refactor(desktop): narrow home health board to expired/revoked accounts
Home 看板只保留已过期或已停用的账号,问题计数改用阻塞态 authState;新增 formatVerifiedAtLabel,统一校验通过时间的展示粒度。 Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -114,6 +114,9 @@ function createLiveRuntimeSnapshot(controller: ReturnType<typeof getRuntimeContr
|
||||
acc[item.health] = (acc[item.health] ?? 0) + 1;
|
||||
return acc;
|
||||
}, {});
|
||||
const blockingAccountCount = accounts.filter((item) =>
|
||||
["expired", "revoked", "challenge_required"].includes(item.authState),
|
||||
).length;
|
||||
|
||||
return {
|
||||
generatedAt: now,
|
||||
@@ -138,7 +141,7 @@ function createLiveRuntimeSnapshot(controller: ReturnType<typeof getRuntimeContr
|
||||
queuedTasks: tasks.filter((item) => item.status === "queued").length,
|
||||
issuesOpen:
|
||||
tasks.filter((item) => ["unknown", "failed"].includes(item.status)).length
|
||||
+ accounts.filter((item) => item.health !== "live").length,
|
||||
+ blockingAccountCount,
|
||||
healthCounts,
|
||||
},
|
||||
clients,
|
||||
|
||||
Reference in New Issue
Block a user