From ca774267cd08411921a1ec3af81318a23519d8ac Mon Sep 17 00:00:00 2001 From: Hagernesh Date: Thu, 9 Jul 2026 13:41:57 +0000 Subject: [PATCH] fix(warehouses): Store no longer strands an import item in STORED READY_FOR_PICKUP allows STORED (park an import item back into storage), but STORED allowed only RESERVED / READY_FOR_LOADING - so readyForPickup() hit assertTransition(STORED, READY_FOR_PICKUP) and threw. The item could never return to pickup, and getNextInventoryAction returned null for an import STORED item, leaving the row with no action at all. - allow STORED -> READY_FOR_PICKUP - an inspected import STORED item now advances to ready-for-pickup readyForPickup() still rejects non-IMPORT inventory, so the new edge cannot be reached from the export flow. Co-Authored-By: Claude Opus 4.8 (1M context) --- .../warehouses/entities/warehouse-inventory.entity.ts | 4 +++- apps/edr-freight-web/backoffice/src/types/warehouse.ts | 5 +++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/apps/edr-freight-api/src/modules/warehouses/entities/warehouse-inventory.entity.ts b/apps/edr-freight-api/src/modules/warehouses/entities/warehouse-inventory.entity.ts index a54f40973..b2c4ca3c4 100644 --- a/apps/edr-freight-api/src/modules/warehouses/entities/warehouse-inventory.entity.ts +++ b/apps/edr-freight-api/src/modules/warehouses/entities/warehouse-inventory.entity.ts @@ -36,7 +36,9 @@ export const WAREHOUSE_INVENTORY_TRANSITIONS: Record