From 742725d333ef72ff7096796f600d3dcbcb7edb50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 23 Aug 2023 18:18:20 +0200 Subject: [PATCH] Do not prevent to pack customer shipment with cancelled inventory moves --- modules/stock/shipment.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/stock/shipment.py b/modules/stock/shipment.py index 49e6fc69b4..a242c10b53 100644 --- a/modules/stock/shipment.py +++ b/modules/stock/shipment.py @@ -1565,7 +1565,7 @@ class ShipmentOut(ShipmentAssignMixin, Workflow, ModelSQL, ModelView): Move = pool.get('stock.move') for shipment in shipments: for move in shipment.inventory_moves: - if move.state != 'done': + if move.state not in {'done', 'cancelled'}: raise AccessError( gettext('stock.msg_shipment_pack_inventory_done', shipment=shipment.rec_name))