fix(M01): 빠진 원 단위 입력도 null 처럼 그 줄만 비움 (/calc · /text)
- mf.fill_empty — 화면이 안 보낸 가격 입력(단위에 원)을 null 로 채움 · Store.calc·text 에서 부름 - 시험 test_m01_auto.py 한 개 더 — 입력 둘 뺀 GF000056 Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01JgUhN55Z3BCYhUJTjwTNfj
This commit is contained in:
@@ -449,6 +449,16 @@ def cut(row: dict, value: Decimal, on: str) -> Decimal:
|
||||
return _round(value, rule.get("자리") or 0, way)
|
||||
|
||||
|
||||
def fill_empty(row: dict, given: dict) -> dict:
|
||||
"""화면이 안 보낸 가격 입력(단위에 「원」)은 null 로 채움 — 빈 입력과 같이 그 줄만 비움."""
|
||||
gap = {
|
||||
s["이름"]: None
|
||||
for s in row.get("입력", [])
|
||||
if s["이름"] not in given and "원" in str(s.get("단위") or "")
|
||||
}
|
||||
return {**given, **gap}
|
||||
|
||||
|
||||
def _inputs(row: dict, given: dict) -> dict:
|
||||
env = {}
|
||||
for spec in row.get("입력", []):
|
||||
|
||||
Reference in New Issue
Block a user