From 86a092ecd31847f2a2b636ee299a9ee8f669ceb5 Mon Sep 17 00:00:00 2001 From: haopengzhan Date: Sat, 15 Aug 2026 00:07:11 -0700 Subject: [PATCH] feat: update application status tracking and rename pipeline metrics in dashboard UI --- internal/ui/handlers.go | 16 +++++++++++----- internal/ui/template_apply.go | 1 + internal/ui/template_layout.go | 16 ++++++++-------- internal/ui/templates.go | 4 ++-- 4 files changed, 22 insertions(+), 15 deletions(-) diff --git a/internal/ui/handlers.go b/internal/ui/handlers.go index 6d15d2d..ef242eb 100644 --- a/internal/ui/handlers.go +++ b/internal/ui/handlers.go @@ -68,10 +68,16 @@ func (s *Server) handleIndex(w http.ResponseWriter, r *http.Request) { return } - qualifiedCount := 0 + toReviewCount := 0 + inPipelineCount := 0 + for _, j := range jobs { - if j.Analysis != nil && j.Analysis.IsQualified { - qualifiedCount++ + if j.App != nil && j.App.Status != "OPTED_OUT" { + inPipelineCount++ + } else if j.App == nil || j.App.Status != "OPTED_OUT" { + if j.Analysis != nil && (j.Analysis.IsQualified || j.Analysis.Status == "PENDING") { + toReviewCount++ + } } } @@ -81,9 +87,9 @@ func (s *Server) handleIndex(w http.ResponseWriter, r *http.Request) { Applications: apps, ActiveTab: "triage", LLMProvider: s.cfg.LLMProvider, - QualifiedJobsCount: qualifiedCount, + ToReviewCount: toReviewCount, TotalIngestedCount: len(jobs), - ActiveApplications: len(apps), + InPipelineCount: inPipelineCount, } w.Header().Set("Content-Type", "text/html; charset=utf-8") diff --git a/internal/ui/template_apply.go b/internal/ui/template_apply.go index 49da52b..b71862b 100644 --- a/internal/ui/template_apply.go +++ b/internal/ui/template_apply.go @@ -113,6 +113,7 @@ const applyTableHTML = `{{ define "applyTable" }}