Mewriick / Blazor.FlexGrid

GridView component for Blazor
MIT License
199 stars 35 forks source link

Clear or properly persist filtering on refresh #115

Open MAndrade1980 opened 3 years ago

MAndrade1980 commented 3 years ago

Hi, please see the attached solution for an example of an issue we're having with the filtering. If you assign a filter on the main page, let's say column 1 equal "Item 1", the filter looks good. If you either go to page 2 then come back, or even hit the clear or load grid buttons I have set up, the grid loads all records again but the filter button is still green, so it appears the filter should be persisting, but is really not. I was hoping I could null the adapter and recreate it, but the buttons are actually doing that and it is not affecting the filter at all. We'd like to persist the filtering for the time being, but overall it'd be nice to have a toggle on the component to persist the filtering or not. Seems it's doing a bit of both at the moment. Would you be able to take a look at this?

Many thanks!

FlexGrid.zip

MAndrade1980 commented 3 years ago

Hi, along the same lines, the paging and sorting should be persisting when coming back to the grid from another page.

Mewriick commented 3 years ago

Hi, I will look into this weekend

pawelhmz commented 3 years ago

Hi, I will look into this weekend

Hi. Any update about this ?

Mewriick commented 3 years ago

Sorry guys, I had some problems and I had no time. I will look into this probably tommorow

Mewriick commented 3 years ago

Hello @MAndrade1980 , @pawelhmz new version is released and new functionallity is added. If you use during configuration methods EnablePreserveFiltering and EnablePreservePagination during navigating between pages the state schould be correctly restored. Please see little breaking change in new release