I want to fetch grid records page per page according to the appropriate filter settings. While this is possible through the OnRead event, I want to be able to send the request to the server so that it is easier to fetch the data, like in the UI for ASP.NET Core grid. Currently you can do this only for a server-side project because you can pass the request object by reference, but for a WASM project it needs to serialize in an HTTP request.
---
ADMIN EDIT
You can find examples of doing this here: https://github.com/telerik/blazor-ui/tree/master/grid/datasourcerequest-on-server
---
In the meantime, the Service example from the Grid State article shows one custom serializer that you can use for the time being: https://docs.telerik.com/blazor-ui/components/grid/state#save-and-load-grid-state-from-browser-localstorage
Regards,
Marin Bratanov
Progress Telerik
Hi,
You can use the OnRead event for that: https://docs.telerik.com/blazor-ui/components/grid/manual-operations
This particular snippet shows how you can page from a remote service: https://docs.telerik.com/blazor-ui/components/grid/manual-operations#custom-paging-with-a-remote-service.
You can see how to extract filter information so you can send it to the service in this snippet: https://docs.telerik.com/blazor-ui/components/grid/manual-operations#get-information-from-the-datasourcerequest
If you already have an OData service, you can consume it much more easily: https://github.com/telerik/blazor-ui/tree/master/grid/odata
We will also make the DataSourceRequest object serializable so you can skip all the information extraction and directly send it over to a controller action, in a fashion very similar to our UI for ASP.NET Core grid (reference - see the IndexController.cs and the Read events in it, the goal is for something similar to be available : https://demos.telerik.com/aspnet-core/grid/index).
Regards,
Marin Bratanov
Progress Telerik