auto-sync: 2026-05-23 12:41:33

This commit is contained in:
cfdaily
2026-05-23 12:41:33 +08:00
parent 7f0c95cbe6
commit 4d3a4d2c67
@@ -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 <LoadingSkeleton />;
return (