It's all about the answers!

Ask a question

Dependent enumeration, prevent invalid values after save?


Michelle Stein (1579) | asked Sep 09 '14, 2:34 p.m.
edited Sep 09 '14, 2:36 p.m.
I have created a dependent enumeration using attribute customization, value sets, dependencies etc. 

Everything is working as expected, dependent enum drop-down is populated only with values that are valid for the source attribute.

However, if after I save my Work Item, I choose a different value for the Source attribute, I am able to save the work item even if the dependent enumeration is not valid for the new value. There is a little red X to the left of the field, and only the new valid values will appear in the drop-down for the dependent field, but I can still save bad data.

Am I missing a flag or option somewhere, or is this a bug?

Comments
sam detweiler commented Sep 09 '14, 3:25 p.m.

you had value 1 selected, went thru the dependents and picked the sub values, saved..
then changed the top level, and did NOT go thru the dependents, and saved.. and it worked..

right? 

seen that since 3.0.1 days.


Michelle Stein commented Sep 09 '14, 3:28 p.m.

Yup, that is exactly what happened, but the OB rule below fixed it. 


sam detweiler commented Sep 09 '14, 3:47 p.m.

this just stops you from saving.. til you go thru them, right..


Michelle Stein commented Sep 09 '14, 3:51 p.m.

Gives you an error on save, same as if you were missing a required field or had a permission issue. Then you can fix and save. 

Accepted answer


permanent link
Dinesh Kumar B (4.1k413) | answered Sep 09 '14, 2:44 p.m.
JAZZ DEVELOPER
edited Sep 09 '14, 2:47 p.m.
"Attribute Validation" Precondition on Work Item Save Operation should be used.

The precondition "Attribute Validation" is defined as :
"Verifies that a work item can only be saved if all attribute values are valid."

and is reached on Eclipse Client from :
Open PA in Eclipse Client > Process Configuration Tab > Team Configuration > Operation Behavior > Work Items Operation > Save Work Item (Server) > Pick a Role this should apply to > Under Preconditions Section > Select Add to find Attribute Validation and add it

hope it helps.

Michelle Stein selected this answer as the correct answer

Comments
Michelle Stein commented Sep 09 '14, 3:22 p.m.

Thanks, that worked. This rule wasn't mentioned in documentation, can't imagine why anyone would want to save with invalid attributes.

Your answer


Register or to post 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.