I would like to request the data-query package support filtering on OData collections using lamdba functions. Given a Collection with the existing operators, the filter string outputted by `toODataString` should be OData v4 compliant.
Example: Project is a collection. A user filters to see all General projects which outputs { field: 'Project', operator: 'eq', value: 'General' }.
Recommendation: Supply another key that dictates the lamdba operator and property field to use.
{ field: 'Project', operator: 'eq', value: 'General', lambda: 'any', collectionField: 'Name' } -> $filter=Project/any(x:x/Name eq 'General')
The above can work with inner functions like contains.
{ { field: 'Project', operator: 'contains', value: 'gen', ignoreCase: true, lambda: 'any', collectionField: 'Name' } -> $filter=Project/any(x:contains(tolower(x/Name),'gen'))
Hello, Price,
Thank you for your interest in this feature.
This is currently not part of our short term ToDo list, but this may change based on its popularity.
We go on the feedback portal before each planning and pick the top components/features based on the community interest.
Regards,
Stefan
Progress Telerik
To add to this, we also have Singles that aren't collections. The above example would extend to:
{ field: 'Location', operator: 'eq', value: 'Home', innerField: 'Name' } -> $filter=Location/Name eq 'Home'