From b3d540b8143b1be9e556523aa64d3ba8d721d04f Mon Sep 17 00:00:00 2001
From: qixiaoning <jony.kee@outlook.com>
Date: 星期二, 09 九月 2025 16:56:30 +0800
Subject: [PATCH] 修改分辨率后更新解码配置
---
chanmanage-service/service/pollSetService.go | 22 +++++++++++++++-------
1 files changed, 15 insertions(+), 7 deletions(-)
diff --git a/chanmanage-service/service/pollSetService.go b/chanmanage-service/service/pollSetService.go
index 3fb386b..32c0845 100644
--- a/chanmanage-service/service/pollSetService.go
+++ b/chanmanage-service/service/pollSetService.go
@@ -176,12 +176,15 @@
}
}
+ //鑾峰彇鐫f煡浠诲姟
+ tasks := models.GetTasks()
+
rTotal := 0
pTotal := 0
for _, c := range camMap {
if c.RunType == bhomeclient.TYPE_RUNTYPE_REALTIME {
rTotal++
- if crInfo, ok := ruleM[c.Id]; ok && crInfo.Rules != nil && len(crInfo.Rules) > 0 {
+ if taskInfo, ok := tasks[c.Id]; ok && taskInfo != nil && len(taskInfo) > 0 {
v.RealValidCount++
} else {
v.RealInvalidCount++
@@ -202,17 +205,22 @@
// }
}
}
+
+ //鎬荤畻閲屾殏鏃跺彧缁熻瀹炴椂绠楀姏
+ v.ChannelTotal = rTotal
+
v.RealTotal = rTotal
v.PollTotal = pTotal
logger.Debug("statisticRunInfo 鑾峰彇瀹孍xistRunningTask鑰楁椂锛�", time.Since(timeStart))
timeStart = time.Now()
- //杞閫氶亾鏁伴噺浠庤疆璇㈤厤缃腑鑾峰彇
- var pollConf models.PollConfig
- pcE, err2 := pollConf.GetOne()
- if err2 == nil {
- v.PollChannelCount = pcE.PollChannelCount
- }
+ //杞閫氶亾鏁伴噺浠庤疆璇㈤厤缃腑鑾峰彇20250724绉婚櫎
+ // var pollConf models.PollConfig
+ // pcE, err2 := pollConf.GetOne()
+ // if err2 == nil {
+ // v.PollChannelCount = pcE.PollChannelCount
+ // }
+
//tmpPC := v.RealTotal - v.StackTotal
//if tmpPC < 0 {
// v.PollChannelCount = 0
--
Gitblit v1.8.0