diff --git a/sf_manufacturing/models/mrp_workorder.py b/sf_manufacturing/models/mrp_workorder.py index d86578e5..82c1a5b2 100644 --- a/sf_manufacturing/models/mrp_workorder.py +++ b/sf_manufacturing/models/mrp_workorder.py @@ -109,7 +109,7 @@ class ResMrpWorkOrder(models.Model): next_workorder = sorted_workorders[position + 1] next_state = next_workorder.state if (next_state == 'ready' or ( - next_workorder.state == 'pending' and next_workorder.is_subcontract)) and cur_workorder.state == 'done': + next_workorder.state == 'waiting' and next_workorder.is_subcontract)) and cur_workorder.state == 'done': record.back_button_display = True else: record.back_button_display = False