Merge branch 'dev' into runny827
feat(training): 新增精益培训视频与周任务管理 # Conflicts: # backend/app/models/__init__.py
This commit is contained in:
1 parent
85d27e9ffa
commit
91b7233872
812 files changed
+73763
-18908
No files matched your search
@@ -20,7 +20,6 @@ from app.services.shipping_notice.notice_line_values import (
|
||||
map_notice_header,
|
||||
norm_header,
|
||||
normalize_currency,
|
||||
normalize_line_no,
|
||||
normalize_required_date,
|
||||
parse_number,
|
||||
)
|
||||
@@ -201,10 +200,6 @@ def normalize_notice_line(
|
||||
if raw_uom and field_enabled("uom"):
|
||||
line["uom"] = raw_uom
|
||||
|
||||
line_no = normalize_line_no(raw.get("line_no"))
|
||||
if line_no and field_enabled("line_no"):
|
||||
line["line_no"] = line_no
|
||||
|
||||
reservation_id = extract_reservation_id(raw.get("reservation_id"))
|
||||
if reservation_id and field_enabled("reservation_id"):
|
||||
line["reservation_id"] = reservation_id
|
||||
@@ -217,9 +212,10 @@ def normalize_notice_line(
|
||||
line["unit_price"] = unit_price
|
||||
|
||||
amount = parse_number(raw.get("amount"))
|
||||
if amount is not None and field_enabled("amount"):
|
||||
# Schema 使用 canonical line_amount_with_tax;内部通知行仍保留 amount 键供下游消费。
|
||||
if amount is not None and field_enabled("line_amount_with_tax"):
|
||||
line["amount"] = amount
|
||||
elif unit_price is not None and field_enabled("amount"):
|
||||
elif unit_price is not None and field_enabled("line_amount_with_tax"):
|
||||
line["amount"] = round(unit_price * qty, 4)
|
||||
|
||||
currency = normalize_currency(raw.get("currency"))
|
||||
|
||||
Reference in new issue
Block a user