Is this the correct syntax for dynamically adding a filter to a bottom toolbar of gridpanel?
this.Grid.getBottomToolbar().plugins=[filters];
There are no errors when I do this. But it does not behave as promised. i.e. the paging does not reset to 1 when the filter is fired.
SoI load the page, go to page 2, then change the filter and there is only 1 record(say). It shows: page 2 of 1 because the paging is not reset.
Is my syntax correct?
The docs say:
Paging : If specified as a plugin to
the grid’s configured PagingToolbar,
the current page will be reset to page
1 whenever you update the filter.
this is not the correct way no … you should attach your filters when creating your instance of the bottom toolbar, you are adding it to he plugins array probably after it has already been created and that’s too late for the grid to register the plugin behaviour on itself.