ui(cupang): 박스 입수량 2열 배치 + 고정폭 + 입수량 "개" 단위
- 추가/수정 480px(좌), 입수량 규칙 900px(우) - 제품명/제품코드/박스이름 입력 140px, 박스당 입수량 60px + "개" 접미 - 캐시 버전 e Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{% extends "erp_base.html" %}
|
||||
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530d" />{% endblock %}
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530e" />{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="cpg">
|
||||
@@ -9,15 +9,17 @@
|
||||
<a class="erp-btn erp-btn-primary" href="/cupang/">◀◀ 달력</a>
|
||||
</div>
|
||||
|
||||
<!-- 추가/수정 (product_code UNIQUE → upsert) -->
|
||||
<div class="erp-card cpg-form-card">
|
||||
<div class="cpg-brule-layout">
|
||||
|
||||
<!-- 왼쪽: 추가/수정 (product_code UNIQUE → upsert) -->
|
||||
<div class="erp-card cpg-form-card cpg-brule-add">
|
||||
<div class="cpg-card-head">
|
||||
<h2>박스 입수량 추가 / 수정</h2>
|
||||
<span class="erp-muted">같은 제품코드는 덮어씁니다. 쿠팡박스 1박스당 들어가는 수량.</span>
|
||||
<span class="erp-muted">같은 제품코드는 덮어씁니다.</span>
|
||||
</div>
|
||||
<form method="post" action="/cupang/box-rules">
|
||||
<input type="hidden" name="product_name_snapshot" id="brule-name-snap" />
|
||||
<div class="cpg-header-grid">
|
||||
<div class="cpg-brule-fields">
|
||||
<label class="erp-field"><span>제품명 *</span>
|
||||
<select class="erp-select" id="brule-name" required>
|
||||
<option value="">— 제품명 선택 —</option>
|
||||
@@ -26,13 +28,16 @@
|
||||
{% endfor %}
|
||||
</select></label>
|
||||
<label class="erp-field"><span>제품코드</span>
|
||||
<input class="erp-input" type="text" name="product_code" id="brule-code" required placeholder="제품명 선택 시 자동" /></label>
|
||||
<input class="erp-input" type="text" name="product_code" id="brule-code" required placeholder="자동" /></label>
|
||||
<label class="erp-field"><span>박스이름</span>
|
||||
<input class="erp-input" type="text" name="box_name" value="쿠팡박스" /></label>
|
||||
<label class="erp-field"><span>박스당 입수량 *</span>
|
||||
<input class="erp-input" type="number" name="units_per_box" min="1" required /></label>
|
||||
<span class="cpg-upb-wrap">
|
||||
<input class="erp-input cpg-brule-upb" type="number" name="units_per_box" min="1" required />
|
||||
<span class="cpg-upb-unit">개</span>
|
||||
</span></label>
|
||||
<label class="erp-field cpg-full"><span>메모</span>
|
||||
<input class="erp-input" type="text" name="memo" /></label>
|
||||
<input class="erp-input cpg-brule-memo" type="text" name="memo" /></label>
|
||||
</div>
|
||||
<div class="erp-page-actions" style="margin-top:12px;">
|
||||
<button type="submit" class="erp-btn erp-btn-primary">저장</button>
|
||||
@@ -41,24 +46,24 @@
|
||||
{% if not products %}
|
||||
<p class="erp-muted"><a href="/cupang/products">설정에서 제품명을 먼저 등록</a>하면 드롭다운에 표시됩니다.</p>
|
||||
{% endif %}
|
||||
|
||||
<script>
|
||||
(function () {
|
||||
var sel = document.getElementById("brule-name");
|
||||
var code = document.getElementById("brule-code");
|
||||
var snap = document.getElementById("brule-name-snap");
|
||||
if (!sel) return;
|
||||
sel.addEventListener("change", function () {
|
||||
var opt = sel.options[sel.selectedIndex];
|
||||
code.value = sel.value;
|
||||
snap.value = opt ? (opt.getAttribute("data-name") || "") : "";
|
||||
});
|
||||
})();
|
||||
</script>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
(function () {
|
||||
var sel = document.getElementById("brule-name");
|
||||
var code = document.getElementById("brule-code");
|
||||
var snap = document.getElementById("brule-name-snap");
|
||||
if (!sel) return;
|
||||
sel.addEventListener("change", function () {
|
||||
var opt = sel.options[sel.selectedIndex];
|
||||
code.value = sel.value;
|
||||
snap.value = opt ? (opt.getAttribute("data-name") || "") : "";
|
||||
});
|
||||
})();
|
||||
</script>
|
||||
|
||||
<!-- 목록 -->
|
||||
<div class="erp-card cpg-form-card">
|
||||
<!-- 오른쪽: 목록 -->
|
||||
<div class="erp-card cpg-form-card cpg-brule-list">
|
||||
<div class="cpg-card-head"><h2>입수량 규칙 ({{ box_rules|length }})</h2></div>
|
||||
<div class="erp-table-wrap">
|
||||
<table class="erp-table">
|
||||
@@ -89,5 +94,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div><!-- /cpg-brule-layout -->
|
||||
|
||||
</section>
|
||||
{% endblock %}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{% extends "erp_base.html" %}
|
||||
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530d" />{% endblock %}
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530e" />{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="cpg">
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{% extends "erp_base.html" %}
|
||||
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530d" />{% endblock %}
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530e" />{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="cpg">
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{% extends "erp_base.html" %}
|
||||
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530d" />{% endblock %}
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530e" />{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="cpg">
|
||||
@@ -118,4 +118,4 @@
|
||||
</script>
|
||||
{% endblock %}
|
||||
|
||||
{% block scripts %}<script src="/static/cupang.js?v=20260530d" defer></script>{% endblock %}
|
||||
{% block scripts %}<script src="/static/cupang.js?v=20260530e" defer></script>{% endblock %}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{% extends "erp_base.html" %}
|
||||
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530d" />{% endblock %}
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530e" />{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="cpg">
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{% extends "erp_base.html" %}
|
||||
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530d" />{% endblock %}
|
||||
{% block head_extra %}<link rel="stylesheet" href="/static/cupang.css?v=20260530e" />{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="cpg">
|
||||
|
||||
Reference in New Issue
Block a user