Hi,
I have a Grid component that is used for editing data in an arbitrary database table. The type of the grid is a class that doesn't have properties for each column, but rather simulates columns and row data based on the selected database table structure. The purpose of this is to enable the user to edit a certain database table without the need to define the exact data structure in the web application.
This works fine when displaying data and editing data. However, I need to implement filtering and things start to get tricky.
I have a snippet that simplifies the issue: https://blazorrepl.telerik.com/weYKFcvq2749nY9L57
Before trying to implement filtering, I had no Field attribute on my GridColumns and that worked fine. But when adding the FilterMode attribute to the TelerikGrid component the filter row isn't rendered at all (also not when using FilterCellTemplate). I've read other forum posts about the necessity of the Field attribute. When I add the Field attribute, the filter row is rendered but I get an exception stating "Value cannot be null. (Parameter 'nullableType')" with this stack trace:
at System.ArgumentNullException.Throw(String paramName)
at System.Nullable.GetUnderlyingType(Type nullableType)
at Telerik.Blazor.Common.Filter.FilterOperatorFactory.GetColumnDefaultFilterOperator(Type propType)
Is the component using reflection to determine the Type of the field? Or can I somehow tell the component dynamically what type to use, in the same way I can return the title or cell content dynamically?
I tried to use the filter template but I get stuck on the Field problem.