Files
dbx-main/app/modules/dispatch/templates/dispatch/batches.html
T
king 1d6a523c1f feat(dispatch): 배치 목록 플랫폼을 로고 아이콘으로 표기
- shopee.png / tiktok.png 추가, 플랫폼 칸에 아이콘(미매칭은 텍스트 폴백)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-22 16:48:14 +09:00

67 lines
3.9 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{% extends "erp_base.html" %}
{% block content %}
<section class="dsp">
{% include "dispatch/_nav.html" %}
<div class="erp-card">
<div class="cpg-card-head" style="display:flex;justify-content:space-between;align-items:center;">
<h2><span data-ko="출고 배치" data-en="Batches">출고 배치</span> ({{ batches|length }})</h2>
<a class="erp-btn erp-btn-primary" href="/dispatch/batches/new" data-ko=" 새 업로드" data-en="+ New Upload"> 새 업로드</a>
</div>
<div class="erp-table-wrap">
<table class="erp-table">
<thead>
<tr>
<th data-ko="날짜" data-en="Date">날짜</th>
<th data-ko="플랫폼" data-en="Platform">플랫폼</th>
<th data-ko="배치명" data-en="Batch">배치명</th>
<th style="text-align:right" data-ko="박스" data-en="Boxes">박스</th>
<th style="text-align:right" data-ko="완료" data-en="Done">완료</th>
<th data-ko="생성시각" data-en="Created">생성시각</th><th></th>
</tr>
</thead>
<tbody>
{% for b in batches %}
<tr>
<td style="white-space:nowrap;">{{ b.dispatch_date }}</td>
<td>
{% set pf = (b.platform or '')|lower %}
{% if pf in ['tiktok', 'shopee'] %}
<img src="/static/dispatch/courier/{{ pf }}.png" alt="{{ b.platform }}" title="{{ b.platform }}"
style="height:22px;width:auto;max-width:100px;vertical-align:middle;object-fit:contain;" />
{% else %}{{ b.platform }}{% endif %}
</td>
<td><a href="/dispatch/batches/{{ b.id }}" style="font-weight:600;" class="dsp-bname"
data-raw="{{ b.batch_name or '(이름없음)' }}">{{ b.batch_name or '(이름없음)' }}</a></td>
<td style="text-align:right;">{{ b.parcel_count }}</td>
<td style="text-align:right;">
{% if b.parcel_count and b.done_count == b.parcel_count %}
<span style="color:#16a34a;font-weight:600;">{{ b.done_count }} ✓</span>
{% else %}{{ b.done_count }}{% endif %}
</td>
<td class="erp-muted" style="white-space:nowrap;">{{ (b.created_at[:19].replace('T',' ')) if b.created_at else '' }}</td>
<td style="text-align:right;white-space:nowrap;">
<a class="erp-btn erp-btn-outline" href="/dispatch/batches/{{ b.id }}" data-ko="작업" data-en="Work">작업</a>
<a class="erp-btn erp-btn-outline" href="/dispatch/batches/{{ b.id }}/picking" data-ko="피킹" data-en="Picking">피킹</a>
<a class="erp-btn erp-btn-outline" href="/dispatch/batches/{{ b.id }}/handover" data-ko="전달" data-en="Handover">전달</a>
<a class="erp-btn erp-btn-outline" href="/dispatch/batches/{{ b.id }}/download" data-ko="다운로드" data-en="Download">다운로드</a>
{% if is_super %}
<form method="post" action="/dispatch/batches/{{ b.id }}/delete" style="display:inline;"
onsubmit="return confirm('배치 「{{ b.batch_name or '(이름없음)' }}」 와 모든 박스/상품/로그를 삭제합니다. 되돌릴 수 없습니다. 계속할까요?');">
<button type="submit" class="erp-btn erp-btn-outline" style="color:#dc2626;border-color:#fca5a5;" data-ko="삭제" data-en="Delete">삭제</button>
</form>
{% endif %}
</td>
</tr>
{% endfor %}
{% if not batches %}
<tr><td colspan="7" class="erp-muted" data-ko="아직 출고 배치가 없습니다. 위 + 새 업로드로 시작하세요." data-en="No batches yet. Start with + New Upload above.">아직 출고 배치가 없습니다. 위 + 새 업로드로 시작하세요.</td></tr>
{% endif %}
</tbody>
</table>
</div>
</div>
</section>
{% endblock %}