Search for implicit locations of type storage when generating internal shipment

The provisioning and overflow locations are only meaningful on storage locations.
This commit is contained in:
Cédric Krier
2024-10-06 12:38:20 +02:00
parent fbbad830a2
commit 4aa300a3e4
+1
View File
@@ -66,6 +66,7 @@ class ShipmentInternal(ModelSQL, ModelView):
implicit_locations = Location.search(['OR',
('provisioning_location', '!=', None),
('overflowing_location', '!=', None),
('type', '=', 'storage'),
])
id2location.update({l.id: l for l in implicit_locations})
location_ids = list(id2location.keys())