B08_Quantity 86 · B09_Estimation 111 파일을 old_code/ 로 옮김(지우지 않음). 화면은 메뉴·주소·단계 막대만 남은 빈 틀 둘 — main.py 라우터 13 개는 끊음. B07 이 빌려 쓰던 비탈 길이·면적은 필요한 함수만 B07_DesignDetail_Engine_SlopeGeometry 로 옮겨 적음(면적 적분·노면 면적·측점 묶음은 안 옮김) · 시험 하나를 새로 둠. B07 구조물도 조립(Cad_StandardSheet)은 2026-09-13 에 이미 도면 목록에서 빠져 부르는 곳이 없어 old_code 로 같이 보냄 — 구조물 그림은 되살리지 않음. B06 구조물 몫 조회는 빈 값으로 두어 화면이 그대로 서게 함. B08·B09 를 부르던 시험 25 개도 old_code/resources/tester 로 옮김. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PAdA5ThqmtVSsbzjusk1cJ
26 lines
1.2 KiB
TypeScript
26 lines
1.2 KiB
TypeScript
/* =============================================================================
|
|
* B08_Quantity_Formula_Node.ts
|
|
* 구조물도 식 풀이를 **서버가** 돌리는 진입점 — [저장]·[확정] 때 정본으로 다시 풂.
|
|
*
|
|
* 풀이는 화면이 쓰는 `B08_Quantity_Formula.ts` 그대로(판정 Ⓐ, 2026-09-13) —
|
|
* B06 `B06_Section_Server_Calc_Node.ts` 와 같은 본. 여기에는 계산이 없음.
|
|
*
|
|
* 실행: node <번들> <입력.json> <출력.json>
|
|
* 입력 { sheets: FormulaSheet[] }
|
|
* 출력 { sheets: FormulaRowResult[][] } — 입력 장 차례 그대로
|
|
* 끝 코드: 0 성공 / 2 인자 오류
|
|
* ========================================================================== */
|
|
|
|
import { readFileSync, writeFileSync } from "node:fs";
|
|
import { evaluateSheet, type FormulaSheet } from "./B08_Quantity_Formula";
|
|
|
|
const [inputPath, outputPath] = process.argv.slice(2);
|
|
if (!inputPath || !outputPath) {
|
|
console.error("사용법: node <번들> <입력.json> <출력.json>");
|
|
process.exit(2);
|
|
}
|
|
|
|
const input = JSON.parse(readFileSync(inputPath, "utf8")) as { sheets?: FormulaSheet[] };
|
|
const sheets = (input.sheets ?? []).map((sheet) => evaluateSheet(sheet));
|
|
writeFileSync(outputPath, JSON.stringify({ sheets }));
|