Enumeration List and Unassigned Literal
![]()
I currently have a precondition to require an attribute for a certain condition. This attribute is of type 'enumeration list'. Even though I have set a value in the enumeration for this attribute as the 'unassigned literal', it is still allowed to be set . Default literal doesn't seem to be used for 'enumeration list'
Any ideas on how I can stop the unassigned literal from being a valid option? |
Accepted answer
2 other answers
![]()
Ralph Schoon (63.3k●3●36●46)
| answered Apr 08 '16, 8:45 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
What kind of precondition is that? A JavaScript condition? A Server side Plugin?
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,
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.
i.e. for an enumeration list, default is blank. For type enumeration default is the default literal.
|
Your answer
Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.