feat(778-4): 율 기준 줄 목록 열쇠@비목 — 그 줄 그 비목 몫(절 노무비 · 기계 노무 포함)

- 밑 공용 함수 rate_base ↔ rateBase · 검사 · 짝잃음 · B09 rows:n@labor(파이썬 · TS) · 굳힘 · 화면 열쇠 옮김이 비목 꼬리 그대로
- 여덟 파일 율 줄 152 중 기준 찾은 147 재현(인력 82 · 재료 35 · 절 소계 16 · 노무비 11 · 장비 2 · 자재+율 1)
- 시험 test_778_4_rate_line 29 · 전후 대조 148/148 같음

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-04 13:15:13 +09:00
co-authored by Claude Opus 5.5
parent b8772a4172
commit fd9cce0b12
10 changed files with 114 additions and 28 deletions
+5 -1
View File
@@ -320,7 +320,11 @@ def _rekey(one: dict, move: Any) -> dict:
rate = ((one.get("고정") or {}).get("비율") or {}) if isinstance(one, dict) else {}
if not isinstance(rate.get("기준"), list):
return one
keys = [k for k in (move(x) for x in rate["기준"]) if k]
keys = []
for x in rate["기준"]:
line, cost = fixed.split_key(x) # `열쇠@비목` = 비목 꼬리 그대로
if got := move(line):
keys.append(f"{got}@{cost}" if cost else got)
fx = {**one["고정"], "비율": {**rate, "기준": keys}}
return {**one, "고정": fx}