feat(aiot): 告警冷却时间调整 + 截图本地保留 + 中文路径修复

- 离岗检测冷却时间: 300s → 600s(10分钟)
- 入侵检测冷却时间: 120s → 300s(5分钟)
- 入侵告警级别改为高(alarm_level=3)
- COS 不可用时保留本地截图文件,不再上报后删除
- 修复 cv2.imwrite 中文路径失败,改用 imencode + write_bytes
- 配置订阅在 LOCAL 模式下跳过 Redis 连接

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-11 09:57:02 +08:00
parent e828f4e09b
commit 181623428a
8 changed files with 532 additions and 66 deletions

View File

@@ -266,7 +266,7 @@ class SQLiteManager:
'param_schema': json.dumps({
"confirm_on_duty_sec": {"type": "int", "default": 10, "min": 1},
"confirm_leave_sec": {"type": "int", "default": 10, "min": 1},
"cooldown_sec": {"type": "int", "default": 300, "min": 0},
"cooldown_sec": {"type": "int", "default": 600, "min": 0},
"working_hours": {"type": "list", "default": []},
}),
'description': '检测人员是否在岗,支持工作时间段配置'
@@ -276,7 +276,7 @@ class SQLiteManager:
'algo_name': '周界入侵检测',
'target_class': 'person',
'param_schema': json.dumps({
"cooldown_seconds": {"type": "int", "default": 120, "min": 0},
"cooldown_seconds": {"type": "int", "default": 300, "min": 0},
"confirm_seconds": {"type": "int", "default": 5, "min": 1},
}),
'description': '检测人员进入指定区域,支持确认时间和冷却时间配置'