Open ToshY opened 2 years ago
Issues: #3171 (2.x) #4245 (3.x) #4881 (3.x/4.x) Pull requests: #4236 #4840 #4882
The dot is a known problem for filters for a while... :(
Still 3 options to filter embedded or association fields (with dot):
@Ang3 Thanks for the reply. PR #4882 is still open, is there a reason not to merge that one?
Describe the bug After not being able to find in the docs on how to apply a filter based on a property of the entity I'd like to ask if it's even possible.
To Reproduce As an example, I have have a many-to-one relation from
User
toColour
denoted with the propertyuserColour
. TheColour
entity consists of a propertycolourCode
which is of type string.In the CRUD controller for
User
, let's say I have the following fields configured:Now I can use the
EntityFilter
onuserColour
to filter (which works), but if I wanted to filter onuserColour.colourCode
it doesn't seem to be that easy.Throwing the following error/stacktrace:
So am I missing something obvious here, either wrongly passing the property name or missing some options? Or is this either something that isn't working correctly, or maybe should a custom filter be used for such cases?
Additional context
Versions:
4.0.2
6.0.1
8.1