Feature request #21825

value relation widget having both a parent key value and a child key value

Added by Robin Rotsaert about 2 years ago.

Category:Edit widget
Pull Request or Patch supplied:No Resolution:
Easy fix?:No Copied to github as #:29640


when setting up drive down cascades with the value relation widget things get quite complicated when one wants to set up a "multiple-step drive down cascade" (value in field A affects the drop-down of field B, value of field B on his turn affects the drop-dwon of field C), especially when there is overlap between groups (a value in field C can be child of several values in field B)

the problem, in my view, is that the key column for field B acts both as parent reference and as child reference

I found a workaround using the filter expression
NOT regexp_match("foreign_key",current_value('parent_field'))=0
combined with some complex values in the key-field, but as the list of values gets longer the key-values one has to invent get more complex as well + this way of working is not straightforward at all

Also available in: Atom PDF