Skip to content

Commit 5b16c68

Browse files
committed
set default to contains
implements #4130
1 parent 358daa7 commit 5b16c68

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/components/CippTable/CippDataTable.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -376,6 +376,7 @@ export const CippDataTable = (props) => {
376376
}
377377
},
378378
},
379+
globalFilterFn: "contains",
379380
enableGlobalFilterModes: true,
380381
renderGlobalFilterModeMenuItems: ({ internalFilterOptions, onSelectFilterMode }) => {
381382
// add custom filter options
@@ -448,14 +449,14 @@ export const CippDataTable = (props) => {
448449
if (filters && Array.isArray(filters) && filters.length > 0 && memoizedColumns.length > 0) {
449450
// Make sure the table and columns are ready
450451
setTimeout(() => {
451-
if (table && typeof table.setColumnFilters === 'function') {
452-
const formattedFilters = filters.map(filter => ({
452+
if (table && typeof table.setColumnFilters === "function") {
453+
const formattedFilters = filters.map((filter) => ({
453454
id: filter.id || filter.columnId,
454-
value: filter.value
455+
value: filter.value,
455456
}));
456457
table.setColumnFilters(formattedFilters);
457458
}
458-
},);
459+
});
459460
}
460461
}, [filters, memoizedColumns, table]);
461462

0 commit comments

Comments
 (0)