ДО формируются под сделку
All checks were successful
Deploy MES Core / deploy (push) Successful in 12s
All checks were successful
Deploy MES Core / deploy (push) Successful in 12s
This commit is contained in:
@@ -24,6 +24,7 @@ def apply_closing(
|
||||
item_actions: dict[int, dict],
|
||||
consumptions: dict[int, float],
|
||||
remnants: list[dict],
|
||||
inherit_deal_for_remnants: bool = False,
|
||||
) -> None:
|
||||
logger.info('apply_closing:start user=%s machine=%s material=%s items=%s consumptions=%s remnants=%s', user_id, machine_id, material_id, list(item_actions.keys()), list(consumptions.keys()), len(remnants))
|
||||
|
||||
@@ -93,7 +94,7 @@ def apply_closing(
|
||||
)
|
||||
|
||||
logger.info('apply_closing:close_session id=%s', report.id)
|
||||
close_cutting_session(report.id)
|
||||
close_cutting_session(report.id, inherit_deal_for_remnants=bool(inherit_deal_for_remnants))
|
||||
|
||||
for it in items:
|
||||
spec = item_actions.get(it.id) or {}
|
||||
@@ -142,6 +143,7 @@ def apply_closing_workitems(
|
||||
item_actions: dict[int, dict], # workitem_id -> {'action': 'done'|'partial', 'fact': int}
|
||||
consumptions: dict[int, float],
|
||||
remnants: list[dict],
|
||||
inherit_deal_for_remnants: bool = False,
|
||||
) -> None:
|
||||
logger.info('apply_closing_workitems:start user=%s machine=%s material=%s workitems=%s cons=%s rem=%s', user_id, machine_id, material_id, list(item_actions.keys()), list(consumptions.keys()), len(remnants))
|
||||
|
||||
@@ -224,5 +226,5 @@ def apply_closing_workitems(
|
||||
unique_id=None,
|
||||
)
|
||||
|
||||
close_cutting_session(report.id)
|
||||
close_cutting_session(report.id, inherit_deal_for_remnants=bool(inherit_deal_for_remnants))
|
||||
logger.info('apply_closing_workitems:done report=%s shift_items=%s', report.id, created_shift)
|
||||
|
||||
Reference in New Issue
Block a user