fix(B09 설계내역서): 엑셀 내역 불러오기 화면 검증 흠 — 단가만 빈칸 · 운반 줄 오붙음 · 차례 · 표 높이 (PLAN 707-1)

- 단가만 갈래 = 붙인 자동 줄에 B08 수량이 없으면 엑셀 수량(빈칸 금액 막음)
- 운반 자동 줄(「모래」 · 「시멘트」 = 자재대 줄 이름) = 붙이지 않음 · 지우기만
- 불러온 공종 = 관급자재대 앞(엑셀 차례 · 표 끝에 묻히지 않음)
- 결과 창 = 표를 다시 그린 뒤 따로 엶(열린 창 가림막을 표 아래 자리로 재어 표가 한 줄로 줄던 것) · 어긋난 줄 표 칸 폭 줄임
- 못 읽은 파일(빈 · DRM · 내역 시트 없음) = 프로젝트 import 폴더에 안 둠

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-31 16:13:34 +09:00
co-authored by Claude Opus 5.5
parent 02886d5d4d
commit c33f6837f2
4 changed files with 60 additions and 35 deletions
+22 -15
View File
@@ -51,11 +51,11 @@ function merged(user: Row, made: Row): Row {
function differences(rows: Row[]): HTMLElement {
return createDataTable({
columns: [
{ key: "행", label: "엑셀 행", kind: "number", width: 56 },
{ key: "이름", label: "명칭", width: 200 },
{ key: "엑셀", label: "엑셀 금액", kind: "number", width: 110 },
{ key: "우리", label: "우리 금액", kind: "number", width: 110 },
{ key: "까닭", label: "까닭", width: 160 },
{ key: "행", label: "엑셀 행", kind: "number", width: 48 },
{ key: "이름", label: "명칭", width: 150 },
{ key: "엑셀", label: "엑셀 금액", kind: "number", width: 96 },
{ key: "우리", label: "우리 금액", kind: "number", width: 96 },
{ key: "까닭", label: "까닭", width: 130 },
],
rows,
}).root;
@@ -123,20 +123,27 @@ export function createBillImport(
showLoadingOverlay();
try {
const got = await post(projectId, "bill/apply", JSON.stringify(ask), true);
// 창 닫고 다시 그림 — 표 높이(fillViewport)가 열린 창 가림막을 아래 자리로 셈
close();
done(got.payload, merged(draft, got.user));
const n = got.알림 || {};
const head = `새 줄 ${n.실음} · 붙임 ${n.붙임} · 지움 ${n.지움} · 이음 ${n.이음} — [저장]해야 남음`;
const off: Row[] = got.어긋남 || [];
if (!off.length) {
close();
return void showToast(`${head} · 엑셀 금액과 모두 같음`, "success");
}
run.remove();
body.replaceChildren(
createText(head, "success", 14),
createText(`엑셀 금액과 다른 줄 ${off.length}`, "warning", 14),
differences(off),
);
if (!off.length) return void showToast(`${head} · 엑셀 금액과 모두 같음`, "success");
// 어긋난 줄 = 표 높이를 잰 뒤(다음 화면) 보기 창
const result = (): void =>
void openModal({
title: "엑셀 내역 불러오기 — 결과",
closeLabel: "닫기",
width: "40rem",
mount: (box) =>
box.append(
createText(head, "success", 14),
createText(`엑셀 금액과 다른 줄 ${off.length}`, "warning", 14),
differences(off),
),
});
requestAnimationFrame(() => requestAnimationFrame(result));
} catch (error) {
showToast(`불러오지 못함 — ${error instanceof Error ? error.message : error}`, "error");
} finally {