ui: fix session fetch on saved search apply

This commit is contained in:
nick-delirium 2024-10-31 14:08:38 +01:00
parent c239d8d080
commit b9bf65d67b
No known key found for this signature in database
GPG key ID: 93ABD695DF5FDBA0
2 changed files with 5 additions and 3 deletions

View file

@ -82,7 +82,7 @@ function SavedSearchModal(props: Props) {
<div style={{ maxHeight: 'calc(100vh - 106px)', overflowY: 'auto' }}>
{shownItems.map((item) => (
<div
key={item.key}
key={item.searchId}
className={cn('p-4 cursor-pointer border-b flex items-center group hover:bg-active-blue')}
onClick={(e) => onClick(item, e)}
>

View file

@ -50,14 +50,16 @@ function SessionSearch(props: Props) {
// void searchStore.fetchSessions(true)
}, []);
useEffect(() => {
debounceFetch();
}, [appliedFilter.filters]);
const onAddFilter = (filter: any) => {
searchStore.addFilter(filter);
};
const onUpdateFilter = (filterIndex: any, filter: any) => {
searchStore.updateFilter(filterIndex, filter);
debounceFetch();
};
const onFilterMove = (newFilters: any) => {