diff --git a/B09_Estimation/B09_Estimation_BillOfQuantities.py b/B09_Estimation/B09_Estimation_BillOfQuantities.py index 4a5f7329..b75c5b13 100644 --- a/B09_Estimation/B09_Estimation_BillOfQuantities.py +++ b/B09_Estimation/B09_Estimation_BillOfQuantities.py @@ -96,6 +96,10 @@ class HandoffWorkItem: #: 갈래 축·원본값 — 「stone_cm」·「60~80」. **키 문자열은 우리가 만든다**(두 창 합의). variant_axis: str = "" variant_value: str = "" + #: 규격 갈래를 B08 이 판정해 보낸 것(「철근구조물」)과 그 근거 문구. + #: **근거는 산출근거 칸에 그대로 적는다** — 우리가 다시 지어내지 않는다. + spec_class: str = "" + spec_class_basis: str = "" @property def display_name(self) -> str: @@ -243,6 +247,8 @@ def parse_handoff(payload: dict[str, Any]) -> tuple[list[HandoffWorkItem], list[ blocked_kind=row.get("blocked_kind") or "", variant_axis=row.get("variant_axis") or "", variant_value=str(row.get("variant_value") or ""), + spec_class=row.get("spec_class") or "", + spec_class_basis=row.get("spec_class_basis") or "", ) for row in payload["work_items"] ] diff --git a/B09_Estimation/B09_Estimation_BillOfQuantities_Rows.py b/B09_Estimation/B09_Estimation_BillOfQuantities_Rows.py index 46a19f4c..787dd508 100644 --- a/B09_Estimation/B09_Estimation_BillOfQuantities_Rows.py +++ b/B09_Estimation/B09_Estimation_BillOfQuantities_Rows.py @@ -140,6 +140,9 @@ def _leaf_row( quantity=item.quantity, in_bill=item.in_bill, ) + if item.spec_class_basis: + # 갈래 판정 근거는 **B08 문구를 그대로** 쓴다(두 벌로 짜지 않는다). + row.note = " / ".join(part for part in (row.note, item.spec_class_basis) if part) if item.application_ratio_pct is not None: # ⚠ 곱하지 않는다 — B08 이 이미 곱한 값이다. 산출근거로만 적는다. row.note = f"반영률 {item.application_ratio_pct}% 적용 후 수량" diff --git a/B09_Estimation/B09_Estimation_ResourceAxis.py b/B09_Estimation/B09_Estimation_ResourceAxis.py index 958ce3c2..bc790a7f 100644 --- a/B09_Estimation/B09_Estimation_ResourceAxis.py +++ b/B09_Estimation/B09_Estimation_ResourceAxis.py @@ -357,14 +357,9 @@ def match_table( result: AxisResult, ) -> None: """표 하나에 자원 축을 붙인다. 값이 안 서면 `unmatched` 로 보낸다.""" - # ⚠ **예시 서식 표는 자원 표가 아니다.** 품셈이 「ha당 …단가산출서(예시)」처럼 - # **빈 서식**을 실어 두는데(4-2 · 3-2 등), 그것을 읽으려 들면 구간 라벨·항목명이 - # 자원 이름으로 오해돼 못 맞춘 목록이 못 쓰게 된다(2026-09-08 실측 39줄). - # 값이 있는데 안 서는 자리가 아니라 **애초에 값이 없는 표**다. - headers = " ".join(str(c) for c in (table.get("condition_note") or [])) - if "단가산출서" in headers or "예시" in headers: - result.skipped_forms["example_form"] = result.skipped_forms.get("example_form", 0) + 1 - return + # 예시 서식(「ha당 …단가산출서(예시)」)은 **B08 이 마스터 원천에서 거른다**(8건). + # 두 곳에서 같은 것을 거르면 **나중에 한쪽만 고쳐진다** — 원천이 이긴다. + # ⚠ 짝 시험은 남겨 둔다(예시 서식이 자원으로 안 서는지) — 원천이 바뀌면 그것이 알려 준다. from B09_Estimation.B09_Estimation_CrewOutput import match_crew_table