Compare commits

..

2 Commits

1 changed files with 3 additions and 1 deletions

View File

@ -857,7 +857,9 @@ def handover_submit(handover:Handover, user: User, now: Union[datetime.datetime,
else: else:
raise ParseError("不支持非工段报废") raise ParseError("不支持非工段报废")
elif handover.type == Handover.H_CHANGE: elif handover.type == Handover.H_CHANGE:
if handover.recive_mgroup: if handover.new_wm:
wm_to = handover.new_wm
elif handover.recive_mgroup:
wm_to, _ = WMaterial.objects.get_or_create( wm_to, _ = WMaterial.objects.get_or_create(
batch=batch, batch=batch,
material=handover.material_changed, material=handover.material_changed,