diff --git a/src/frontend/src/components/EdictBoard.tsx b/src/frontend/src/components/EdictBoard.tsx index ca4e677..f08dded 100644 --- a/src/frontend/src/components/EdictBoard.tsx +++ b/src/frontend/src/components/EdictBoard.tsx @@ -425,6 +425,24 @@ export default function EdictBoard() { const reviewCount = topLevelTasks.filter(t => !t.archived && t.status === 'review').length; const archivedCount = topLevelTasks.filter(t => t.archived).length; + // 下拉菜单数字:从 v2tasks 聚合(单一数据源,与看板统计一致) + const topLevelAll = (v2tasks as any[]).filter(t => !t.parent_task); + const countByProjectAndFilter = (pid: string) => { + return topLevelAll.filter(t => { + if (t._projectId !== pid) return false; + if (archiveFilter === 'archived') return !!t.archived; + if (archiveFilter === 'active') return !t.archived; + return true; + }).length; + }; + const countAllByFilter = () => { + return topLevelAll.filter(t => { + if (archiveFilter === 'archived') return !!t.archived; + if (archiveFilter === 'active') return !t.archived; + return true; + }).length; + }; + if (v2tasksLoading && tasks.length === 0) return ; return (