feat(b09): 치즐 소모량 — 자원 목록 AR-M 치즐(본) · 대형브레이커 줄 옆 본/hr ÷ Q × 배분으로 같은 D 에 붙음(수동 단가가 있을 때만) · 칸을 채우면 치즐 13공종 온전 · 9-4-1 평균 갈래는 원문에 치즐 평균이 없어 사유
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BW6Jdsh18WPtYUR6THZJqn
This commit is contained in:
@@ -797,6 +797,19 @@ def build_unit_prices(
|
||||
from B09_Estimation.B09_Estimation_MaterialPrices import add_material_titles
|
||||
|
||||
build.manual_materials = add_material_titles(build.book, material_prices)
|
||||
from B09_Estimation.B09_Estimation_Chisel import (
|
||||
BREAKER_PREFIX,
|
||||
CHISEL_CODE,
|
||||
attach_chisel,
|
||||
chisel_per_hour,
|
||||
without_chisel_labels,
|
||||
)
|
||||
|
||||
nodes_by_code = {str(node.get("work_item_code")): node for node in master.get("work_items", [])}
|
||||
# 치즐은 자원 축 줄이 아니라 표의 소모량 줄 — 「자재 단가」 탭에 칸이 서게 쓰는 공종을 실음.
|
||||
chisel_items = sorted(code for code, node in nodes_by_code.items() if chisel_per_hour(node))
|
||||
if chisel_items:
|
||||
build.material_uses[CHISEL_CODE] = chisel_items
|
||||
for row in axis.rows:
|
||||
if row.resource_kind == "material":
|
||||
uses = build.material_uses.setdefault(row.resource_code, [])
|
||||
@@ -1005,6 +1018,17 @@ def build_unit_prices(
|
||||
output=fix2(capacity["capacity_per_hour"]),
|
||||
)
|
||||
attached_capacity = True
|
||||
# 치즐 — 대형브레이커 줄 옆 「치즐소모량(본/hr)」 ÷ Q × 배분(Ⓐ-3 · 수동 단가가 있을 때만).
|
||||
if capacity["machine_code"].startswith(BREAKER_PREFIX) and attach_chisel(
|
||||
build.book,
|
||||
title_code,
|
||||
chisel_per_hour(nodes_by_code.get(work_item_code, {})),
|
||||
fix2(capacity["capacity_per_hour"]),
|
||||
group_share,
|
||||
):
|
||||
build.unattached[work_item_code] = without_chisel_labels(
|
||||
build.unattached.get(work_item_code, [])
|
||||
)
|
||||
|
||||
# ⚠ **배분율이 있는 표는 「몇 %가 실제로 붙었나」를 세어 둔다.**
|
||||
# 「인력(10%)·장비(90%)」 표에서 인력만 붙으면 단가가 10 % 몫만인데, 그 값이
|
||||
|
||||
Reference in New Issue
Block a user