From c3cab212b66889003c2ce4a6cb812f7e00961e27 Mon Sep 17 00:00:00 2001 From: king Date: Wed, 14 Oct 2026 15:39:06 +0900 Subject: [PATCH] =?UTF-8?q?style(project):=20=EB=A7=88=EA=B0=90=20?= =?UTF-8?q?=EC=A7=80=EB=82=9C=20=EC=97=85=EB=AC=B4=20=EC=95=8C=EB=A6=BC=20?= =?UTF-8?q?=EB=8B=AB=EA=B8=B0=20=EB=B2=84=ED=8A=BC=20=EA=B8=80=EC=9E=90=20?= =?UTF-8?q?"(1=EC=8B=9C=EA=B0=84=20=EB=92=A4=20=EB=8B=A4=EC=8B=9C)"=20?= =?UTF-8?q?=EC=82=AD=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 1시간 뒤 다시 알리는 동작·말풍선 안내는 그대로. Co-Authored-By: Claude Opus 5.5 --- app/static/erp-overdue.js | 2 +- app/templates/admin.html | 2 +- app/templates/erp_base.html | 2 +- app/templates/main.html | 2 +- docs/PROJECT_MODULE.md | 2 +- tests/js/overdue_ui.test.js | 4 +++- 6 files changed, 8 insertions(+), 6 deletions(-) diff --git a/app/static/erp-overdue.js b/app/static/erp-overdue.js index e175b1e..96a72aa 100644 --- a/app/static/erp-overdue.js +++ b/app/static/erp-overdue.js @@ -85,7 +85,7 @@ box.innerHTML = '
' + '마감이 지난 내 업무 ' + tasks.length + "건" + - '
' + + '' + '
' + rows + more + "
"; box.hidden = false; } diff --git a/app/templates/admin.html b/app/templates/admin.html index d32d7d7..019967c 100644 --- a/app/templates/admin.html +++ b/app/templates/admin.html @@ -344,6 +344,6 @@ - + diff --git a/app/templates/erp_base.html b/app/templates/erp_base.html index 0b79e70..ef5b5ad 100644 --- a/app/templates/erp_base.html +++ b/app/templates/erp_base.html @@ -194,7 +194,7 @@ {# 긴급 공지 — 로그인한 모든 화면 가운데(받는 사람이 [확인] 전까지). app/modules/notice #} {% if user %}{% endif %} {# 마감 지난 내 업무 — 로그인한 모든 화면 위쪽(닫으면 1시간 뒤 다시). Project 권한이 없으면 조용히 멈춘다. #} - {% if user %}{% endif %} + {% if user %}{% endif %} {% block scripts %}{% endblock %} diff --git a/app/templates/main.html b/app/templates/main.html index 41e96cf..bb16c47 100644 --- a/app/templates/main.html +++ b/app/templates/main.html @@ -171,6 +171,6 @@ - + diff --git a/docs/PROJECT_MODULE.md b/docs/PROJECT_MODULE.md index 36c1d09..be1a4a3 100644 --- a/docs/PROJECT_MODULE.md +++ b/docs/PROJECT_MODULE.md @@ -1285,7 +1285,7 @@ Windows 트레이 프로그램 **DBX 알림**(`desktop/notifier/`, C# .NET Frame - **마감 지난 내 업무 알림** — `static/erp-overdue.js`·`erp-overdue.css`, ERP 모든 화면(`erp_base.html`·`main.html`·`admin.html`) 위쪽 가운데 (body 에 붙음, z 5500 — 긴급 공지 6000 아래). `GET /project/api/my-overdue` = 내가 담당인 미완료 업무(세부 포함) 중 마감일 < 오늘(KST), 지금 볼 수 있는 것만(`access.filter_visible_tasks`), 마감 오래된 순 최대 200건(`db.list_my_overdue`). 알림은 최대 5줄 + "그 밖에 N건 — 내 업무에서 보기", - 줄 = `/project/t/{id}`(마감 M/D · N일 지남). **[닫기 (1시간 뒤 다시)]** = localStorage `erp_overdue_snooze`({until, ids}) — 이 브라우저 모든 탭이 + 줄 = `/project/t/{id}`(마감 M/D · N일 지남). **[닫기]**(말풍선 "닫으면 1시간 뒤에 다시 알려 드립니다", 2026-10-14 버튼 글자에서 "(1시간 뒤 다시)" 뺌) = localStorage `erp_overdue_snooze`({until, ids}) — 이 브라우저 모든 탭이 1시간 쉬고, 닫을 때 없던 업무가 새로 마감을 넘기면 바로 다시 띄운다. 5분마다·창을 다시 볼 때 확인, 다 완료하면 사라짐. 401·403(Project 권한 없음)·404·503 이면 조용히 멈춤, iframe 안에서는 안 돈다. 새 환경변수·DB 변경 없음. - 검증: `tests/test_project_module.py::test_create_with_followers_and_my_overdue`(실제 PG), `tests/js/project_ui.test.js` diff --git a/tests/js/overdue_ui.test.js b/tests/js/overdue_ui.test.js index ae873c5..3a9278a 100644 --- a/tests/js/overdue_ui.test.js +++ b/tests/js/overdue_ui.test.js @@ -42,7 +42,9 @@ const T = function (id, title, due, extra) { const first = box.querySelector(".erp-overdue-item"); check("[마감 알림] 줄 = 업무 링크·마감일·며칠 지남", first.getAttribute("href") === "/project/t/1" && /마감 10\/10 · 3일 지남/.test(first.textContent)); check("[마감 알림] 제목은 글자로(HTML 아님)·상위 업무 표시", !box.querySelector(".erp-overdue-item b b") && /상위: 상위/.test(box.textContent)); - box.querySelector("[data-overdue-close]").click(); await settle(); + const closeBtn = box.querySelector("[data-overdue-close]"); + check("[마감 알림] 닫기 버튼 글자는 '닫기'만(1시간 뒤 안내는 말풍선)", closeBtn.textContent.trim() === "닫기" && /1시간/.test(closeBtn.title), closeBtn.textContent); + closeBtn.click(); await settle(); check("[마감 알림] 닫기 → 숨김·1시간 쉼 기록", box.hidden && JSON.parse(e.w.localStorage.getItem("erp_overdue_snooze")).ids.length === 7); await e.w.__erpOverdue.poll(); await settle(); check("[마감 알림] 1시간 안 다시 확인 — 같은 업무면 안 띄움", box.hidden);