Hi guys,
I’m having a strange issue with valuelists and find mode.
I have a main “colors” valuelist and a “colors_fallback” valuelist to be used as fallback to the first. Both list are of type custom and are populated at login using sql queries.
Everything works fine except when the form is in find mode, when in find mode the main valuelist is not used and the fallback one kicks in.
I don’t think this is a correct behavior, the fallback valuelist should be used only for display purposes when a field has a value that is outside the main valuelist, so just to avoid showing an empty field (according to the documentation).
Should I open a case?
Hi,
This is correct behaviour, because a fallback list shows all posible values.
The “normal” valuelist shows only values that the user may choose from at this time, whilst the fallback list also contains values that are no longer available for the user.
So in findmode the fallback list should be used to be able to find any value !
This is exactly as we use it and want it to be.
Regards,
I can understand that you use it like this and like it like this, but that doesn’t mean it’s the correct behavior.
In my scenario it doesn’t work for example, I’m not sure which one would be the correct behavior, both scenarios make sense and are real world cases but at least I would like this to be documented and maybe there should be an option to decide how the list should behave in find mode.
In my case the main list shows the color code and the color description while the fallback list shows only the color code (this is to workaround the issue for some colors not having yet a record in the table for the selected language), if I want in find mode to use the list with both code and description I would need to create a third list. Looks like an overkill to me, especially since I cache those list in memory at login.
A simple option like (use the fallback list on find mode true/false) would address both use cases.
Please servoy staff, add this to the documentation if it’s intended behavior, we can’t always “fallback” to the forum.