feat(tasks): 任务列表新增「运行中 Worker」列
TaskListMetricsAll 增加一个 LATERAL 子查询统计 kind='intent' 且 state='running' 的节点数,随 TaskDTO.in_flight 一并返回,口径与任务 详情页概览的「运行中 Worker」完全一致。列表页在「目标进度」后新增该 列,无运行中 Worker 时显示 0。
This commit is contained in:
1 parent
4fba36b73d
commit
f270ca66bc
4 files changed
+22
-4
No files matched your search
@@ -1064,6 +1064,7 @@ func (s *Server) listTasks(w http.ResponseWriter, r *http.Request) {
|
||||
}
|
||||
dto.GoalsTotal = metric.Goals.Total
|
||||
dto.GoalsMet = metric.Goals.Met
|
||||
dto.InFlight = metric.RunningIntents
|
||||
dtos = append(dtos, dto)
|
||||
}
|
||||
writeJSON(w, 200, map[string]any{"tasks": dtos, "active": active})
|
||||
|
||||
Reference in new issue
Block a user