From b42be16c46ea667c578394e04b03a6683e8087d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Anna-Sara=20S=C3=A9lea?= Date: Wed, 25 Feb 2026 21:45:02 +0100 Subject: [PATCH] Added lan_id to more places --- resources/js/Pages/CustomerGroups.tsx | 19 +++++++++++-------- resources/js/Pages/Dashboard.tsx | 8 +++++--- 2 files changed, 16 insertions(+), 11 deletions(-) diff --git a/resources/js/Pages/CustomerGroups.tsx b/resources/js/Pages/CustomerGroups.tsx index 327b983..3315c15 100644 --- a/resources/js/Pages/CustomerGroups.tsx +++ b/resources/js/Pages/CustomerGroups.tsx @@ -12,6 +12,7 @@ interface CustomerProps { name: string customer_group_id: string, is_in_group: boolean + lan_id: number }], }; @@ -20,7 +21,7 @@ type Customer = { name: string customer_group_id: string, is_in_group: boolean - + lan_id: number }; interface CustomerGroupProps { @@ -32,6 +33,7 @@ interface CustomerGroupProps { name: string customer_group_id: string, is_in_group: boolean + lan_id: number }], }] }; @@ -44,6 +46,7 @@ type CustomerGroup = { name: string customer_group_id: string, is_in_group: boolean + lan_id: number }], }; @@ -86,7 +89,7 @@ export default function CustomerGroups({groups, customers} :( CustomerGroupProps setSearchItemCustomers(searchTerm) const filteredItems = customers.filter((customer) => - customer.name.toLowerCase().includes(searchTerm.toLowerCase()) + customer.name.toLowerCase().includes(searchTerm.toLowerCase()) || String(customer.lan_id).includes(searchTerm) ); setFilteredCustomers(filteredItems); @@ -161,7 +164,7 @@ export default function CustomerGroups({groups, customers} :( CustomerGroupProps setSearchItemCustomersAddToGroup(searchTerm) const filteredItems = customers.filter((customer) => - customer.name.toLowerCase().includes(searchTerm.toLowerCase()) + customer.name.toLowerCase().includes(searchTerm.toLowerCase()) || String(customer.lan_id).includes(searchTerm) ); setFilteredCustomersAddToGroup(filteredItems); @@ -211,7 +214,7 @@ export default function CustomerGroups({groups, customers} :( CustomerGroupProps .map( customer => { return })} @@ -228,7 +231,7 @@ export default function CustomerGroups({groups, customers} :( CustomerGroupProps .filter((filteredCustomer) => checkboxesAddToGroup.includes("" + filteredCustomer.id)) .map( customer => { return

- {customer.id}. {customer.name} + {customer.lan_id}. {customer.name}

})} @@ -281,7 +284,7 @@ export default function CustomerGroups({groups, customers} :( CustomerGroupProps .map( customer => { return })} @@ -298,7 +301,7 @@ export default function CustomerGroups({groups, customers} :( CustomerGroupProps .filter((filteredCustomer) => checkboxes.includes("" + filteredCustomer.id)) .map( customer => { return

- {customer.id}. {customer.name} + {customer.lan_id}. {customer.name}

})} @@ -354,7 +357,7 @@ export default function CustomerGroups({groups, customers} :( CustomerGroupProps