Enumeration List and Unassigned Literal
Any ideas on how I can stop the unassigned literal from being a valid option?
Accepted answer
2 other answers
What version of RTC?
Dependent on what you have, I would check what information an enumeration list attribute returns a list of enumeration literals so you can't test against "unassigned" you will have to test if the list is empty, if not you will have to check on multiple values. I assume your condition is not designed to handle enumeration lists and you will have to think about what "required" means in this context.
If this is JavaScript based, there might be a problem to actually access the enumeration list attribute. I had issues with list attribute values, as far as I can remember.
Comments
Hi Ralph,
I have a simple javascript condition that checks if another attribute is blank. If this attribute is set then I want my enumeration list attribute to be mandatory. Unfortunately mandatory means users can still select the value that we have assigned to be the "Unassigned literal" (None) in this case.
This method works fine for regular single select enumeration (single select) attributes.
Version is 5.0.2
So what checks for mandatory and what does that mean in case of an enumeration list? If it is the required for condition precondition that ships with RTC, I would assume that - if it works at all for list attributes - that it checks for a literal has to be available, The "Unassigned literal" is a literal.
You might consider this a bug, if so approach support with a PMR, On the other hand, as I mention, what "required" means for a list type attribute is something completely different from a not list type attribute. You can argue about what should or should not be available for selection and how the condition should work, there might be good reasons for multiple different approaches.
i.e. for an enumeration list, default is blank. For type enumeration default is the default literal.