fix(performance): 주문 내역 창 가로 스크롤 없애기 — 넓은 창(최대 1640px) + 상품명만 줄바꿈

- openModal opts.wide → .perf-modal-card.is-wide(min(1640px, 100%)), 금액 클릭 주문 내역 창에 사용
- 상품명 열(.perf-ev-name)만 줄바꿈(최소 220px), 나머지 열은 한 줄 그대로
- css·js 캐시 버전 올림

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-01 10:39:24 +09:00
parent 931cc0d1d9
commit 614747ffca
4 changed files with 12 additions and 8 deletions
@@ -1,6 +1,6 @@
{% extends "erp_base.html" %}
{% block head_extra %}<link rel="stylesheet" href="/static/performance.css?v=20261001a" />{% endblock %}
{% block head_extra %}<link rel="stylesheet" href="/static/performance.css?v=20261001b" />{% endblock %}
{%- macro won(v) -%}
{%- if v is none -%}<span class="perf-na"></span>
@@ -239,4 +239,4 @@
} | tojson }}</script>
{% endblock %}
{% block scripts %}<script src="/static/performance.js?v=20261001f" defer></script>{% endblock %}
{% block scripts %}<script src="/static/performance.js?v=20261001g" defer></script>{% endblock %}
@@ -1,6 +1,6 @@
{% extends "erp_base.html" %}
{% block head_extra %}<link rel="stylesheet" href="/static/performance.css?v=20261001a" />{% endblock %}
{% block head_extra %}<link rel="stylesheet" href="/static/performance.css?v=20261001b" />{% endblock %}
{%- macro when(v) -%}{{ (v or '')[:16] | replace('T', ' ') or '—' }}{%- endmacro -%}
@@ -192,4 +192,4 @@
</section>
{% endblock %}
{% block scripts %}<script src="/static/performance.js?v=20261001f" defer></script>{% endblock %}
{% block scripts %}<script src="/static/performance.js?v=20261001g" defer></script>{% endblock %}
+3
View File
@@ -157,6 +157,7 @@ td.is-link:hover { background: #eef2ff; text-decoration: underline; }
.perf-modal { position: fixed; inset: 0; z-index: 1000; background: rgba(0, 0, 0, .35); display: flex; align-items: center; justify-content: center; padding: 20px; }
.perf-modal-card { background: #fff; border-radius: 14px; width: min(1100px, 100%); max-height: 88vh; display: flex; flex-direction: column; box-shadow: 0 20px 60px rgba(0, 0, 0, .25); }
.perf-modal-card.is-narrow { width: min(560px, 100%); }
.perf-modal-card.is-wide { width: min(1640px, 100%); } /* 주문 내역 — 열이 많아 넓게 */
.perf-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--perf-line); }
.perf-modal-head h3 { margin: 0; font-size: 15px; font-weight: 600; }
.perf-modal-body { padding: 12px 16px; overflow: auto; }
@@ -229,6 +230,8 @@ td.is-link:hover { background: #eef2ff; text-decoration: underline; }
.perf-ev-table thead th { background: var(--perf-soft, #fafafa); box-shadow: 0 1px 0 var(--perf-line, #e5e5e5); }
/* 취소 행 — 행 전체를 기울임 + 취소선 + 회색 */
.perf-ev-table tr.is-cancel td { font-style: italic; text-decoration: line-through; color: #9a9a9a; }
/* 상품명만 줄바꿈 — 긴 상품명 때문에 표가 창보다 넓어져 가로 스크롤이 생기지 않게(나머지 열은 한 줄) */
.perf-ev-table .perf-ev-name { white-space: normal; min-width: 220px; overflow-wrap: anywhere; }
/* ── 매출 업데이트 진행 창 — 쇼핑몰별·전체 진행 막대(runSyncWithProgress) ── */
.perf-prog-card { width: min(640px, 100%); }
+5 -4
View File
@@ -54,7 +54,8 @@
function openModal(title, opts) {
opts = opts || {};
const back = el("div", { class: "perf-modal" });
const card = el("div", { class: "perf-modal-card" + (opts.narrow ? " is-narrow" : ""), role: "dialog", "aria-modal": "true" });
const card = el("div", { class: "perf-modal-card" + (opts.narrow ? " is-narrow" : opts.wide ? " is-wide" : ""),
role: "dialog", "aria-modal": "true" });
const head = el("div", { class: "perf-modal-head" });
head.appendChild(el("h3", { text: title }));
const x = el("button", { type: "button", class: "perf-modal-x", "aria-label": "닫기" }, "×");
@@ -335,7 +336,7 @@
async function openEvents(code, from, to) {
const name = (data.names || {})[code] || code;
const title = name + " · " + (from === to ? from : from + " ~ " + to) + " 주문 내역";
const m = openModal(title);
const m = openModal(title, { wide: true }); // 넓은 창 + 상품명 줄바꿈 → 가로 스크롤 없이
m.body.innerHTML = '<p class="perf-muted">불러오는 중…</p>';
try {
const res = await api("GET", "/performance/api/events?code=" + encodeURIComponent(code) +
@@ -351,7 +352,7 @@
"<td>" + esc(r.sales_date) + "</td><td>" + esc(KIND[r.event_type] || r.event_type) +
(r.is_sample ? ' <span class="perf-pill">테스트</span>' : "") + "</td>" +
"<td>" + esc(r.external_order_id) + "</td>" +
"<td>" + esc(r.product_name) + (r.option_name ? " <span class='perf-muted'>" + esc(r.option_name) + "</span>" : "") + "</td>" +
'<td class="perf-ev-name">' + esc(r.product_name) + (r.option_name ? " <span class='perf-muted'>" + esc(r.option_name) + "</span>" : "") + "</td>" +
'<td class="perf-num">' + esc(r.quantity) + "</td>" +
'<td class="perf-num">' + fmt(r.amount) + "</td>" +
"<td>" + esc(r.order_date || "") + "</td><td>" + esc(r.payment_date || "") + "</td>" +
@@ -360,7 +361,7 @@
m.body.innerHTML =
'<div class="perf-ev-wrap"><table class="perf-table perf-ev-table"><thead><tr>' +
'<th class="perf-th-label">매출일</th><th class="perf-th-label">구분</th><th class="perf-th-label">주문번호</th>' +
'<th class="perf-th-label">상품명</th><th>수량</th><th>금액</th><th class="perf-th-label">주문일</th>' +
'<th class="perf-th-label perf-ev-name">상품명</th><th>수량</th><th>금액</th><th class="perf-th-label">주문일</th>' +
'<th class="perf-th-label">결제일</th><th class="perf-th-label">상태</th></tr></thead><tbody>' + body +
'</tbody><tfoot><tr class="perf-row-total"><th class="perf-td-label" colspan="5">결제 ' + fmt(sales) +
" / 취소·반품 " + fmt(minus) + '</th><td class="perf-num">' + fmt(sum) + '</td><td colspan="3"></td></tr></tfoot></table></div>' +