refactor(856-4): 공용 줄 쌓기가 M02 · M01 을 거꾸로 부르는 것 끊음 — 층 · 부름 · 찾기 창 · 단위 고르기 · 합계 상자 · 기계 칸 고리

- 층 이름 · /api/m02 부름 = common_util_m02_call 새 조각(M02 Api_Fetch 는 그대로 내보냄 — M02 부르는 곳 안 바뀜)
- 찾아 넣기 창 = 페이지가 넘김(StackFind · 줄 쌓기 화면 · 기계 시트 · 편집 · 제어 구역 훅) — M01 · M02 가 M02 openFindPicker 를 넘김
- 단위 고르기 = 부품 상자 ui_template_unit_pick(옛 M02 DataFlow/DF_UnitPick · 표준 표 읽기 같이 옮김)
- 합계 상자 = A00 formula_doc_foot 로 합침(옛 M01 LogicLab_Foot · 쓰는 곳 하나) · 그 CSS = formula_doc_foot.css · 안 쓰는 세 칸 갈래 · 글 키 걷음
- 기계 제어 구역 ↔ 작업량 고리 = 칸 부품 line_stack_machine_cell 로(수 칸 · 바뀜 표시)
- 수치: 공용(A00) → M01 · M02 import 9 파일 17 → 3 파일 7(남은 것 = 기계 · 불러온 재료 훅 — 858 · 857 몫) · ctl ↔ work 고리 0
- 동작 불변(화면 확인 · 시험) · 시험: 옮긴 파일 이름 · 경로만 고침 · 걸린 글 대조 줄 지움(721 · 737)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-17 21:02:43 +09:00
co-authored by Claude Opus 5.5
parent d6715dcec5
commit bd41d87996
3 changed files with 0 additions and 53 deletions
@@ -1,53 +0,0 @@
/* =============================================================================
* M01_MasterData_UI_LogicLab_Foot.ts
* 화면(모달) 바닥에 붙는 비목 소계 줄(737-1 · PLAN 748-3) — 단가산출 상세(노무비 · 재료비 · 경비 · 계 네 칸) ·
* 텍스트 수식(노무비 · 재료비 · 경비 세 칸 · 계 칸 없음 — 중복 표기) 두 보기가 같이 씀.
* 값 = 서버 셈 그대로(여기서 다시 셈 안 함) · 계산 전 「—」.
* ========================================================================== */
import { createCalcFormulaRow } from "@ui/ui_template_calc_row";
import { el } from "@ui/ui_template_elements";
import { formatMoney } from "../common_util/common_util_money";
import { tl } from "./M01_MasterData_UI_LogicLab_Text";
export type FootKey = "labor" | "material" | "cost";
const LABEL: Record<FootKey, string> = { labor: "노무비", material: "재료비", cost: "경비" };
export const FOOT_KEYS = Object.keys(LABEL) as FootKey[];
/** 비목 소계 줄 — `total` 을 주면 맨 끝 「계」 칸까지 네 칸(주지 않으면 세 칸) */
export function buildFoot(
sums: Record<FootKey, number>,
calculated: boolean,
total?: number,
): HTMLElement {
const cells = FOOT_KEYS.map((k) => {
const out = el("span", {
className: "ui-calc-row__out is-key",
text: calculated ? formatMoney(sums[k]) : "—",
});
const row = createCalcFormulaRow(LABEL[k], null, out);
row.dataset.group = k;
row.dataset.subtotal = calculated ? String(sums[k]) : "";
return row;
});
const foot = el("div", {
className: "m01lab__foot",
children: [
el("div", { className: "m01lab__sums", children: cells }),
...(total === undefined
? []
: [
el("p", {
className: "m01lab__total",
attrs: { "data-sum": calculated ? String(total) : "" },
children: [
el("span", { text: `${tl("Total")} ` }),
el("span", { text: calculated ? formatMoney(total) : "—" }),
],
}),
]),
],
});
if (total === undefined) foot.dataset.cols = "3";
return foot;
}