From 19b02812bdaa68aca815220dbca946dfd8921406 Mon Sep 17 00:00:00 2001 From: Christian Vidal Wolf Date: Tue, 12 May 2026 11:53:54 +0200 Subject: [PATCH] feat: enable sorting and filtering on CPNP No. column in Cosmetic Items tab Show all cosmetic products regardless of CPNP status. Column filter on CPNP No. lets user isolate items with empty value. Co-Authored-By: claude-flow --- src/components/CosmeticItemsView.tsx | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/components/CosmeticItemsView.tsx b/src/components/CosmeticItemsView.tsx index 2cb08fe..96bcd9a 100644 --- a/src/components/CosmeticItemsView.tsx +++ b/src/components/CosmeticItemsView.tsx @@ -43,8 +43,6 @@ export function CosmeticItemsView({ data, headers, onSaveRow, onCaptureState, ro data.forEach(row => { const lineVal = String(row[COLUMNS.LINE] ?? '').trim().toUpperCase(); if (!COSMETIC_LINES.some(l => lineVal === l)) return; - const cpnp = row[COLUMNS.CPNP_NO]; - if (cpnp !== null && cpnp !== undefined && String(cpnp).trim() !== '') return; columns.forEach(({ col }) => { result[col].add(String(row[col] ?? '')); @@ -66,12 +64,6 @@ export function CosmeticItemsView({ data, headers, onSaveRow, onCaptureState, ro return COSMETIC_LINES.some(l => lineVal === l); }); - // Filter: CPNP No. is empty - result = result.filter(({ row }) => { - const cpnp = row[COLUMNS.CPNP_NO]; - return cpnp === null || cpnp === undefined || String(cpnp).trim() === ''; - }); - // Global search if (search) { const terms = search.toLowerCase().split(/\s+/).filter(Boolean);