feat(project): hide completed projects and done sections in meeting task pickers
- Project picker skips status=completed; section picker skips is_done_stage - Auto-selected first section skips done sections - Help + docs; jsdom test data covers both Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -10703,7 +10703,8 @@
|
||||
async function loadProjects() {
|
||||
if (projects) return projects;
|
||||
const res = await api("GET", "/project/api/projects");
|
||||
projects = (res.projects || []).filter(function (p) { return !p.parent_id; });
|
||||
// 완료 프로젝트는 고를 목록에서 뺀다(새 작업을 넣을 곳이 아니다) — 서버는 보관만 뺀다
|
||||
projects = (res.projects || []).filter(function (p) { return !p.parent_id && p.status !== "completed"; });
|
||||
return projects;
|
||||
}
|
||||
async function membersOf(pid) {
|
||||
@@ -10758,7 +10759,8 @@
|
||||
showToast(nameOf(r.assignee) + "님은 이 프로젝트 멤버가 아니어서 담당자를 비웠습니다.");
|
||||
r.assignee = "";
|
||||
}
|
||||
if (!r.stageId && stages.length) { r.stageId = stages[0].id; r.stageName = stages[0].name; }
|
||||
const open = stages.filter(function (st) { return !st.is_done_stage; }); // 완료 섹션은 자동으로 고르지 않는다
|
||||
if (!r.stageId && open.length) { r.stageId = open[0].id; r.stageName = open[0].name; }
|
||||
} catch (e) { showToast("프로젝트 정보를 읽지 못했습니다: " + e.message, "error"); }
|
||||
save(); render();
|
||||
}
|
||||
@@ -10809,7 +10811,8 @@
|
||||
showToast("섹션 ‘" + res.stage.name + "’를 만들었습니다.");
|
||||
} catch (e) { showToast("섹션 만들기 실패: " + e.message, "error"); }
|
||||
} }, null];
|
||||
menuAt(btn, head.concat(stages.map(function (st) {
|
||||
// 완료 섹션(완료 단계)은 목록에서 뺀다 — 거기 만들면 바로 완료 처리된다
|
||||
menuAt(btn, head.concat(stages.filter(function (st) { return !st.is_done_stage; }).map(function (st) {
|
||||
return { label: st.name, icon: menuIcon("view_column"), checked: r.stageId === st.id, onClick: function () { r.stageId = st.id; r.stageName = st.name; save(); render(); } };
|
||||
})));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user