2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-15 19:45:46 +00:00

Clear allocations when returning a stock item against a return order (#4538)

This commit is contained in:
Oliver
2023-03-29 16:04:31 +11:00
committed by GitHub
parent 66b8fb6bc1
commit 8148067f59

View File

@ -1745,6 +1745,9 @@ class ReturnOrder(TotalPriceMixin, Order):
stock_item = line.item stock_item = line.item
# Remove any allocations against the returned StockItem
stock_item.clearAllocations()
deltas = { deltas = {
'status': StockStatus.QUARANTINED, 'status': StockStatus.QUARANTINED,
'returnorder': self.pk, 'returnorder': self.pk,