From f9987e515cb398ed9a2bb58cb8ec0be40199c248 Mon Sep 17 00:00:00 2001 From: Hagernesh Date: Thu, 20 Aug 2026 10:25:08 +0000 Subject: [PATCH] feat(warehouses): filters/pagination on all import+export queue tabs Extends the stat-tile/filter/pagination pattern from the import arrival queue to every remaining import and export tab (unloaded, eligible, received, ready-to-load, loaded/dispatch, locate-booking), reusing useListControls/ListControls/RuleEngineListFooter throughout. Adds a 5-tile stat row to the export tab bar and renames ImportStatCard to WarehouseStatCard now that it's shared by both directions. Co-Authored-By: Claude Sonnet 5 --- .../warehouses/ReceiveInventoryModal.tsx | 156 +++++++++++++++--- 1 file changed, 135 insertions(+), 21 deletions(-) diff --git a/apps/edr-freight-web/backoffice/src/components/warehouses/ReceiveInventoryModal.tsx b/apps/edr-freight-web/backoffice/src/components/warehouses/ReceiveInventoryModal.tsx index f1dad1f1e..f0cef75b1 100644 --- a/apps/edr-freight-web/backoffice/src/components/warehouses/ReceiveInventoryModal.tsx +++ b/apps/edr-freight-web/backoffice/src/components/warehouses/ReceiveInventoryModal.tsx @@ -925,7 +925,10 @@ function EligibleTab({ ), [rows, statusOptions], ); - const selectableRows = statusFilteredRows.filter(canReceiveBooking); + const controls = useListControls(statusFilteredRows, { + searchKeys: ['reference', 'customer', 'origin', 'destination', 'containerNumber', 'cargo', 'cargoDescription'], + }); + const selectableRows = controls.filteredRows.filter(canReceiveBooking); const allSelected = selectableRows.length > 0 && selected.size === selectableRows.length; const someSelected = selected.size > 0 && !allSelected; const pendingReceiveRows = useMemo( @@ -1085,7 +1088,7 @@ function EligibleTab({ - Selected: {selected.size} / {statusFilteredRows.length} eligible + Selected: {selected.size} / {controls.filteredRows.length} eligible