Merge branch 'feature/制造订单状态优化' into feature/工单状态优化_2
This commit is contained in:
@@ -1097,8 +1097,7 @@ class ResMrpWorkOrder(models.Model):
|
||||
# ================= 如果制造订单刀具状态为[无效刀、缺刀] 或者 制造订单状态为[返工]==========================
|
||||
if (workorder.production_id.tool_state in ['1', '2'] or workorder.production_id.state == 'rework'
|
||||
or workorder.production_id.schedule_state != '已排'
|
||||
or len(
|
||||
workorder.production_id.picking_ids.filtered(lambda w: w.state not in ['done', 'cancel'])) != 0
|
||||
or workorder.production_id.reservation_state not in ['assigned']
|
||||
or workorder.production_id.workorder_ids.filtered(
|
||||
lambda wk: wk.sequence == workorder.sequence - 1).test_results in ['报废', '返工']):
|
||||
if workorder.state != 'waiting':
|
||||
|
||||
Reference in New Issue
Block a user