Merge branch 'feature/刀具拆解单优化' into feature/工单优化

This commit is contained in:
yuxianghui
2024-09-18 09:30:49 +08:00

View File

@@ -1035,6 +1035,10 @@ class ResMrpWorkOrder(models.Model):
elif workorder.production_id.reservation_state != 'assigned': elif workorder.production_id.reservation_state != 'assigned':
workorder.state = 'waiting' workorder.state = 'waiting'
continue continue
elif (workorder.name == '装夹预调' and
workorder.state not in ['rework', 'done', 'cancel']):
if workorder.state != 'pending':
workorder.state = 'pending'
if workorder.production_id.tool_state in ['1', '2'] and workorder.state == 'ready': if workorder.production_id.tool_state in ['1', '2'] and workorder.state == 'ready':
workorder.state = 'waiting' workorder.state = 'waiting'
continue continue