Skip to content

Commit

Permalink
[FIX] purchase: patch _check to take cancel moves into account
Browse files Browse the repository at this point in the history
  • Loading branch information
robinkeunen committed Jan 9, 2020
1 parent 40c55ab commit cfb591b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion addons/purchase/purchase.py
Original file line number Diff line number Diff line change
Expand Up @@ -799,7 +799,7 @@ def _check(self, procurement):
if procurement.purchase_line_id:
if not procurement.move_ids:
return False
return all(move.state == 'done' for move in procurement.move_ids)
return all(move.state in ('cancel', 'done') for move in procurement.move_ids)
return super(ProcurementOrder, self)._check(procurement)

@api.v8
Expand Down

0 comments on commit cfb591b

Please sign in to comment.