fix search at manage position

This commit is contained in:
Raja Oktafrianto
2025-05-02 11:24:30 +07:00
parent 49cdbbf12a
commit 50b9c15d91

View File

@ -17,13 +17,13 @@ const ListToolBar = () => {
}; };
const handleSearch = () => { const handleSearch = () => {
table.getColumn('username')?.setFilterValue(searchValue); table.getColumn('name')?.setFilterValue(searchValue);
table.setPageIndex(0); table.setPageIndex(0);
}; };
useEffect(() => { useEffect(() => {
const timer = setTimeout(() => { const timer = setTimeout(() => {
table.getColumn('username')?.setFilterValue(searchValue); table.getColumn('name')?.setFilterValue(searchValue);
table.setPageIndex(0); table.setPageIndex(0);
}, 200); }, 200);
return () => clearTimeout(timer); return () => clearTimeout(timer);