Skip to content

Commit

Permalink
Fix bug with editing filters.
Browse files Browse the repository at this point in the history
  • Loading branch information
nsthorat committed Feb 14, 2024
1 parent e41abe0 commit 6c09cda
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,9 +97,7 @@
}
function submit() {
for (const filter of stagedFilters) {
datasetViewStore.addFilter(filter);
}
datasetViewStore.setFilters(stagedFilters);
close();
}
</script>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,8 @@
};
$: keywordSearchItem = {
id: 'keyword-search',
text: searchText
text: searchText,
disabled: searchText == ''
} as SearchItem;
$: semanticSearchItem = {
id: 'semantic-search',
Expand Down
7 changes: 7 additions & 0 deletions web/blueprint/src/lib/stores/datasetViewStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -273,6 +273,13 @@ export function createDatasetViewStore(
state.selection = undefined;
return state;
}),
setFilters: (filters: Filter[]) =>
update(state => {
state.query.filters = filters;
state.rowId = undefined;
state.selection = undefined;
return state;
}),
showTrash: (show: boolean) =>
update(state => {
state.rowId = undefined;
Expand Down

0 comments on commit 6c09cda

Please sign in to comment.