diff --git a/openbis_ng_ui/src/js/components/common/grid/GridController.js b/openbis_ng_ui/src/js/components/common/grid/GridController.js index cb051ac674cd307aaa6cda72b493de4b0ecc8ad3..cb86961370681fa34f4692e99a506924a5fd25a2 100644 --- a/openbis_ng_ui/src/js/components/common/grid/GridController.js +++ b/openbis_ng_ui/src/js/components/common/grid/GridController.js @@ -724,12 +724,12 @@ export default class GridController { ) } - async handleGlobalFilterChange(globalFilter) { - const { local } = this.context.getState() + async handleGlobalFilterChange(newGlobalFilter) { + const { local, globalFilter } = this.context.getState() await this.context.setState(() => ({ page: 0, - globalFilter + globalFilter: newGlobalFilter })) if (this.loadTimerId) { @@ -743,6 +743,10 @@ export default class GridController { }, local ? LOCAL_GRID_RELOAD_PERIOD : REMOTE_GRID_RELOAD_PERIOD ) + + if (globalFilter.operator !== newGlobalFilter.operator) { + await this._saveSettings() + } } async handleColumnVisibleChange(name) {