From 3066ba06a2d4c0363334597385ef4b9e4771f369 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cau=C3=AA=20Faleiros?= Date: Mon, 20 Jul 2026 10:16:58 -0300 Subject: [PATCH] Refine planning product classification --- src/productClassification.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/productClassification.ts b/src/productClassification.ts index a4c6cac..b1f759e 100644 --- a/src/productClassification.ts +++ b/src/productClassification.ts @@ -121,6 +121,12 @@ export const classifyProductType = (name: string): ProductTypeKey => { if (!normalizedName) return 'unknown'; + if (has(normalizedName, /\bSALDO ESTOQUE\b/)) return 'ignore_from_planning'; + if (has(normalizedName, /^(?:\d+\s+)?(?:MALHA|RIBANA)\b/)) return 'raw_material'; + if (has(normalizedName, /\b(?:RETALHO|RESIDUO)\s+(?:DE\s+)?MALHA\b/)) return 'raw_material'; + if (has(normalizedName, /\bFIO\b.*\bMALHARIA\b/)) return 'raw_material'; + if (has(normalizedName, /\b(?:LINHA|FIO) PARA COSTURA\b/)) return 'raw_material'; + if (has(normalizedName, /ETIQUETA|TAG|FITA/)) return 'raw_material'; if (has(normalizedName, /\bKIT\b/)) return 'kit_bundle'; if (has(normalizedName, /TRANSPARENTE PP|SACO DE SEGURANCA|MILHEIRO|SACOLA|EMBALAGEM/)) return 'packaging'; if (has(normalizedName, /PRENSA|MAQUINA|OVERLOCK/)) return 'equipment';