feat: 新增多插件 UI 支持及运行日志集中回传功能

本次提交包含多项功能更新:
1. 为多个插件(xq0002/0003/0004/0008/0010/0011/0020/0031_xq0032/0033/0035/0037/0045_xq0046/0047/0048)新增 UI 界面及配置支持
2. 新增运行日志集中回传功能,客户端自动上传运行日志到中心机集中存储
3. 新增插件分类字段支持,用于场景库分组管理
4. 优化 xq0034/0037/0048 等插件的功能及描述
5. 修复控制面响应兼容问题,支持新旧版本数据格式
6. 新增 xq0033 插件的状态存储模块,用于历史记录管理
7. 优化 CRM 登录窗口模式,支持全屏置顶
This commit is contained in:
2026-10-26 15:42:50 +08:00
parent 8bf33b65cd
commit c73c113721
453 changed files with 243002 additions and 4493 deletions
+7
View File
@@ -28,6 +28,7 @@ from fastapi.middleware.cors import CORSMiddleware
from controlplane import config
from controlplane.core.db import _init_db, _seed
from controlplane.core.logstore import cleanup_expired, start_log_cleanup
from controlplane.core.monitor import start_fileserver_monitor
from controlplane.apis import admin as api_admin
from controlplane.apis import auth as api_auth
@@ -52,6 +53,12 @@ async def lifespan(app: FastAPI):
"CONTROLPLANE_TOKEN 未配置:全部客户端接口将无鉴权放行,生产环境禁止!")
_init_db()
_seed()
# 集中日志保留期清理:启动即清一次超期日志 + 常驻周期清理(daemon 线程)
try:
cleanup_expired()
except Exception: # noqa: BLE001 启动清理失败不阻断服务(周期线程会继续重试)
_LOGGER.exception("集中日志启动清理失败")
start_log_cleanup()
# 内网文件服务器离线监控:心跳超时判离线并钉钉告警管理员(daemon 线程)
start_fileserver_monitor()
yield