ParamQuery grid support forum
General Category => Help for ParamQuery Pro => Topic started by: queensgambit9 on February 10, 2020, 07:12:20 pm
-
Is it possible to include value of toolbar select in a state?
-
The API was not pre designed for it but I found it working.
First include the toolbar items in the state with stateKeys option.
stateKeys : { toolbar: ['items']}
Then during restoration of state, please add this besides call to loadState:
grid.option('toolbar').items[index of select item in the toolbar].value = JSON.parse(grid.getState()).toolbar.items[index of select item in the toolbar].value
grid.refreshToolbar();