Enumeration - limit selectable items based on Value?

0
Hi, happy new year. Is it possible to somehow limit the selectable values of an ENUM based on a attribute value? For example my ENUM has the the values “New”, “Under Review”  and “Finished”. The user should only see the value “Under Review” if the current status is “New”. Is this possible? Best Tjark
asked
3 answers
2

While this is not directly possible, you can achieve this type of functionality a number of alternative ways. The simplest is to render buttons instead of a dropdown selector. Each button can run a nanoflow that sets the enumeration to a particular value. You can show and hide the button for each status value based on any conditional visibility expression. I hope this helps!

answered
1

Hi, happy new year to you too.

AFAIK, it is not possible to add a constrain to the displayed enum values. However, you could hide the values using CSS and dynamic classes.

Alternatively, you could consider not using an enum, but an entity “Status” that you can constrain programmatically.

answered
1

https://marketplace.mendix.com/link/component/111237

We have found a solution with this widget. :-) It allows you set conditional visibility and the selectable items. This in combinations serves for our intended purpose. We simply display the matching widget for a given situation.

 

answered