Files
dbx-main/app/modules/project/templates/project/inbox.html
T
king 8ea0db9245 feat(project): 좌측 프로젝트 트리도 완료 프로젝트 별도 섹션으로 분류
홈 카드와 같은 원칙 — "프로젝트" 목록 아래 "완료 프로젝트" 섹션을 따로
둔다. 서버 렌더(project.html, rejectattr/selectattr로 분리)와 클라이언트
재렌더(project.js renderTree) 둘 다 반영. 완료 섹션이 처음엔 없어도
(완료 프로젝트가 하나도 없던 상태로 열었을 때) 완료로 바뀌는 순간 JS가
동적으로 섹션을 만들고, 마지막 하나가 해제/삭제되면 다시 치운다. 드래그
재정렬은 각 섹션 안에서만(홈 카드와 동일).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-17 15:50:59 +09:00

50 lines
1.7 KiB
HTML

{% extends "erp_base.html" %}
{% block head_extra %}
<link rel="stylesheet" href="/static/project.css?v=20260918d" />
<link rel="stylesheet" href="/static/vendor/material-symbols/material-symbols.css" />
{% endblock %}
{% block content %}
<div class="pj-wrap">
<div class="pj-section-head">
<h2>알림센터</h2>
<div style="display:flex; gap:8px;">
<a class="pj-btn" href="/project/">← 프로젝트</a>
<button type="button" class="pj-btn pj-btn-primary" id="pj-readall">모두 읽음</button>
</div>
</div>
{% if not notifications %}
<div class="pj-empty">알림이 없습니다.</div>
{% else %}
<ul class="pj-inbox" id="pj-inbox">
{% for n in notifications %}
<li class="pj-inbox-item {% if not n.is_read %}is-unread{% endif %}"
data-id="{{ n.id }}"
{% if n.task_id %}data-project="{{ n.project_id }}"{% endif %}>
<span class="material-symbols-outlined pj-inbox-icon">
{% if n.type == 'assigned' %}assignment_ind
{% elif n.type == 'completed' %}task_alt
{% elif n.type == 'comment' %}chat_bubble
{% else %}notifications{% endif %}
</span>
<div class="pj-inbox-body">
<div class="pj-inbox-title">{{ n.title }}</div>
{% if n.body %}<div class="pj-inbox-sub">{{ n.body }}</div>{% endif %}
<div class="pj-inbox-meta">
{% if n.actor_email %}{{ n.actor_email.split('@')[0] }} · {% endif %}{{ n.created_at[:16].replace('T',' ') }}
</div>
</div>
{% if n.project_id %}
<a class="pj-btn pj-inbox-go" href="/project/p/{{ n.project_id }}">이동</a>
{% endif %}
</li>
{% endfor %}
</ul>
{% endif %}
</div>
<script src="/static/project.js?v=20260918d" defer></script>
{% endblock %}