Validator javascript handler question
I have a couple custom fields on a workitem, which are workitem and workitemList types.
they function like I want them to, except for one item, I want to constrain the workitemtype allowed to be selected.
the add function brings up the 'pick any workitem (or create one)' dialog.
I know we cannot customize that (shame, would be SO easy with a couple optional properties for the presentation)
anyhow.. so I want to prevent saving if one picked the wrong workitem type.
but I don't think I can get access to this field contents (workitem or list) in javascript.
am I correct?
they function like I want them to, except for one item, I want to constrain the workitemtype allowed to be selected.
the add function brings up the 'pick any workitem (or create one)' dialog.
I know we cannot customize that (shame, would be SO easy with a couple optional properties for the presentation)
anyhow.. so I want to prevent saving if one picked the wrong workitem type.
but I don't think I can get access to this field contents (workitem or list) in javascript.
am I correct?
2 answers
thanks.. my issue is that the linked doc says 'limited' types.. and the workitem and workitemList type fields are not listed..
and if its a list type, I need to run thru the list as well.
was thinking javascript so I wouldn't have to reboot the production servers. altho the osgi console should allow us to do that... another training exercise.
and if its a list type, I need to run thru the list as well.
was thinking javascript so I wouldn't have to reboot the production servers. altho the osgi console should allow us to do that... another training exercise.
Sam, you can get triggered by the work item type and potentially prohibit save, I think. The type as of https://jazz.net/wiki/bin/view/Main/AttributeCustomization is WorkItemAttributes.TYPE. If you validate to error and configure the operational behavior to prevent error level validation a from saving, you should be good. I have not tried that myself. I would probably rather go for a custom Advisor myself.