Unplanned
Last Updated: 30 Jul 2024 09:38 by Mattia
Mattia
Created on: 30 Jul 2024 09:38
Category: Grid
Type: Feature Request
1
Do not fire OnRead twice when aggregates are defined

As of UI for Blazor 6.0.2 OnRead event handler is triggered twice if Grid has defined the GridAggregates Parameter (if you try defining Grid without the GridAggregates Parameter, the OnRead event handler is caller once). In the first call the args.Request.Aggregates value is empty, while in the second one that field is populated correctly.

The behavior may be related to the fix of this issue but I'd prefer the Grid to fire OnRead only once if possible.

===

ADMIN EDIT

===

Currently, OnRead fires twice only on initial load. A possible optimization that you can implement on your side is to toggle a flag based on which you can process the data only once. You can do that in the second OnRead as this is when the AggregateResults field of the request gets populated.

Here is a basic example: https://blazorrepl.telerik.com/GokrRkYX536x1mSF35.

0 comments