I have a DataGrid that's working using virtualisation (via LoadData/OData).
If I set AllowGrouping="true" AllowVirtualization="false" AllowPaging="true", grouping works as expected.
If I set AllowGrouping="true" AllowVirtualization="true" AllowPaging=[true or false, it makes no difference], then no grouping happens.
It does exactly the same when I edit the examples, for instance the DataGrid OData one. Is this by design, a bug, or something that hasn't been implemented for some reason?
Thanks. Not supported and never will be because of some technical limitation, or just not supported yet?
My presentation layer is separated from my data layer, so to use IQueryable with a DB context in the view would be... non-trivial, and would break the separation of concerns.
Interestingly, the example at /datagrid-loaddata uses LoadData, and enabling grouping and virtualisation works there. Even though it uses a DB context AsQueryable, it only uses that query to Skip and Take, the same as the OData example. So what's the difference?
Right, thanks. And I'm guessing that the limitation is that the grid groups data by querying the data source directly.
But am I right in thinking that this is technically possible by passing query parameters via LoadDataArgs (for example the 'select' parameter that NorthwindODataService.GetEmployees seems to support), and hand off the heavy lifting to the upstream data service?
$select parameter will not work, $apply=groupby() is needed however it’s not supported nor something easily to implement, still we accept pull requests!
After a look at the source, I think adding IEnumerable Groups to LoadDataArgs is better to support nested groups, add support for that in LoadItems, LoadGroups and InvokeLoadData, then stop that combo from being blocked in DrawRows and ReloadInternal. Might not be as simple as it looks, but one way to find out!