DataGrid Pager page count doesn't update after using Filter API #784

Open
opened 2026-01-29 17:43:16 +00:00 by claunia · 0 comments
Owner

Originally created by @Benjathing on GitHub (Mar 28, 2023).

Describe the bug
After filtering the data grid using the Filter API, the PageCount value doesn't change from that of the original unfiltered value. In the case where this filtered list is less than the page size, this means the pager is still shown.

To Reproduce
Steps to reproduce the behavior:

  1. Create a DataGrid with multiple columns
  2. Create a function that sets the filters on one of these columns after the data grid has already loaded

Expected behavior
Pager should not show when the filtered result set is less than the Page size. Note that in debugging grid I can see that although Count = 4, PageNumbersCount still equals 5, which is what it is when the list isn't filtered.

Screenshots
image
image

Desktop (please complete the following information):

  • OS: Win10
  • Browser Edge
  • Version (Radzen.Blazor) 4.7.14

Additional context
If you click on any of the pager buttons, or sort any of the columns, the pager updates itself and realises it's not meant to show. However, I can't seem to be able to get it to recognise this during grid.Reload()

Originally created by @Benjathing on GitHub (Mar 28, 2023). **Describe the bug** After filtering the data grid using the Filter API, the PageCount value doesn't change from that of the original unfiltered value. In the case where this filtered list is less than the page size, this means the pager is still shown. **To Reproduce** Steps to reproduce the behavior: 1. Create a DataGrid with multiple columns 2. Create a function that sets the filters on one of these columns after the data grid has already loaded **Expected behavior** Pager should not show when the filtered result set is less than the Page size. Note that in debugging `grid` I can see that although Count = 4, PageNumbersCount still equals 5, which is what it is when the list isn't filtered. **Screenshots** ![image](https://user-images.githubusercontent.com/10608747/228136822-df517d69-cdb4-4af5-8641-8496cc0d3f24.png) ![image](https://user-images.githubusercontent.com/10608747/228137869-5a8e9029-cb17-4ea6-aa4c-0bf8ef733a75.png) **Desktop (please complete the following information):** - OS: Win10 - Browser Edge - Version (Radzen.Blazor) 4.7.14 **Additional context** If you click on any of the pager buttons, or sort any of the columns, the pager updates itself and realises it's not meant to show. However, I can't seem to be able to get it to recognise this during `grid.Reload()`
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/radzen-blazor#784