diff --git a/M02_MasterTemplete/M02_MasterTemplete_Api_Fetch.ts b/M02_MasterTemplete/M02_MasterTemplete_Api_Fetch.ts index 8ae41196..384a3321 100644 --- a/M02_MasterTemplete/M02_MasterTemplete_Api_Fetch.ts +++ b/M02_MasterTemplete/M02_MasterTemplete_Api_Fetch.ts @@ -114,12 +114,25 @@ export const listStructures = async (): Promise => export const createStructure = (column: string): Promise => call(`/structures/${enc(column)}`, { method: "POST" }); -/** `{열 id: 도번}` — 집계표 도면 줄(없는 열은 키 없음 = 「없음」) */ -export const fetchStructureNumbers = (): Promise> => +/** 한 열의 번호 — 도번 `SD` · 표번 `SC` + 같은 6자리 [종류][분류1][분류2](없는 쪽은 빈 글) */ +export interface StructureNumbers { + 도번: string; + 표번: string; +} + +/** `{열 id: {도번, 표번}}` — 구조물 열만(글 열 · 없는 열은 키 없음 = 「없음」) */ +export const fetchStructureNumbers = (): Promise> => call("/structures/numbers"); -/** `{열 id: 표번}` — 좌측 산출근거 줄(도번과 같은 규칙 · 「표-01」 꼴) */ -export const fetchBasisNumbers = (): Promise> => call("/basis/numbers"); +/** 다른 열(`from`) 구조물 도면 내용을 받는 열(`column`)로 가져옴 — 도번 · 열은 받는 쪽 그대로 */ +export const copyStructure = async (column: string, from: string): Promise => { + await call(`/structures/${enc(column)}/copy?from=${enc(from)}`, { method: "POST" }); +}; + +/** 다른 열(`from`) 산출근거 내용을 받는 열(`column`)로 가져옴 — 표번 · 열은 받는 쪽 그대로 */ +export const copyBasis = async (column: string, from: string): Promise => { + await call(`/basis/${enc(column)}/copy?from=${enc(from)}`, { method: "POST" }); +}; /* --- 프로젝트 층 단추 다섯 --- */ const project = (id: string, tail: string): string => `/projects/${enc(id)}/templates/${tail}`; diff --git a/M02_MasterTemplete/M02_MasterTemplete_Router.py b/M02_MasterTemplete/M02_MasterTemplete_Router.py index ddb1b27d..68c2fadc 100644 --- a/M02_MasterTemplete/M02_MasterTemplete_Router.py +++ b/M02_MasterTemplete/M02_MasterTemplete_Router.py @@ -7,7 +7,7 @@ from __future__ import annotations from typing import Any -from fastapi import APIRouter, HTTPException +from fastapi import APIRouter, HTTPException, Query from pydantic import BaseModel from M02_MasterTemplete import M02_MasterTemplete_Store as store @@ -39,13 +39,20 @@ def get_structure_numbers() -> dict: @router.post("/structures/{column}") def post_structure(column: str) -> dict: - """구조물 도면 새로 — 열 id 하나 · 도번 자동 · A1 도각 + 빈 산출근거 표 · 이미 있으면 409.""" + """구조물 도면 새로 — 열 id 하나 · 도번 자동 · 빈 산출근거도 · 이미 있으면 409.""" return _call(store.create_structure, column) -@router.get("/basis/numbers") -def get_basis_numbers() -> dict: - return _call(store.basis_numbers) +@router.post("/structures/{column}/copy") +def post_structure_copy(column: str, source: str = Query(alias="from")) -> dict: + """다른 열 구조물 도면 내용을 가져옴 — 도번 · 열은 받는 쪽 그대로.""" + return _call(store.copy_structure, column, source) + + +@router.post("/basis/{column}/copy") +def post_basis_copy(column: str, source: str = Query(alias="from")) -> dict: + """다른 열 산출근거 내용을 가져옴 — 표번 · 열은 받는 쪽 그대로.""" + return _call(store.copy_basis, column, source) @router.get("/templates/{kind}/{name}") diff --git a/M02_MasterTemplete/M02_MasterTemplete_Store.py b/M02_MasterTemplete/M02_MasterTemplete_Store.py index 61f54cda..a11dbe62 100644 --- a/M02_MasterTemplete/M02_MasterTemplete_Store.py +++ b/M02_MasterTemplete/M02_MasterTemplete_Store.py @@ -20,8 +20,10 @@ from M02_MasterTemplete import M02_Template_Layers as layers FOLDER: Path = Path(__file__).resolve().parent.parent / "resources" / "master_template" KINDS = layers.KINDS # 시험은 FOLDER 를 사본으로 바꿈 -# 구조물 도면 = 구조물집계표 열 id 마다 하나(파일 이름 = 열 id) · 도각 없는 전용 화면(그린 만큼이 설계 영역) +# 구조물 도면 = 구조물집계표 구조물 열(꼴=수) 마다 하나(파일 이름 = 열 id) · 도각 없는 전용 화면 # 산출근거 = 같은 열 id 로 따로 한 파일(`basis/<열 id>.json` · 스프레드시트 통합문서) +# 번호 = 도번 SD · 표번 SC + 6자리 [종류][분류1][분류2](제목행 = 열 `머리` 세 층 · 없는 층 00) — +# 한 열의 두 번호는 같은 6자리 · 한 번 준 번호는 파일에 남아 안 바뀜(PLAN 12장) STRUCTURE_TABLE = "구조물집계표" _BASIS_HEAD = ("공종", "규격", "산출 내역", "단위", "수량(m당)") _BASIS_HEAD_STYLE = { @@ -30,8 +32,7 @@ _BASIS_HEAD_STYLE = { "세로": "center", "테두리": {side: {"선": "thin"} for side in ("위", "아래", "왼", "오른")}, } -_NUMBER = re.compile(r"^구-(\d+)$") -_TABLE_NUMBER = re.compile(r"^표-(\d+)$") +_CODE = re.compile(r"^S[DC](\d{6})$") _BAD_NAME = re.compile(r'[\\/:*?"<>|\x00-\x1f]|\.\.') # 도각 없는 빈 CAD 문서의 기본 도면층 — 없으면 B07 CAD 가 못 엶("Cannot read properties # of undefined (reading 'length')") · CAD 쪽도 없으면 새로 채우지만(2026-09-27 sub1 고침) @@ -93,8 +94,8 @@ def _check_skeleton(kind: str, doc: Any) -> None: def write(kind: str, name: str, version: str, doc: Any) -> dict[str, Any]: """`version` 이 빈 글이면 새로 만듦(이미 있으면 409) · 아니면 그 판일 때만 덮어씀. - 구조물집계표를 저장하면 — 새 열의 빈 구조물 도면 · 산출근거도 같이 만듦(잠금 밖에서 · - `create_structure` 가 다시 잠금을 잡으므로 안에서 부르면 죽음). + 구조물집계표를 저장하면 — 새 구조물 열의 빈 구조물 도면 · 산출근거를 번호와 같이 만들고 + 지운 열(또는 구조물이 아니게 된 열)의 두 파일을 지움(잠금 밖에서 · 안에서 부르면 죽음). 산출근거(basis)는 서버가 같은 TS 엔진을 Node 로 돌려 `계산값` 을 새로 적음 (브라우저 값 버림 · 5장 ②).""" path = _path(kind, name) @@ -108,7 +109,8 @@ def write(kind: str, name: str, version: str, doc: Any) -> dict[str, Any]: atomic_write_json(path, doc) info = _info(kind, path) if kind == "table" and name == STRUCTURE_TABLE: - backfill_missing_structures() + backfill_missing_structures() # 지우기 앞 — 같은 저장의 새 열이 지운 번호를 안 받게 + prune_removed_structures() return info @@ -130,46 +132,131 @@ def _structures() -> list[tuple[str, Any]]: return [(p.stem, json.loads(p.read_bytes())) for p in sorted(folder.glob("[!.]*.json"))] -def structure_numbers() -> dict[str, str | None]: - """`{열 id: 도번}` — 집계표 도면 줄이 한 번에 받음.""" - return { - name: (doc.get("도번") if isinstance(doc, dict) else None) for name, doc in _structures() - } +def _code(doc: Any, key: str) -> str | None: + """문서의 새 번호 6자리 — 옛 `구-01` · `표-01` · 없음은 None.""" + found = _CODE.match(str(doc.get(key) or "")) if isinstance(doc, dict) else None + return found.group(1) if found else None -def _number(doc: Any) -> int: - found = _NUMBER.match(str(doc.get("도번") or "")) if isinstance(doc, dict) else None - return int(found.group(1)) if found else 0 +def _codes() -> dict[str, str]: + """`{열 id: 6자리}` — 구조물 도면 도번 먼저 · 없으면 산출근거 표번.""" + codes = {name: c for name, doc in _basis_docs() if (c := _code(doc, "표번"))} + codes.update({name: c for name, doc in _structures() if (c := _code(doc, "도번"))}) + return codes + + +def structure_numbers() -> dict[str, dict[str, str]]: + """`{열 id: {도번, 표번}}` — 집계표 도면 · 산출근거 줄 · 좌측 줄이 한 번에 받음 + (없는 쪽은 빈 글).""" + out: dict[str, dict[str, str]] = {} + for name, doc in _structures(): + out.setdefault(name, {"도번": "", "표번": ""})["도번"] = str(doc.get("도번") or "") + for name, doc in _basis_docs(): + out.setdefault(name, {"도번": "", "표번": ""})["표번"] = str(doc.get("표번") or "") + return out + + +def _heads(col: dict[str, Any]) -> tuple[str | None, str | None, str | None]: + """제목행 세 층(종류 · 분류1 · 분류2) — 빈 층은 None.""" + parts = [*(col.get("머리") or []), None, None, None][:3] + clean = [str(p).strip() if p is not None else "" for p in parts] + return (clean[0] or None, clean[1] or None, clean[2] or None) + + +def _structure_columns() -> list[dict[str, Any]]: + """번호 · 파일을 받는 열 — 꼴=수(NO · 측점 · 비고 같은 글 열은 구조물 아님).""" + table = read("table", STRUCTURE_TABLE)["문서"] + return [ + col + for col in table.get("열", []) + if isinstance(col, dict) and col.get("id") and col.get("꼴") == "수" + ] def _column_ids() -> list[str]: - table = read("table", STRUCTURE_TABLE)["문서"] - return [col["id"] for col in table.get("열", []) if isinstance(col, dict) and col.get("id")] + return [col["id"] for col in _structure_columns()] + + +def _pick_code(col: dict[str, Any], taken: dict[str, str], heads: dict[str, tuple]) -> str: + """새 열 번호 — 같은 종류(· 분류1)가 이미 번호를 가졌으면 그 두 자리를 이어 받고 · 없으면 그 층 + 가장 큰 번호 + 1 · 빈 층은 00. 같은 6자리가 이미 있으면(같은 제목행 · 빈 분류2 겹침) 분류2 를 + 그 무리 가장 큰 번호 + 1 로. `taken` = 이미 번호 있는 열 `{열 id: 6자리}` · + `heads` = 열 id → 제목행.""" + kind, first, second = _heads(col) + codes = list(taken.values()) + mates = [(heads[cid], code) for cid, code in taken.items() if cid in heads] + + def next_of(prefix: str, at: slice) -> str: + found = [int(c[at]) for c in codes if c.startswith(prefix)] + return f"{max(found, default=0) + 1:02d}" + + k = next((c[:2] for h, c in mates if h[0] == kind), None) or next_of("", slice(0, 2)) + if first is None: + a = "00" + else: + same = (c[2:4] for h, c in mates if h[:2] == (kind, first) and c[:2] == k) + a = next(same, None) or next_of(k, slice(2, 4)) + b = "00" if second is None else next_of(k + a, slice(4, 6)) + if k + a + b in codes: + b = next_of(k + a, slice(4, 6)) + return k + a + b + + +def _new_code(column: str) -> str: + """이 열이 쓸 6자리 — 짝 파일에 이미 있으면 그것 · 없으면 새로(잠금 안에서 부름).""" + taken = _codes() + if column in taken: + return taken[column] + cols = _structure_columns() + col = next((c for c in cols if c["id"] == column), {"id": column}) + return _pick_code(col, taken, {c["id"]: _heads(c) for c in cols}) def create_structure(column: str) -> dict[str, Any]: - """열 id 하나의 구조물 도면 새로 — 도번 = 있는 것 중 가장 큰 번호 + 1 · 이미 있으면 409. + """구조물 열 하나의 구조물 도면 새로 — 도번 SD + 6자리(산출근거와 같은 6자리) · 이미 있으면 409. 산출근거 파일이 없으면 빈 통합문서도 같이 만듦.""" path = _path("structure", column) if column not in _column_ids(): - raise StoreError(404, f"{STRUCTURE_TABLE}에 없는 열 「{column}」") + raise StoreError(404, f"{STRUCTURE_TABLE}에 없는 구조물 열 「{column}」") with _LOCK: if path.is_file(): raise StoreError(409, f"이미 있는 구조물 도면 「{column}」") - number = max((_number(doc) for _name, doc in _structures()), default=0) + 1 - doc = { - "양식": "구조물도면", - "종류": "structure", - "판": 1, - "열": column, - "도번": f"구-{number:02d}", - "도면": {"format": 6, "entities": [], "layers": [dict(_BLANK_LAYER)]}, - } - atomic_write_json(path, doc) + atomic_write_json(path, {**_blank_structure(column), "도번": f"SD{_new_code(column)}"}) ensure_basis(column) return read("structure", column) +def _blank_structure(column: str) -> dict[str, Any]: + """빈 구조물 도면(도번은 부르는 쪽이 붙임) — 도각 없음 · 기본 도면층 하나.""" + return { + "양식": "구조물도면", + "종류": "structure", + "판": 1, + "열": column, + "도면": {"format": 6, "entities": [], "layers": [dict(_BLANK_LAYER)]}, + } + + +def copy_structure(column: str, source: str) -> dict[str, Any]: + """다른 열 구조물 도면 내용을 가져옴 — 도번 · 열은 받는 쪽 그대로(두 열은 따로 움직임).""" + return _copy("structure", column, source, ("열", "도번")) + + +def copy_basis(column: str, source: str) -> dict[str, Any]: + """다른 열 산출근거 내용을 가져옴 — 표번 · 열은 받는 쪽 그대로 · 계산값은 서버가 다시 풂.""" + return _copy("basis", column, source, ("열", "표번")) + + +def _copy(kind: str, column: str, source: str, keep: tuple[str, ...]) -> dict[str, Any]: + target = read(kind, column)["문서"] + doc = {**read(kind, source)["문서"], **{key: target.get(key) for key in keep}} + if kind == "basis": + doc = _server_values({k: v for k, v in doc.items() if k != "계산값"}) + with _LOCK: + atomic_write_json(_path(kind, column), doc) + return _info(kind, _path(kind, column)) + + # ── 산출근거 ────────────────────────────────────────── @@ -183,7 +270,7 @@ def _col_letters(index: int) -> str: def basis_doc(column: str, old: Any = None) -> dict[str, Any]: - """빈 산출근거 통합문서 — 1 행 머리(공종 · 규격 · 산출 내역 · 단위 · 수량(m당)). + """산출근거 통합문서 — 새로는 진짜 빈 시트(머리 줄 없음). `old` = 옛 구조물 문서 `산출근거` 표(열 · 줄) — 머리 글 · 칸 값 · 열 폭을 옮김 (옛 열 식은 없어 안 옮김).""" columns = old.get("열") if isinstance(old, dict) and isinstance(old.get("열"), list) else None @@ -192,7 +279,7 @@ def basis_doc(column: str, old: Any = None) -> dict[str, Any]: " ".join(str(h) for h in (c.get("머리") or []) if h) or c.get("id", "") for c in columns ] else: - heads, columns = list(_BASIS_HEAD), [] + heads, columns = [], [] cells: dict[str, Any] = { f"{_col_letters(i)}1": {"값": head, "서식": 1} for i, head in enumerate(heads) if head } @@ -216,7 +303,7 @@ def basis_doc(column: str, old: Any = None) -> dict[str, Any]: "종류": "통합문서", "판": 1, "열": column, - "서식": [{}, _BASIS_HEAD_STYLE], + "서식": [{}, _BASIS_HEAD_STYLE] if heads else [{}], "시트": [sheet], "활성": "s1", } @@ -227,40 +314,80 @@ def _basis_docs() -> list[tuple[str, Any]]: return [(p.stem, json.loads(p.read_bytes())) for p in sorted(folder.glob("[!.]*.json"))] -def _table_number(doc: Any) -> int: - found = _TABLE_NUMBER.match(str(doc.get("표번") or "")) if isinstance(doc, dict) else None - return int(found.group(1)) if found else 0 - - def ensure_basis(column: str, old: Any = None) -> bool: """산출근거 파일이 없으면 만듦(식 없는 새 문서라 `계산값` 없음 · 첫 [저장] 때 서버가 적음). - 표번 = 도번과 같은 규칙(있는 것 중 가장 큰 번호 + 1) · 만든 뒤로는 안 바뀜.""" + 표번 = SC + 구조물 도면과 같은 6자리 · 만든 뒤로는 안 바뀜.""" path = _path("basis", column) with _LOCK: if path.is_file(): return False - number = max((_table_number(doc) for _name, doc in _basis_docs()), default=0) + 1 - doc = {**basis_doc(column, old), "표번": f"표-{number:02d}"} + doc = {**basis_doc(column, old), "표번": f"SC{_new_code(column)}"} atomic_write_json(path, doc) return True -def basis_numbers() -> dict[str, str | None]: - """`{열 id: 표번}` — 좌측 산출근거 줄이 한 번에 받음. - 표번이 없는 옛 파일은 여기서 만나는 순서로 채움(도번 규칙과 같음).""" - docs = _basis_docs() - missing = [name for name, doc in docs if not (isinstance(doc, dict) and doc.get("표번"))] - if missing: - with _LOCK: - docs = _basis_docs() # 잠금 안에서 다시 읽음 — 그 사이 누가 채웠을 수 있음 - number = max((_table_number(doc) for _name, doc in docs), default=0) - for name, doc in docs: - if isinstance(doc, dict) and not doc.get("표번"): - number += 1 - doc["표번"] = f"표-{number:02d}" - atomic_write_json(_path("basis", name), doc) - docs = _basis_docs() - return {name: (doc.get("표번") if isinstance(doc, dict) else None) for name, doc in docs} +def _strip_default_head(doc: Any) -> bool: + """옛 빈 산출근거의 1 행 기본 머리(공종 · 규격 · 산출 내역 · 단위 · 수량(m당))를 지움 — + 다섯 칸이 모두 그 글일 때만(사용자가 고친 머리는 둠) · 머리 서식만 쓰였으면 서식 표도 비움.""" + sheets = doc.get("시트") if isinstance(doc, dict) else None + cells = sheets[0].get("칸") if isinstance(sheets, list) and sheets else None + keys = [f"{_col_letters(i)}1" for i in range(len(_BASIS_HEAD))] + if not isinstance(cells, dict) or [(cells.get(k) or {}).get("값") for k in keys] != list( + _BASIS_HEAD + ): + return False + for k in keys: + del cells[k] + if not any(isinstance(c, dict) and c.get("서식") for s in sheets for c in s["칸"].values()): + doc["서식"] = [{}] + return True + + +def prune_removed_structures() -> list[str]: + """집계표에서 지운 열(또는 구조물이 아니게 된 열)의 구조물 도면 · 산출근거를 같이 지움 — + 번호는 비워 둠(다른 열 번호를 안 당김).""" + keep = set(_column_ids()) + gone: list[str] = [] + with _LOCK: + for kind in ("structure", "basis"): + for path in sorted((FOLDER / kind).glob("[!.]*.json")): + if path.stem not in keep: + path.unlink() + gone.append(f"{kind}/{path.stem}") + return gone + + +def renumber() -> dict[str, list[str]]: + """한 번 — 옛 번호(구-NN · 표-NN · 없음)를 새 번호로(열 차례 = 종류 · 분류1 · 분류2 차례) · + 옛 빈 산출근거 기본 머리 줄 지움 · 구조물 아닌 열 파일 지움 · 빠진 파일 만듦. + 내용은 그대로 · 새 번호가 이미 있으면 그대로(두 번 돌려도 같음).""" + gone = prune_removed_structures() + changed: list[str] = [] + made: list[str] = [] + with _LOCK: + cols = _structure_columns() + heads = {c["id"]: _heads(c) for c in cols} + taken = _codes() + for col in cols: + if col["id"] not in taken: + taken[col["id"]] = _pick_code(col, taken, heads) + docs = {"structure": dict(_structures()), "basis": dict(_basis_docs())} + for col in cols: + cid = col["id"] + for kind, key, head in (("structure", "도번", "SD"), ("basis", "표번", "SC")): + number = f"{head}{taken[cid]}" + doc = docs[kind].get(cid) + if doc is None: + blank = _blank_structure(cid) if kind == "structure" else basis_doc(cid) + atomic_write_json(_path(kind, cid), {**blank, key: number}) + made.append(f"{kind}/{cid}") + continue + stripped = kind == "basis" and _strip_default_head(doc) + if doc.get(key) != number or stripped: + doc[key] = number + atomic_write_json(_path(kind, cid), doc) + changed.append(f"{kind}/{cid}") + return {"지움": gone, "바꿈": changed, "새로": made} def _server_values(doc: Any) -> dict[str, Any]: @@ -288,8 +415,8 @@ def migrate_basis() -> dict[str, list[str]]: def backfill_missing_structures() -> list[str]: - """구조물집계표 열마다 빈 구조물 도면 · 산출근거가 있게 — 없는 열만 열 차례로 새로 - 만듦(도번 이어서). + """구조물 열마다 빈 구조물 도면 · 산출근거가 있게 — 없는 열만 열 차례로 새로 + 만듦(그 무리 다음 번호). 그 사이 남이 만들었거나(409) 열 규칙에 안 맞으면(404) 그 열만 건너뜀.""" have = {name for name, _ in _structures()} made: list[str] = [] diff --git a/M02_MasterTemplete/M02_MasterTemplete_Structure.ts b/M02_MasterTemplete/M02_MasterTemplete_Structure.ts index ad0a7ce5..1ab16387 100644 --- a/M02_MasterTemplete/M02_MasterTemplete_Structure.ts +++ b/M02_MasterTemplete/M02_MasterTemplete_Structure.ts @@ -31,6 +31,7 @@ import { fetchStructureNumbers, readTemplate, type StructureDoc, + type StructureNumbers, } from "./M02_MasterTemplete_Api_Fetch"; import { mountDrawingTemplate, @@ -75,7 +76,7 @@ const fill = (text: string, value: string): string => text.replace("{value}", va const loadSpreadsheet = () => import("../A00_Common/spreadsheet/spreadsheet"); /** `{열 id: {도번, 표번}}` — 집계표 도면 · 산출근거 줄(없는 열은 키 없음 = 「없음」) */ -export type ColumnNumbers = Record; +export type ColumnNumbers = Record; /** 일위대가 목록 — 처음 한 번만 받음(못 받으면 다음에 다시) */ let combos: Promise | null = null; @@ -161,15 +162,23 @@ function choose(title: string, items: Choice[], clearable: boolean): Promise col.꼴 === "수"; + +/** 구조물 이름 + 변수값 — 제목행 층을 빈칸으로 이음(빈 층은 건너뜀 · 다 비면 열 id) */ export const columnHead = (col: StructureColumn): string => - col.머리.filter((part): part is string => !!part && part.trim() !== "").join(" · ") || col.id; + col.머리.filter((part): part is string => !!part && part.trim() !== "").join(" ") || col.id; + +/** 번호가 맨 앞 — 「SD010101 돌기슭막이 H=1.0」(번호가 없으면 이름만) */ +export const structureLabel = (number: string, col: StructureColumn): string => + [number, columnHead(col)].filter(Boolean).join(" "); export interface StructurePanelOptions { /** 시스템 관리자만 저장함(구조물 도면은 서버가 미리 만들어 둠) */ @@ -215,7 +224,7 @@ export function createStructurePanel(opts: StructurePanelOptions): StructurePane className: "m02-struct__card ui-collapsible ui-sidebar-section ui-sidebar-card", children: [ el("h3", { className: "ui-collapsible__title", text: TEXT.drawingInfo }), - el("div", { className: "m02-struct__head", children: [columnName, number, edit] }), + el("div", { className: "m02-struct__head", children: [number, columnName, edit] }), previewHost, ], }); @@ -314,7 +323,7 @@ export function createStructurePanel(opts: StructurePanelOptions): StructurePane column = col.id; columnLabel = columnHead(col); columnName.textContent = columnLabel; - number.textContent = numbers[col.id]?.도번 ?? TEXT.noNumber; + number.textContent = numbers[col.id]?.도번 || TEXT.noNumber; doc = null; basisDoc = null; basisNumber = ""; @@ -335,9 +344,11 @@ export function createStructurePanel(opts: StructurePanelOptions): StructurePane paintBody(mine); } + /** 글 열(NO · 측점 · 비고)은 구조물이 아니라 컨테이너를 닫음 */ const show = (colId: string | null, columns: StructureColumn[]): void => { - if (colId === column) return; - void load(colId ? (columns.find((c) => c.id === colId) ?? null) : null); + const col = columns.find((c) => c.id === colId && isStructureColumn(c)) ?? null; + if ((col?.id ?? null) === column) return; + void load(col); }; const pickPrice = async (colId: string, columns: StructureColumn[]): Promise => { diff --git a/M02_MasterTemplete/M02_MasterTemplete_UI_Main.ts b/M02_MasterTemplete/M02_MasterTemplete_UI_Main.ts index f226ae1c..1d6fb4a3 100644 --- a/M02_MasterTemplete/M02_MasterTemplete_UI_Main.ts +++ b/M02_MasterTemplete/M02_MasterTemplete_UI_Main.ts @@ -248,13 +248,13 @@ export function createMain(isAdmin: boolean, onSaved?: () => void): MainHandle { ) : got.문서; if (mine !== seq) return; - // 구조물 도면 · 산출근거는 열 id 로 열리니 머리에 도번 · 표번을 함께 보임 + // 구조물 도면 · 산출근거는 열 id 로 열리니 머리 맨 앞에 도번 · 표번(「SD010101 돌기슭막이 …」) if (next.kind === "structure") { const number = (got.문서 as StructureDoc)?.도번; - if (number) title.textContent = `${number} · ${next.label ?? next.name}`; + if (number) title.textContent = `${number} ${next.label ?? next.name}`; } else if (next.kind === "basis") { const number = (got.문서 as { 표번?: string })?.표번; - if (number) title.textContent = `${number} · ${next.label ?? next.name}`; + if (number) title.textContent = `${number} ${next.label ?? next.name}`; } await mount(shown, next); } catch (error) { diff --git a/M02_MasterTemplete/M02_MasterTemplete_UI_Side.ts b/M02_MasterTemplete/M02_MasterTemplete_UI_Side.ts index b21dceac..c39364c3 100644 --- a/M02_MasterTemplete/M02_MasterTemplete_UI_Side.ts +++ b/M02_MasterTemplete/M02_MasterTemplete_UI_Side.ts @@ -1,8 +1,8 @@ /* ============================================================================= * M02_MasterTemplete_UI_Side.ts * 마스터 템플릿 좌측 패널 — 시스템 양식 목록(표/도면/구조물 도면/산출근거) · 새로 · 본떠 · 지우기. - * 서버 길은 계약 `6_계약.md`. 구조물 도면 · 산출근거 줄은 집계표 열마다 하나씩 — - * 서버가 미리 만들어 둠(도번·표번 항상 있음 · 같은 번호 매기기 규칙). + * 서버 길은 계약 `6_계약.md`. 구조물 도면 · 산출근거 줄은 집계표 구조물 열(꼴=수)마다 하나씩 — + * 서버가 미리 만들어 둠(도번 SD · 표번 SC + 같은 6자리) · 줄 글은 번호가 맨 앞(「SD010101 돌기슭막이 …」). * ========================================================================== */ import { @@ -18,16 +18,22 @@ import { t as L } from "@ui/ui_template_locale"; import { openModal } from "@ui/ui_template_modal"; import { deleteTemplate, - fetchBasisNumbers, fetchStructureNumbers, listTemplates, readTemplate, saveTemplate, StaleError, type Kind, + type StructureNumbers, type TemplateInfo, } from "./M02_MasterTemplete_Api_Fetch"; -import { STRUCTURE_TABLE, columnHead, type StructureColumn } from "./M02_MasterTemplete_Structure"; +import { + STRUCTURE_TABLE, + columnHead, + isStructureColumn, + structureLabel, + type StructureColumn, +} from "./M02_MasterTemplete_Structure"; import { canEdit, type Selection } from "./M02_MasterTemplete_UI_Main"; const KINDS: { kind: Kind; label: () => string }[] = [ @@ -83,8 +89,7 @@ export function buildSide(opt: SideOptions): SideHandle { const layer = "system" as const; let items: TemplateInfo[] = []; let columns: StructureColumn[] = []; - let numbers: Record = {}; - let basisNumbers: Record = {}; + let numbers: Record = {}; let seq = 0; let picked: { kind: Kind; name: string } | null = null; @@ -153,41 +158,27 @@ export function buildSide(opt: SideOptions): SideHandle { } } - /** 구조물 도면 줄 — 집계표 열마다 하나(서버가 미리 만들어 둬 도번은 항상 있음) */ - function paintStructure(): void { - structureBody.replaceChildren( + /** 구조물 도면 · 산출근거 줄 — 구조물 열마다 하나 · 「번호 이름 변수값」(번호가 없으면 「없음」) */ + function paintRows(body: HTMLElement, kind: "structure" | "basis"): void { + body.replaceChildren( ...(columns.length ? columns.map((col) => { - const num = numbers[col.id] ?? L("M02_StructureNone"); + const num = + (kind === "structure" ? numbers[col.id]?.도번 : numbers[col.id]?.표번) || + L("M02_StructureNone"); const b = el("button", { - className: `m02-side__item ui-sidebar-row${isPicked("structure", col.id) ? " is-active" : ""}`, - text: `${columnHead(col)} · ${num}`, + className: `m02-side__item ui-sidebar-row${isPicked(kind, col.id) ? " is-active" : ""}`, + text: structureLabel(num, col), attrs: { type: "button" }, }); - b.addEventListener("click", () => void selectColumn(col)); - return b; - }) - : [el("p", { className: "m02-side__empty", text: L("M02_NoTemplates") })]), - ); - } - - /** 산출근거 줄 — 구조물 도면과 같은 열 목록 · 표번은 도번과 같은 규칙(서버가 미리 만들어 둠) */ - function paintBasis(): void { - basisBody.replaceChildren( - ...(columns.length - ? columns.map((col) => { - const num = basisNumbers[col.id] ?? L("M02_StructureNone"); - const b = el("button", { - className: `m02-side__item ui-sidebar-row${isPicked("basis", col.id) ? " is-active" : ""}`, - text: `${columnHead(col)} · ${num}`, - attrs: { type: "button" }, - }); - b.addEventListener("click", () => void selectBasisColumn(col)); + b.addEventListener("click", () => void selectColumn(col, kind)); return b; }) : [el("p", { className: "m02-side__empty", text: L("M02_NoTemplates") })]), ); } + const paintStructure = (): void => paintRows(structureBody, "structure"); + const paintBasis = (): void => paintRows(basisBody, "basis"); function paintButtons(): void { const editable = canEdit(layer, opt.isAdmin); @@ -204,25 +195,11 @@ export function buildSide(opt: SideOptions): SideHandle { paintButtons(); } - async function selectColumn(col: StructureColumn): Promise { - if (!isPicked("structure", col.id) && !(await opt.confirmLeave())) return; + async function selectColumn(col: StructureColumn, kind: "structure" | "basis"): Promise { + if (!isPicked(kind, col.id) && !(await opt.confirmLeave())) return; picked = null; - opt.onOpen({ - layer, - projectId: null, - kind: "structure", - name: col.id, - label: columnHead(col), - }); - paintStructure(); - paintBasis(); - paintButtons(); - } - - async function selectBasisColumn(col: StructureColumn): Promise { - if (!isPicked("basis", col.id) && !(await opt.confirmLeave())) return; - picked = null; - opt.onOpen({ layer, projectId: null, kind: "basis", name: col.id, label: columnHead(col) }); + // 제목은 편집 화면이 문서 번호를 앞에 붙임(「SD010101 돌기슭막이 …」) + opt.onOpen({ layer, projectId: null, kind, name: col.id, label: columnHead(col) }); paintStructure(); paintBasis(); paintButtons(); @@ -230,18 +207,16 @@ export function buildSide(opt: SideOptions): SideHandle { async function refreshStructure(): Promise { try { - const [table, nums, basisNums] = await Promise.all([ + const [table, nums] = await Promise.all([ readTemplate(layer, "table", STRUCTURE_TABLE, null), fetchStructureNumbers(), - fetchBasisNumbers(), ]); - columns = ((table.문서 as { 열?: StructureColumn[] }).열 ?? []) as StructureColumn[]; + const all = ((table.문서 as { 열?: StructureColumn[] }).열 ?? []) as StructureColumn[]; + columns = all.filter(isStructureColumn); numbers = nums; - basisNumbers = basisNums; } catch (error) { columns = []; numbers = {}; - basisNumbers = {}; showToast(L("M02_LoadFailed").replace("{value}", why(error)), "error"); } paintStructure(); diff --git a/resources/master_template/basis/be.json b/resources/master_template/basis/be.json index dfea20aa..92bbbab7 100644 --- a/resources/master_template/basis/be.json +++ b/resources/master_template/basis/be.json @@ -3,55 +3,15 @@ "판": 1, "열": "be", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-01" + "표번": "SC140000" } diff --git a/resources/master_template/basis/bg.json b/resources/master_template/basis/bg.json index 6a72563b..a6f5127f 100644 --- a/resources/master_template/basis/bg.json +++ b/resources/master_template/basis/bg.json @@ -3,55 +3,15 @@ "판": 1, "열": "bg", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-02" + "표번": "SC220000" } diff --git a/resources/master_template/basis/bm_area.json b/resources/master_template/basis/bm_area.json index 1b29ee01..34d471af 100644 --- a/resources/master_template/basis/bm_area.json +++ b/resources/master_template/basis/bm_area.json @@ -3,55 +3,15 @@ "판": 1, "열": "bm_area", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-03" + "표번": "SC120102" } diff --git a/resources/master_template/basis/bm_len.json b/resources/master_template/basis/bm_len.json index 4a74736d..70a17b41 100644 --- a/resources/master_template/basis/bm_len.json +++ b/resources/master_template/basis/bm_len.json @@ -3,55 +3,15 @@ "판": 1, "열": "bm_len", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-04" + "표번": "SC120101" } diff --git a/resources/master_template/basis/bx_len.json b/resources/master_template/basis/bx_len.json index 9c0bd754..08661a29 100644 --- a/resources/master_template/basis/bx_len.json +++ b/resources/master_template/basis/bx_len.json @@ -3,55 +3,15 @@ "판": 1, "열": "bx_len", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-05" + "표번": "SC050101" } diff --git a/resources/master_template/basis/bx_wing.json b/resources/master_template/basis/bx_wing.json index 1e0217a7..c658c055 100644 --- a/resources/master_template/basis/bx_wing.json +++ b/resources/master_template/basis/bx_wing.json @@ -3,55 +3,15 @@ "판": 1, "열": "bx_wing", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-06" + "표번": "SC050102" } diff --git a/resources/master_template/basis/cs.json b/resources/master_template/basis/cs.json index e96e31c6..7ad48cc8 100644 --- a/resources/master_template/basis/cs.json +++ b/resources/master_template/basis/cs.json @@ -3,55 +3,15 @@ "판": 1, "열": "cs", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-07" + "표번": "SC240000" } diff --git a/resources/master_template/basis/ec.json b/resources/master_template/basis/ec.json index 645360cb..2a2659f4 100644 --- a/resources/master_template/basis/ec.json +++ b/resources/master_template/basis/ec.json @@ -3,55 +3,15 @@ "판": 1, "열": "ec", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-08" + "표번": "SC130100" } diff --git a/resources/master_template/basis/etc.json b/resources/master_template/basis/etc.json index 11514e22..5352f91f 100644 --- a/resources/master_template/basis/etc.json +++ b/resources/master_template/basis/etc.json @@ -3,55 +3,15 @@ "판": 1, "열": "etc", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-09" + "표번": "SC250100" } diff --git a/resources/master_template/basis/fb.json b/resources/master_template/basis/fb.json index 1a6d5193..dacd951b 100644 --- a/resources/master_template/basis/fb.json +++ b/resources/master_template/basis/fb.json @@ -3,55 +3,15 @@ "판": 1, "열": "fb", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-10" + "표번": "SC060100" } diff --git a/resources/master_template/basis/fp_l.json b/resources/master_template/basis/fp_l.json index fa43c4a9..fdbc1fc6 100644 --- a/resources/master_template/basis/fp_l.json +++ b/resources/master_template/basis/fp_l.json @@ -3,55 +3,15 @@ "판": 1, "열": "fp_l", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-11" + "표번": "SC070102" } diff --git a/resources/master_template/basis/fp_w.json b/resources/master_template/basis/fp_w.json index 4611a5c2..94c7328f 100644 --- a/resources/master_template/basis/fp_w.json +++ b/resources/master_template/basis/fp_w.json @@ -3,55 +3,15 @@ "판": 1, "열": "fp_w", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-12" + "표번": "SC070101" } diff --git a/resources/master_template/basis/gr_curb.json b/resources/master_template/basis/gr_curb.json index 2972a54f..d6237649 100644 --- a/resources/master_template/basis/gr_curb.json +++ b/resources/master_template/basis/gr_curb.json @@ -3,55 +3,15 @@ "판": 1, "열": "gr_curb", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-13" + "표번": "SC190000" } diff --git a/resources/master_template/basis/gr_rail.json b/resources/master_template/basis/gr_rail.json index f5e3b906..5fd16e33 100644 --- a/resources/master_template/basis/gr_rail.json +++ b/resources/master_template/basis/gr_rail.json @@ -3,55 +3,15 @@ "판": 1, "열": "gr_rail", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-14" + "표번": "SC180000" } diff --git a/resources/master_template/basis/gr_sign.json b/resources/master_template/basis/gr_sign.json index 5fa9c39c..242ae285 100644 --- a/resources/master_template/basis/gr_sign.json +++ b/resources/master_template/basis/gr_sign.json @@ -3,55 +3,15 @@ "판": 1, "열": "gr_sign", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-15" + "표번": "SC200000" } diff --git a/resources/master_template/basis/h_break.json b/resources/master_template/basis/h_break.json index 7134d351..c1fbfd28 100644 --- a/resources/master_template/basis/h_break.json +++ b/resources/master_template/basis/h_break.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_break", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-16" + "표번": "SC350000" } diff --git a/resources/master_template/basis/h_ford_basin.json b/resources/master_template/basis/h_ford_basin.json index 5c621143..3593025a 100644 --- a/resources/master_template/basis/h_ford_basin.json +++ b/resources/master_template/basis/h_ford_basin.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_ford_basin", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-17" + "표번": "SC330000" } diff --git a/resources/master_template/basis/h_intake.json b/resources/master_template/basis/h_intake.json index ac1ec71a..8218949f 100644 --- a/resources/master_template/basis/h_intake.json +++ b/resources/master_template/basis/h_intake.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_intake", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-18" + "표번": "SC260000" } diff --git a/resources/master_template/basis/h_pg_rail.json b/resources/master_template/basis/h_pg_rail.json index 31c6f620..380c366b 100644 --- a/resources/master_template/basis/h_pg_rail.json +++ b/resources/master_template/basis/h_pg_rail.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_pg_rail", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-19" + "표번": "SC310000" } diff --git a/resources/master_template/basis/h_pv_rail.json b/resources/master_template/basis/h_pv_rail.json index 080c14eb..db6f0a0f 100644 --- a/resources/master_template/basis/h_pv_rail.json +++ b/resources/master_template/basis/h_pv_rail.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_pv_rail", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-20" + "표번": "SC300000" } diff --git a/resources/master_template/basis/h_rip_c.json b/resources/master_template/basis/h_rip_c.json index 4a7be6fa..a1abe95e 100644 --- a/resources/master_template/basis/h_rip_c.json +++ b/resources/master_template/basis/h_rip_c.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_rip_c", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-21" + "표번": "SC270100" } diff --git a/resources/master_template/basis/h_rip_m.json b/resources/master_template/basis/h_rip_m.json index 26bdf29e..dd698093 100644 --- a/resources/master_template/basis/h_rip_m.json +++ b/resources/master_template/basis/h_rip_m.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_rip_m", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-22" + "표번": "SC270200" } diff --git a/resources/master_template/basis/h_rockfall.json b/resources/master_template/basis/h_rockfall.json index 9f604788..80e86810 100644 --- a/resources/master_template/basis/h_rockfall.json +++ b/resources/master_template/basis/h_rockfall.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_rockfall", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-23" + "표번": "SC340000" } diff --git a/resources/master_template/basis/h_soil_ditch.json b/resources/master_template/basis/h_soil_ditch.json index 78775ef0..53d64056 100644 --- a/resources/master_template/basis/h_soil_ditch.json +++ b/resources/master_template/basis/h_soil_ditch.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_soil_ditch", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-24" + "표번": "SC320000" } diff --git a/resources/master_template/basis/h_stone_bed.json b/resources/master_template/basis/h_stone_bed.json index 67c7e5ba..18b3dde7 100644 --- a/resources/master_template/basis/h_stone_bed.json +++ b/resources/master_template/basis/h_stone_bed.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_stone_bed", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-25" + "표번": "SC290000" } diff --git a/resources/master_template/basis/h_stone_ch.json b/resources/master_template/basis/h_stone_ch.json index 62958197..738870ef 100644 --- a/resources/master_template/basis/h_stone_ch.json +++ b/resources/master_template/basis/h_stone_ch.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_stone_ch", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-26" + "표번": "SC280000" } diff --git a/resources/master_template/basis/h_waste.json b/resources/master_template/basis/h_waste.json index 9a0c7ada..ac2d647c 100644 --- a/resources/master_template/basis/h_waste.json +++ b/resources/master_template/basis/h_waste.json @@ -3,55 +3,15 @@ "판": 1, "열": "h_waste", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-27" + "표번": "SC360000" } diff --git a/resources/master_template/basis/memo.json b/resources/master_template/basis/memo.json deleted file mode 100644 index 2a2cc430..00000000 --- a/resources/master_template/basis/memo.json +++ /dev/null @@ -1,57 +0,0 @@ -{ - "종류": "통합문서", - "판": 1, - "열": "memo", - "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } - ], - "시트": [ - { - "id": "s1", - "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } - } - ], - "활성": "s1", - "표번": "표-28" -} diff --git a/resources/master_template/basis/mr.json b/resources/master_template/basis/mr.json index af631fc8..92626d18 100644 --- a/resources/master_template/basis/mr.json +++ b/resources/master_template/basis/mr.json @@ -3,55 +3,15 @@ "판": 1, "열": "mr", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-29" + "표번": "SC210000" } diff --git a/resources/master_template/basis/ms.json b/resources/master_template/basis/ms.json index 3fae50e8..eb82b8c6 100644 --- a/resources/master_template/basis/ms.json +++ b/resources/master_template/basis/ms.json @@ -3,55 +3,15 @@ "판": 1, "열": "ms", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-30" + "표번": "SC100101" } diff --git a/resources/master_template/basis/no.json b/resources/master_template/basis/no.json deleted file mode 100644 index aa7985cc..00000000 --- a/resources/master_template/basis/no.json +++ /dev/null @@ -1,57 +0,0 @@ -{ - "종류": "통합문서", - "판": 1, - "열": "no", - "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } - ], - "시트": [ - { - "id": "s1", - "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } - } - ], - "활성": "s1", - "표번": "표-31" -} diff --git a/resources/master_template/basis/od_cnt.json b/resources/master_template/basis/od_cnt.json index 18cd83b9..a5537316 100644 --- a/resources/master_template/basis/od_cnt.json +++ b/resources/master_template/basis/od_cnt.json @@ -3,55 +3,15 @@ "판": 1, "열": "od_cnt", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-32" + "표번": "SC080102" } diff --git a/resources/master_template/basis/od_len.json b/resources/master_template/basis/od_len.json index 3672007f..c703669f 100644 --- a/resources/master_template/basis/od_len.json +++ b/resources/master_template/basis/od_len.json @@ -3,55 +3,15 @@ "판": 1, "열": "od_len", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-33" + "표번": "SC080101" } diff --git a/resources/master_template/basis/pg_in.json b/resources/master_template/basis/pg_in.json index e092e26a..afd33d21 100644 --- a/resources/master_template/basis/pg_in.json +++ b/resources/master_template/basis/pg_in.json @@ -3,56 +3,16 @@ "판": 1, "열": "pg_in", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-34", + "표번": "SC040101", "계산값": {} } diff --git a/resources/master_template/basis/pp_cp.json b/resources/master_template/basis/pp_cp.json index 77ca0428..a453ee06 100644 --- a/resources/master_template/basis/pp_cp.json +++ b/resources/master_template/basis/pp_cp.json @@ -3,55 +3,15 @@ "판": 1, "열": "pp_cp", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-35" + "표번": "SC030102" } diff --git a/resources/master_template/basis/pp_len.json b/resources/master_template/basis/pp_len.json index 6265d1e3..b4b8908f 100644 --- a/resources/master_template/basis/pp_len.json +++ b/resources/master_template/basis/pp_len.json @@ -3,55 +3,15 @@ "판": 1, "열": "pp_len", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-36" + "표번": "SC030101" } diff --git a/resources/master_template/basis/ps.json b/resources/master_template/basis/ps.json index dcab53ab..bb23548f 100644 --- a/resources/master_template/basis/ps.json +++ b/resources/master_template/basis/ps.json @@ -3,55 +3,15 @@ "판": 1, "열": "ps", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-37" + "표번": "SC230000" } diff --git a/resources/master_template/basis/pv_a.json b/resources/master_template/basis/pv_a.json index 62ec59d7..04632b29 100644 --- a/resources/master_template/basis/pv_a.json +++ b/resources/master_template/basis/pv_a.json @@ -3,55 +3,15 @@ "판": 1, "열": "pv_a", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-38" + "표번": "SC020104" } diff --git a/resources/master_template/basis/pv_b.json b/resources/master_template/basis/pv_b.json index 581bd756..a4604c77 100644 --- a/resources/master_template/basis/pv_b.json +++ b/resources/master_template/basis/pv_b.json @@ -3,55 +3,15 @@ "판": 1, "열": "pv_b", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-39" + "표번": "SC020101" } diff --git a/resources/master_template/basis/pv_jt.json b/resources/master_template/basis/pv_jt.json index d5d49f2d..e345b722 100644 --- a/resources/master_template/basis/pv_jt.json +++ b/resources/master_template/basis/pv_jt.json @@ -3,55 +3,15 @@ "판": 1, "열": "pv_jt", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-40" + "표번": "SC020105" } diff --git a/resources/master_template/basis/pv_l.json b/resources/master_template/basis/pv_l.json index 7e8dc0c5..0f8b3e6d 100644 --- a/resources/master_template/basis/pv_l.json +++ b/resources/master_template/basis/pv_l.json @@ -3,55 +3,15 @@ "판": 1, "열": "pv_l", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-41" + "표번": "SC020102" } diff --git a/resources/master_template/basis/pv_w.json b/resources/master_template/basis/pv_w.json index c45478c2..d07558c1 100644 --- a/resources/master_template/basis/pv_w.json +++ b/resources/master_template/basis/pv_w.json @@ -3,55 +3,15 @@ "판": 1, "열": "pv_w", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-42" + "표번": "SC020103" } diff --git a/resources/master_template/basis/rf.json b/resources/master_template/basis/rf.json index 9f1948a7..f57b9541 100644 --- a/resources/master_template/basis/rf.json +++ b/resources/master_template/basis/rf.json @@ -3,55 +3,15 @@ "판": 1, "열": "rf", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-43" + "표번": "SC150000" } diff --git a/resources/master_template/basis/rv.json b/resources/master_template/basis/rv.json index e10dcaad..0e1c7b5a 100644 --- a/resources/master_template/basis/rv.json +++ b/resources/master_template/basis/rv.json @@ -3,55 +3,15 @@ "판": 1, "열": "rv", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-44" + "표번": "SC010101" } diff --git a/resources/master_template/basis/rw.json b/resources/master_template/basis/rw.json index be1d59d6..9bf448fe 100644 --- a/resources/master_template/basis/rw.json +++ b/resources/master_template/basis/rw.json @@ -3,55 +3,15 @@ "판": 1, "열": "rw", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-45" + "표번": "SC090101" } diff --git a/resources/master_template/basis/sg.json b/resources/master_template/basis/sg.json index 3acfffa3..27ca6f50 100644 --- a/resources/master_template/basis/sg.json +++ b/resources/master_template/basis/sg.json @@ -3,55 +3,15 @@ "판": 1, "열": "sg", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-46" + "표번": "SC110101" } diff --git a/resources/master_template/basis/sta.json b/resources/master_template/basis/sta.json deleted file mode 100644 index f95ee33c..00000000 --- a/resources/master_template/basis/sta.json +++ /dev/null @@ -1,57 +0,0 @@ -{ - "종류": "통합문서", - "판": 1, - "열": "sta", - "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } - ], - "시트": [ - { - "id": "s1", - "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } - } - ], - "활성": "s1", - "표번": "표-47" -} diff --git a/resources/master_template/basis/ta.json b/resources/master_template/basis/ta.json index d75dda53..25daee59 100644 --- a/resources/master_template/basis/ta.json +++ b/resources/master_template/basis/ta.json @@ -3,55 +3,15 @@ "판": 1, "열": "ta", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-48" + "표번": "SC170000" } diff --git a/resources/master_template/basis/wy.json b/resources/master_template/basis/wy.json index e7f1ae27..8f8b8449 100644 --- a/resources/master_template/basis/wy.json +++ b/resources/master_template/basis/wy.json @@ -3,55 +3,15 @@ "판": 1, "열": "wy", "서식": [ - {}, - { - "굵게": true, - "가로": "center", - "세로": "center", - "테두리": { - "위": { - "선": "thin" - }, - "아래": { - "선": "thin" - }, - "왼": { - "선": "thin" - }, - "오른": { - "선": "thin" - } - } - } + {} ], "시트": [ { "id": "s1", "이름": "산출근거", - "칸": { - "A1": { - "값": "공종", - "서식": 1 - }, - "B1": { - "값": "규격", - "서식": 1 - }, - "C1": { - "값": "산출 내역", - "서식": 1 - }, - "D1": { - "값": "단위", - "서식": 1 - }, - "E1": { - "값": "수량(m당)", - "서식": 1 - } - } + "칸": {} } ], "활성": "s1", - "표번": "표-49" + "표번": "SC160000" } diff --git a/resources/master_template/structure/be.json b/resources/master_template/structure/be.json index 816e6161..fbae74f6 100644 --- a/resources/master_template/structure/be.json +++ b/resources/master_template/structure/be.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "be", - "도번": "구-25", + "도번": "SD140000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/bg.json b/resources/master_template/structure/bg.json index 38da2c65..fe5d99b4 100644 --- a/resources/master_template/structure/bg.json +++ b/resources/master_template/structure/bg.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "bg", - "도번": "구-33", + "도번": "SD220000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/bm_area.json b/resources/master_template/structure/bm_area.json index e967ce94..0638ee0c 100644 --- a/resources/master_template/structure/bm_area.json +++ b/resources/master_template/structure/bm_area.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "bm_area", - "도번": "구-23", + "도번": "SD120102", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/bm_len.json b/resources/master_template/structure/bm_len.json index 2d58b811..dae5163a 100644 --- a/resources/master_template/structure/bm_len.json +++ b/resources/master_template/structure/bm_len.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "bm_len", - "도번": "구-22", + "도번": "SD120101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/bx_len.json b/resources/master_template/structure/bx_len.json index 404132e7..6699c3cf 100644 --- a/resources/master_template/structure/bx_len.json +++ b/resources/master_template/structure/bx_len.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "bx_len", - "도번": "구-12", + "도번": "SD050101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/bx_wing.json b/resources/master_template/structure/bx_wing.json index 989810ec..9e82ebcc 100644 --- a/resources/master_template/structure/bx_wing.json +++ b/resources/master_template/structure/bx_wing.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "bx_wing", - "도번": "구-13", + "도번": "SD050102", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/cs.json b/resources/master_template/structure/cs.json index e94a7221..c9590022 100644 --- a/resources/master_template/structure/cs.json +++ b/resources/master_template/structure/cs.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "cs", - "도번": "구-35", + "도번": "SD240000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/ec.json b/resources/master_template/structure/ec.json index 6e5fc283..8a94595d 100644 --- a/resources/master_template/structure/ec.json +++ b/resources/master_template/structure/ec.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "ec", - "도번": "구-24", + "도번": "SD130100", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/etc.json b/resources/master_template/structure/etc.json index aa34ef10..2ec18f64 100644 --- a/resources/master_template/structure/etc.json +++ b/resources/master_template/structure/etc.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "etc", - "도번": "구-36", + "도번": "SD250100", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/fb.json b/resources/master_template/structure/fb.json index 50a7f179..b4fd3de7 100644 --- a/resources/master_template/structure/fb.json +++ b/resources/master_template/structure/fb.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "fb", - "도번": "구-14", + "도번": "SD060100", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/fp_l.json b/resources/master_template/structure/fp_l.json index 216d0344..66088307 100644 --- a/resources/master_template/structure/fp_l.json +++ b/resources/master_template/structure/fp_l.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "fp_l", - "도번": "구-16", + "도번": "SD070102", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/fp_w.json b/resources/master_template/structure/fp_w.json index 6b4ea5fa..dc09272f 100644 --- a/resources/master_template/structure/fp_w.json +++ b/resources/master_template/structure/fp_w.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "fp_w", - "도번": "구-15", + "도번": "SD070101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/gr_curb.json b/resources/master_template/structure/gr_curb.json index a2a55ce9..501ccff2 100644 --- a/resources/master_template/structure/gr_curb.json +++ b/resources/master_template/structure/gr_curb.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "gr_curb", - "도번": "구-30", + "도번": "SD190000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/gr_rail.json b/resources/master_template/structure/gr_rail.json index f11eca4a..cd1435d8 100644 --- a/resources/master_template/structure/gr_rail.json +++ b/resources/master_template/structure/gr_rail.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "gr_rail", - "도번": "구-29", + "도번": "SD180000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/gr_sign.json b/resources/master_template/structure/gr_sign.json index 1992f3fe..0eb61570 100644 --- a/resources/master_template/structure/gr_sign.json +++ b/resources/master_template/structure/gr_sign.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "gr_sign", - "도번": "구-31", + "도번": "SD200000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_break.json b/resources/master_template/structure/h_break.json index e286404f..e2fbc94e 100644 --- a/resources/master_template/structure/h_break.json +++ b/resources/master_template/structure/h_break.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_break", - "도번": "구-47", + "도번": "SD350000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_ford_basin.json b/resources/master_template/structure/h_ford_basin.json index 04ae088b..4afa6df1 100644 --- a/resources/master_template/structure/h_ford_basin.json +++ b/resources/master_template/structure/h_ford_basin.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_ford_basin", - "도번": "구-45", + "도번": "SD330000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_intake.json b/resources/master_template/structure/h_intake.json index c6fe90db..deda7fad 100644 --- a/resources/master_template/structure/h_intake.json +++ b/resources/master_template/structure/h_intake.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_intake", - "도번": "구-37", + "도번": "SD260000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_pg_rail.json b/resources/master_template/structure/h_pg_rail.json index bff75d82..504db802 100644 --- a/resources/master_template/structure/h_pg_rail.json +++ b/resources/master_template/structure/h_pg_rail.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_pg_rail", - "도번": "구-43", + "도번": "SD310000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_pv_rail.json b/resources/master_template/structure/h_pv_rail.json index 07592528..1bd0c9cd 100644 --- a/resources/master_template/structure/h_pv_rail.json +++ b/resources/master_template/structure/h_pv_rail.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_pv_rail", - "도번": "구-42", + "도번": "SD300000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_rip_c.json b/resources/master_template/structure/h_rip_c.json index b119a7d6..e6204c3f 100644 --- a/resources/master_template/structure/h_rip_c.json +++ b/resources/master_template/structure/h_rip_c.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_rip_c", - "도번": "구-38", + "도번": "SD270100", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_rip_m.json b/resources/master_template/structure/h_rip_m.json index 57fcb5a2..13019607 100644 --- a/resources/master_template/structure/h_rip_m.json +++ b/resources/master_template/structure/h_rip_m.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_rip_m", - "도번": "구-39", + "도번": "SD270200", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_rockfall.json b/resources/master_template/structure/h_rockfall.json index b6fa2417..2b9f3dd2 100644 --- a/resources/master_template/structure/h_rockfall.json +++ b/resources/master_template/structure/h_rockfall.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_rockfall", - "도번": "구-46", + "도번": "SD340000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_soil_ditch.json b/resources/master_template/structure/h_soil_ditch.json index 643bca97..1501ab68 100644 --- a/resources/master_template/structure/h_soil_ditch.json +++ b/resources/master_template/structure/h_soil_ditch.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_soil_ditch", - "도번": "구-44", + "도번": "SD320000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_stone_bed.json b/resources/master_template/structure/h_stone_bed.json index a1719680..b41730c7 100644 --- a/resources/master_template/structure/h_stone_bed.json +++ b/resources/master_template/structure/h_stone_bed.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_stone_bed", - "도번": "구-41", + "도번": "SD290000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_stone_ch.json b/resources/master_template/structure/h_stone_ch.json index 377d7206..7d069deb 100644 --- a/resources/master_template/structure/h_stone_ch.json +++ b/resources/master_template/structure/h_stone_ch.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_stone_ch", - "도번": "구-40", + "도번": "SD280000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/h_waste.json b/resources/master_template/structure/h_waste.json index c89e4075..5f796566 100644 --- a/resources/master_template/structure/h_waste.json +++ b/resources/master_template/structure/h_waste.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "h_waste", - "도번": "구-48", + "도번": "SD360000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/memo.json b/resources/master_template/structure/memo.json deleted file mode 100644 index 84f694ac..00000000 --- a/resources/master_template/structure/memo.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "양식": "구조물도면", - "종류": "structure", - "판": 1, - "열": "memo", - "도번": "구-49", - "도면": { - "format": 6, - "entities": [], - "layers": [ - { - "id": "기본", - "name": "기본", - "isVisible": true, - "isLocked": false - } - ] - } -} diff --git a/resources/master_template/structure/mr.json b/resources/master_template/structure/mr.json index d260d2a5..5a6813ec 100644 --- a/resources/master_template/structure/mr.json +++ b/resources/master_template/structure/mr.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "mr", - "도번": "구-32", + "도번": "SD210000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/ms.json b/resources/master_template/structure/ms.json index c91f50ef..3ffedeca 100644 --- a/resources/master_template/structure/ms.json +++ b/resources/master_template/structure/ms.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "ms", - "도번": "구-20", + "도번": "SD100101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/no.json b/resources/master_template/structure/no.json deleted file mode 100644 index 94d29720..00000000 --- a/resources/master_template/structure/no.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "양식": "구조물도면", - "종류": "structure", - "판": 1, - "열": "no", - "도번": "구-01", - "도면": { - "format": 6, - "entities": [], - "layers": [ - { - "id": "기본", - "name": "기본", - "isVisible": true, - "isLocked": false - } - ] - } -} diff --git a/resources/master_template/structure/od_cnt.json b/resources/master_template/structure/od_cnt.json index ee4e3112..5dac7962 100644 --- a/resources/master_template/structure/od_cnt.json +++ b/resources/master_template/structure/od_cnt.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "od_cnt", - "도번": "구-18", + "도번": "SD080102", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/od_len.json b/resources/master_template/structure/od_len.json index 4469b206..67f2a421 100644 --- a/resources/master_template/structure/od_len.json +++ b/resources/master_template/structure/od_len.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "od_len", - "도번": "구-17", + "도번": "SD080101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pg_in.json b/resources/master_template/structure/pg_in.json index 86bf15e2..7a40aa0f 100644 --- a/resources/master_template/structure/pg_in.json +++ b/resources/master_template/structure/pg_in.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pg_in", - "도번": "구-11", + "도번": "SD040101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pp_cp.json b/resources/master_template/structure/pp_cp.json index 3d19815b..b649235a 100644 --- a/resources/master_template/structure/pp_cp.json +++ b/resources/master_template/structure/pp_cp.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pp_cp", - "도번": "구-10", + "도번": "SD030102", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pp_len.json b/resources/master_template/structure/pp_len.json index ea38b17c..dd3dcbe8 100644 --- a/resources/master_template/structure/pp_len.json +++ b/resources/master_template/structure/pp_len.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pp_len", - "도번": "구-09", + "도번": "SD030101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/ps.json b/resources/master_template/structure/ps.json index e867c8e1..7cedc89f 100644 --- a/resources/master_template/structure/ps.json +++ b/resources/master_template/structure/ps.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "ps", - "도번": "구-34", + "도번": "SD230000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pv_a.json b/resources/master_template/structure/pv_a.json index 0412d82f..8eae7878 100644 --- a/resources/master_template/structure/pv_a.json +++ b/resources/master_template/structure/pv_a.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pv_a", - "도번": "구-07", + "도번": "SD020104", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pv_b.json b/resources/master_template/structure/pv_b.json index 426eb421..b2828aec 100644 --- a/resources/master_template/structure/pv_b.json +++ b/resources/master_template/structure/pv_b.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pv_b", - "도번": "구-04", + "도번": "SD020101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pv_jt.json b/resources/master_template/structure/pv_jt.json index 3f488892..b0485435 100644 --- a/resources/master_template/structure/pv_jt.json +++ b/resources/master_template/structure/pv_jt.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pv_jt", - "도번": "구-08", + "도번": "SD020105", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pv_l.json b/resources/master_template/structure/pv_l.json index 8a9954e2..87115c65 100644 --- a/resources/master_template/structure/pv_l.json +++ b/resources/master_template/structure/pv_l.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pv_l", - "도번": "구-05", + "도번": "SD020102", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/pv_w.json b/resources/master_template/structure/pv_w.json index 022c985f..4a210baa 100644 --- a/resources/master_template/structure/pv_w.json +++ b/resources/master_template/structure/pv_w.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "pv_w", - "도번": "구-06", + "도번": "SD020103", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/rf.json b/resources/master_template/structure/rf.json index c54858b3..c1f3a339 100644 --- a/resources/master_template/structure/rf.json +++ b/resources/master_template/structure/rf.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "rf", - "도번": "구-26", + "도번": "SD150000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/rv.json b/resources/master_template/structure/rv.json index 6b51501d..afbed06e 100644 --- a/resources/master_template/structure/rv.json +++ b/resources/master_template/structure/rv.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "rv", - "도번": "구-03", + "도번": "SD010101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/rw.json b/resources/master_template/structure/rw.json index 20b14af2..93b54d4e 100644 --- a/resources/master_template/structure/rw.json +++ b/resources/master_template/structure/rw.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "rw", - "도번": "구-19", + "도번": "SD090101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/sg.json b/resources/master_template/structure/sg.json index 1cfb3d61..af5d2f71 100644 --- a/resources/master_template/structure/sg.json +++ b/resources/master_template/structure/sg.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "sg", - "도번": "구-21", + "도번": "SD110101", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/sta.json b/resources/master_template/structure/sta.json deleted file mode 100644 index 7d0ebe77..00000000 --- a/resources/master_template/structure/sta.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "양식": "구조물도면", - "종류": "structure", - "판": 1, - "열": "sta", - "도번": "구-02", - "도면": { - "format": 6, - "entities": [], - "layers": [ - { - "id": "기본", - "name": "기본", - "isVisible": true, - "isLocked": false - } - ] - } -} diff --git a/resources/master_template/structure/ta.json b/resources/master_template/structure/ta.json index ab34875a..b5c627b3 100644 --- a/resources/master_template/structure/ta.json +++ b/resources/master_template/structure/ta.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "ta", - "도번": "구-28", + "도번": "SD170000", "도면": { "format": 6, "entities": [], diff --git a/resources/master_template/structure/wy.json b/resources/master_template/structure/wy.json index 39b4028a..372189cc 100644 --- a/resources/master_template/structure/wy.json +++ b/resources/master_template/structure/wy.json @@ -3,7 +3,7 @@ "종류": "structure", "판": 1, "열": "wy", - "도번": "구-27", + "도번": "SD160000", "도면": { "format": 6, "entities": [], diff --git a/resources/tester/spreadsheet/test_spreadsheet_store.py b/resources/tester/spreadsheet/test_spreadsheet_store.py index 9f0dc02d..c2f1f83d 100644 --- a/resources/tester/spreadsheet/test_spreadsheet_store.py +++ b/resources/tester/spreadsheet/test_spreadsheet_store.py @@ -80,35 +80,58 @@ def test_옛_산출근거를_따로_파일로_옮김(client, tmp_path): assert before == {p.name: p.read_bytes() for p in (tmp_path / "basis").iterdir()} -def test_새_구조물_도면은_산출근거_따로(client): +def test_새_구조물_도면은_산출근거_따로_진짜_빈_시트(client): made = client.post("/api/m02/structures/rv").json()["문서"] assert "산출근거" not in made basis = client.get("/api/m02/templates/basis/rv").json()["문서"] - heads = [basis["시트"][0]["칸"][f"{c}1"]["값"] for c in "ABCDE"] - assert heads == ["공종", "규격", "산출 내역", "단위", "수량(m당)"] + assert basis["시트"][0]["칸"] == {} and basis["서식"] == [{}] # 머리 줄 없음 -def test_표번은_도번과_같은_규칙(client): +def test_표번은_도번과_같은_6자리(client): made1 = client.post("/api/m02/structures/rv").json()["문서"] made2 = client.post("/api/m02/structures/pv_b").json()["문서"] - assert made1["도번"] == "구-01" and made2["도번"] == "구-02" + assert made1["도번"] == "SD010101" and made2["도번"] == "SD020101" basis1 = client.get("/api/m02/templates/basis/rv").json()["문서"] basis2 = client.get("/api/m02/templates/basis/pv_b").json()["문서"] - assert basis1["표번"] == "표-01" and basis2["표번"] == "표-02" - numbers = client.get("/api/m02/basis/numbers").json() - assert numbers["rv"] == "표-01" and numbers["pv_b"] == "표-02" + assert basis1["표번"] == "SC010101" and basis2["표번"] == "SC020101" + numbers = client.get("/api/m02/structures/numbers").json() + assert numbers["pv_b"] == {"도번": "SD020101", "표번": "SC020101"} -def test_표번_없는_옛_파일은_만나면_채움(client, tmp_path): - store.ensure_basis("rv") - doc = store.read("basis", "rv")["문서"] - del doc["표번"] - (tmp_path / "basis" / "rv.json").write_text( +def _old_basis(folder, column, cells): + doc = {**store.basis_doc(column), "표번": "표-03", "서식": [{}, {"굵게": True}]} + doc["시트"][0]["칸"] = cells + (folder / "basis" / f"{column}.json").write_text( json.dumps(doc, ensure_ascii=False), encoding="utf-8" ) - numbers = client.get("/api/m02/basis/numbers").json() - assert numbers["rv"] == "표-01" - assert store.read("basis", "rv")["문서"]["표번"] == "표-01" # 한 번 채우면 파일에 남음 + + +def test_옛_빈_산출근거_머리_줄을_지우고_새_번호(client, tmp_path): + head = {f"{c}1": {"값": v, "서식": 1} for c, v in zip("ABCDE", store._BASIS_HEAD)} + _old_basis(tmp_path, "rv", dict(head)) + _old_basis(tmp_path, "ms", {**head, "A1": {"값": "공종명", "서식": 1}}) # 사용자가 고친 머리 + _old_basis(tmp_path, "sg", {**head, "A2": {"값": "터파기"}}) # 아래 줄에 내용 + store.renumber() + rv = store.read("basis", "rv")["문서"] + assert (rv["표번"], rv["시트"][0]["칸"], rv["서식"]) == ("SC010101", {}, [{}]) + assert store.read("basis", "ms")["문서"]["시트"][0]["칸"]["A1"]["값"] == "공종명" # 둠 + sg = store.read("basis", "sg")["문서"] + assert sg["시트"][0]["칸"] == {"A2": {"값": "터파기"}} # 머리만 지우고 내용은 둠 + assert store.read("structure", "rv")["문서"]["도번"] == "SD010101" # 짝 파일도 만듦 + + +def test_다른_열_산출근거를_복사해_가져옴(client): + store.renumber() + got = client.get("/api/m02/templates/basis/rv").json() + got["문서"]["시트"][0]["칸"] = {"A1": {"식": "1+1"}} + client.put("/api/m02/templates/basis/rv", json=got) + r = client.post("/api/m02/basis/ms/copy", params={"from": "rv"}) + assert r.status_code == 200 + ms = client.get("/api/m02/templates/basis/ms").json()["문서"] + assert ms["시트"][0]["칸"] == {"A1": {"식": "1+1"}} + assert (ms["표번"], ms["열"]) == ("SC100101", "ms") # 번호 · 열은 받는 쪽 그대로 + assert ms["계산값"] == SERVER # 서버가 다시 풂 + assert client.post("/api/m02/basis/ms/copy", params={"from": "없는열"}).status_code == 404 def test_저장은_서버_계산값만_적음(client): diff --git a/resources/tester/test_m02_structure.py b/resources/tester/test_m02_structure.py index 6817c259..0f033c58 100644 --- a/resources/tester/test_m02_structure.py +++ b/resources/tester/test_m02_structure.py @@ -1,6 +1,8 @@ -"""M02 구조물 도면(structure) — 새로 · 도번 자동 · 409 · 저장 · 지운 뒤 번호 · 프로젝트 복사. +"""M02 구조물 도면(structure) — 새로 · 도번 SD+6자리 · 409 · 저장 · 지운 뒤 번호 · +제목행 번호 매김 · 집계표 저장 때 만들기/지우기 · 복사 가져오기 · 프로젝트 복사. 산출근거는 따로 파일(basis) — `resources/tester/spreadsheet/test_spreadsheet_store.py`.""" +import json import shutil import pytest @@ -25,6 +27,10 @@ def client(tmp_path, monkeypatch): return TestClient(app) +def _num(도번: str, 표번: str) -> dict: + return {"도번": 도번, "표번": 표번} + + def test_새로_도번_자동_409_없는_열(client): made = client.post("/api/m02/structures/pp_len") assert made.status_code == 200 @@ -33,7 +39,7 @@ def test_새로_도번_자동_409_없는_열(client): "구조물도면", "structure", "pp_len", - "구-01", + "SD010101", ) # 도각 없는 전용 화면 — 그린 만큼이 설계 영역 · 기본 도면층 하나(없으면 CAD 가 못 엶) assert doc["도면"]["format"] == 6 @@ -43,10 +49,14 @@ def test_새로_도번_자동_409_없는_열(client): assert "산출근거" not in doc assert client.get("/api/m02/templates/basis/pp_len").json()["문서"]["종류"] == "통합문서" - assert client.post("/api/m02/structures/rv").json()["문서"]["도번"] == "구-02" + assert client.post("/api/m02/structures/rv").json()["문서"]["도번"] == "SD020101" assert client.post("/api/m02/structures/pp_len").status_code == 409 assert client.post("/api/m02/structures/없는열").status_code == 404 - assert client.get("/api/m02/structures/numbers").json() == {"pp_len": "구-01", "rv": "구-02"} + assert client.post("/api/m02/structures/no").status_code == 404 # 글 열은 구조물 아님 + assert client.get("/api/m02/structures/numbers").json() == { + "pp_len": _num("SD010101", "SC010101"), + "rv": _num("SD020101", "SC020101"), + } rows = client.get("/api/m02/templates").json() assert {(r["종류"], r["이름"]) for r in rows if r["종류"] == "structure"} == { ("structure", "pp_len"), @@ -68,15 +78,79 @@ def test_저장_뼈대_거름(client): assert client.get("/api/m02/templates/structure/pp_len").json()["문서"] == doc -def test_지워도_번호를_당기지_않음(client): +def test_지워도_번호를_당기지_않음_짝은_같은_번호(client): for column in ("pp_len", "rv", "ms"): client.post(f"/api/m02/structures/{column}") - assert client.delete("/api/m02/templates/structure/pp_len").status_code == 200 - assert client.get("/api/m02/structures/numbers").json() == {"rv": "구-02", "ms": "구-03"} - assert client.post("/api/m02/structures/fb").json()["문서"]["도번"] == "구-04" - # 가장 큰 번호를 지우면 그 번호부터 다시(있는 것 중 가장 큰 번호 + 1) - client.delete("/api/m02/templates/structure/fb") - assert client.post("/api/m02/structures/ec").json()["문서"]["도번"] == "구-04" + assert client.delete("/api/m02/templates/structure/rv").status_code == 200 + numbers = client.get("/api/m02/structures/numbers").json() + assert numbers["rv"] == _num("", "SC020101") # 산출근거는 남아 번호를 쥠 + assert numbers["ms"] == _num("SD030101", "SC030101") # 다른 열 번호는 그대로 + # 같은 종류(관공) 새 열 = 그 무리 다음 번호 · 다시 만든 도면은 짝(산출근거) 번호를 이어 받음 + assert client.post("/api/m02/structures/pp_cp").json()["문서"]["도번"] == "SD010102" + assert client.post("/api/m02/structures/rv").json()["문서"]["도번"] == "SD020101" + + +def test_제목행으로_번호_매김_한_번_옮김(client, tmp_path): + """옛 구-NN 파일 · 글 열 파일 → 새 번호(열 차례 = 종류 · 분류1 · 분류2 차례) · 내용 그대로.""" + for column in ("no", "rv", "pv_l"): + doc = {"양식": "구조물도면", "종류": "structure", "판": 1, "열": column, "도번": "구-07"} + doc["도면"] = {"format": 6, "entities": [{"type": "line"}], "layers": []} + (tmp_path / "structure" / f"{column}.json").write_text( + json.dumps(doc, ensure_ascii=False), encoding="utf-8" + ) + done = store.renumber() + assert done["지움"] == ["structure/no"] # 글 열(NO · 측점 · 비고)은 구조물 아님 + numbers = client.get("/api/m02/structures/numbers").json() + assert set(numbers) == set(store._column_ids()) and "sta" not in numbers + expect = { + "rv": "010101", # 돌기슭막이 · (형태마다) · H=(높이마다) + "pv_b": "020101", # 콘크리트포장 · T=(두께마다) · B + "pv_l": "020102", # 같은 종류 · 분류1 · 다음 분류2 + "fb": "060100", # 세월교 · (관경 × 련수마다) · 분류2 없음 = 00 + "be": "140000", # 소단 — 분류 둘 다 없음 + "h_rip_c": "270100", # 돌붙임 · 찰붙임 + "h_rip_m": "270200", # 돌붙임 · 메붙임 — 분류1 다음 번호 + } + for column, code in expect.items(): + assert numbers[column] == _num(f"SD{code}", f"SC{code}"), column + assert store.read("structure", "rv")["문서"]["도면"]["entities"] == [{"type": "line"}] + assert store.renumber() == {"지움": [], "바꿈": [], "새로": []} # 두 번 돌려도 같음 + + +def test_집계표_저장_때_새_열은_만들고_지운_열은_같이_지움(client): + store.renumber() + got = client.get("/api/m02/templates/table/구조물집계표").json() + table = got["문서"] + table["열"] = [c for c in table["열"] if c["id"] != "pv_a"] + new = {"id": "pv_x", "머리": ["콘크리트포장", "T=(두께마다)", "X"], "단위": "m", "꼴": "수"} + kind = {"id": "zz", "머리": ["새 구조물", None, None], "단위": "개소", "꼴": "수"} + text = {"id": "note2", "머리": ["메모", None, None], "단위": None, "꼴": "글"} + table["열"] += [new, kind, text] + saved = client.put( + "/api/m02/templates/table/구조물집계표", json={"판": got["판"], "문서": table} + ) + assert saved.status_code == 200 + numbers = client.get("/api/m02/structures/numbers").json() + assert "pv_a" not in numbers and "note2" not in numbers + for kind_ in ("structure", "basis"): + assert client.get(f"/api/m02/templates/{kind_}/pv_a").status_code == 404 + assert numbers["pv_x"] == _num("SD020106", "SC020106") # 지운 04 는 비워 둠 · 무리 다음 + assert numbers["zz"] == _num("SD370000", "SC370000") # 새 종류 = 종류 다음 번호 + + +def test_다른_열_도면을_복사해_가져옴(client): + store.renumber() + src = client.get("/api/m02/templates/structure/rv").json() + src["문서"]["도면"]["entities"] = [{"type": "circle"}] + client.put("/api/m02/templates/structure/rv", json=src) + r = client.post("/api/m02/structures/ms/copy", params={"from": "rv"}) + assert r.status_code == 200 + ms = client.get("/api/m02/templates/structure/ms").json()["문서"] + assert ms["도면"]["entities"] == [{"type": "circle"}] + assert (ms["도번"], ms["열"]) == ("SD100101", "ms") # 번호 · 열은 받는 쪽 그대로 + assert client.get("/api/m02/templates/structure/rv").json()["문서"]["도번"] == "SD010101" + bad = client.post("/api/m02/structures/ms/copy", params={"from": "없는열"}) + assert bad.status_code == 404 def test_프로젝트_복사와_층_저장에_실림(client, tmp_path, monkeypatch): diff --git a/resources/tester/test_m02_structure_panel.py b/resources/tester/test_m02_structure_panel.py index 15e8a1e9..b1510126 100644 --- a/resources/tester/test_m02_structure_panel.py +++ b/resources/tester/test_m02_structure_panel.py @@ -49,8 +49,9 @@ def test_소스가_700줄을_넘지_않음(): ), # 산출근거 저장은 컨테이너가 안 함 — [산출근거 수정] 이 여는 메인 칸 전체 편집이 함 ("M02_MasterTemplete_Api_Fetch.ts", ["saveTemplate"], MAIN), - # 좌측 산출근거 줄 번호는 좌측 패널이 받음(구조물 도면 줄과 같은 자리) - ("M02_MasterTemplete_Api_Fetch.ts", ["fetchBasisNumbers"], SIDE), + # 좌측 구조물 도면 · 산출근거 줄 번호는 한 번에 받음(`{열 id: {도번, 표번}}`) + ("M02_MasterTemplete_Api_Fetch.ts", ["fetchStructureNumbers"], SIDE), + ("M02_MasterTemplete_Structure.ts", ["structureLabel", "isStructureColumn"], SIDE), ("M02_MasterTemplete_Drawing.ts", ["mountDrawingTemplate"], PANEL), ("../A00_Common/spreadsheet/spreadsheet.ts", ["createSpreadsheet"], PANEL), ], @@ -64,6 +65,17 @@ def test_컨테이너가_쓰는_이름이_내보내진_것(source: str, names: l assert name in used, name +def test_sub2_가_부르는_이름과_모양(): + """브레인 확정 이름 · 모양 — sub2 가 이대로 부름(바꾸면 브레인에게).""" + body = _text(M02 / "M02_MasterTemplete_Api_Fetch.ts") + for name in ("copyStructure", "copyBasis"): + assert re.search( + rf"export const {name} = async \(column: string, from: string\): Promise", body + ), name + assert "fetchStructureNumbers = (): Promise>" in body + assert re.search(r"interface StructureNumbers \{\s*도번: string;\s*표번: string;\s*\}", body) + + def test_집계표만_컨테이너를_붙임(): """다른 표 양식에는 안 붙음 — 시스템 층 · 이름이 집계표일 때만.""" body = _text(MAIN) @@ -74,15 +86,21 @@ def test_집계표만_컨테이너를_붙임(): @pytest.mark.skipif(shutil.which("node") is None, reason="node 가 없음") def test_열_머리_글_잇기(): - """`columnHead` — 빈 층은 건너뛰고 ` · ` 로 이음 · 다 비면 열 id.""" - found = re.search(r"^export const columnHead[\s\S]*?;$", _text(PANEL), re.M) - assert found, "columnHead 를 못 찾음" + """`columnHead` — 빈 층은 건너뛰고 빈칸으로 이음 · 다 비면 열 id · + `structureLabel` — 번호가 맨 앞(「SD010101 돌기슭막이 …」) · 번호 없으면 이름만.""" + funcs = [ + re.search(rf"^export const {name}[\s\S]*?;$", _text(PANEL), re.M) + for name in ("columnHead", "structureLabel") + ] + assert all(funcs), "columnHead · structureLabel 을 못 찾음" # 부품 파일은 화면 모듈을 부르므로 통째로 못 싣음 — 그 함수만 떼어 Node 가 타입을 벗겨 돌림 script = ( "interface StructureColumn { id: string; 머리: (string | null)[] }\n" - + found.group(0).replace("export ", "") + + "\n".join(f.group(0).replace("export ", "") for f in funcs) + "\nconsole.log(JSON.stringify(process.argv.slice(1)" - + ".map((a) => columnHead(JSON.parse(a)))));" + + ".map((a) => columnHead(JSON.parse(a)))" + + ".concat([structureLabel('SD010101', {id: 'rv', 머리: ['돌기슭막이', null, 'H=1.0']})," + + " structureLabel('', {id: 'rv', 머리: ['돌기슭막이', null, null]})])));" ) cases = [ {"id": "pv_l", "머리": ["콘크리트포장", "T=(두께별)", "L"]}, @@ -96,4 +114,10 @@ def test_열_머리_글_잇기(): capture_output=True, text=True, encoding="utf-8", timeout=60, ) # fmt: skip assert result.returncode == 0, result.stderr - assert json.loads(result.stdout) == ["콘크리트포장 · T=(두께별) · L", "NO", "etc"] + assert json.loads(result.stdout) == [ + "콘크리트포장 T=(두께별) L", + "NO", + "etc", + "SD010101 돌기슭막이 H=1.0", + "돌기슭막이", + ]