fix(project): 완료 취소 시 완료 이력 줄도 숨김 — 지금 완료 상태일 때 마지막 완료 1건만 표시
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -5015,6 +5015,7 @@
|
||||
setAutoState("saving");
|
||||
saveChain = saveChain.then(async function () {
|
||||
try {
|
||||
const wasDone = !!(currentTaskData && currentTaskData.completed_at);
|
||||
const res = await api("PUT", "/project/api/tasks/" + id, body);
|
||||
mergeTask(res.task);
|
||||
const stillOpen = !taskModal.hidden && el("pj-t-id").value === String(id);
|
||||
@@ -5028,7 +5029,8 @@
|
||||
setCompleteBtn(!!res.task.completed_at);
|
||||
syncDueBtn();
|
||||
}
|
||||
if (res.task._newly_completed) loadComments(id);
|
||||
// 완료 섹션으로 옮기거나 빼면 완료 이력 줄이 생기거나 사라진다.
|
||||
if (wasDone !== !!res.task.completed_at) loadComments(id);
|
||||
if (res.task._newly_assigned) loadTaskExtras(res.task); // 새 담당자가 협업자로 들어온다
|
||||
}
|
||||
if (key !== "desc") refreshActiveView();
|
||||
@@ -5400,7 +5402,7 @@
|
||||
mergeTask(res.task);
|
||||
setCompleteBtn(!!res.task.completed_at);
|
||||
refreshActiveView();
|
||||
if (res.task._newly_completed) loadComments(id); // "OO 님이 이 작업을 완료했습니다" 줄
|
||||
loadComments(id); // "OO 님이 이 작업을 완료했습니다" 줄 — 완료하면 생기고 취소하면 사라진다
|
||||
} catch (e) { alert("처리 실패: " + e.message); }
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user