fix(M01): 200 원 미만 단가는 유효숫자로 — 상세 · 모달 단가 (PLAN 5장 5바퀴)

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016WRFJmmhPi4exAzHgPZHMT
This commit is contained in:
2026-09-24 11:44:34 +09:00
co-authored by Claude Sonnet 5
parent 0d81acc7d3
commit 68daa24259
3 changed files with 15 additions and 7 deletions
@@ -18,7 +18,7 @@ import type {
TextPiece,
} from "./M01_MasterData_UI_Logic_Api";
import { buildEditor, qtyKind } from "./M01_MasterData_UI_Logic_Edit";
import { formatMoney } from "./M01_MasterData_UI_Logic_Money";
import { formatMoney, formatPrice } from "./M01_MasterData_UI_Logic_Money";
import { openPicker } from "./M01_MasterData_UI_Logic_Pick";
import { tx } from "./M01_MasterData_UI_Logic_Text";
import { buildFormula } from "./M01_MasterData_UI_LogicLab_Formula";
@@ -206,7 +206,7 @@ const spread = (e: Entry, line?: CalcLine): Entry[] => {
share: k,
// 몫 줄 단가 = 단가 × (몫 금액 ÷ 줄 금액) — 곱하기 수량이 몫 금액과 맞게
...(line && line.금액 && line.단가 != null
? { price: formatMoney((line.단가 * v) / line.금액) }
? { price: formatPrice((line.단가 * v) / line.금액) }
: {}),
}
: {}),
@@ -230,7 +230,7 @@ function entries(ctx: DetailContext): Entry[] {
qty: item.수량,
qtyTag: qtyKind(item.수량) === tx("Ho_QtyTable") ? tl("Tag_Table") : qtyKind(item.수량),
qtyFrag: [{ text: item.수량 }],
price: price === undefined || price === null ? "" : formatMoney(price),
price: price === undefined || price === null ? "" : formatPrice(price),
amount: line ? line.금액 : null,
extra: false,
open: (self) =>