- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2015 06:57 AM
Hi all. I've been reading some of the many discussions on Catalog Task variables in order to resolve my issue but haven't found anything definitive. Here's what I'm trying to achieve:
On a Catalog Task I have two variables 'sdr_replace_success' and 'sdr_issues'. sdr_replace_success is a Yes/No field with None. If the selection is 'no' I want to make sdr_issues mandatory. To do this I've been trying to use a UI Policy with Scripts enabled. Here is what I've ended up with with no success:
Solved! Go to Solution.
- Labels:
-
User Interface (UI)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2015 07:12 AM
I think you are creating this as a "normal" UI Policy on the Task form, correct? I would create it as a Catalog UI Policy instead and check the "Applies to Catalog Tasks" field:
You may have to switch to the the "Advanced" view to see the field. And then you can use a "Catalog UI Policy Action" to set the variable to mandatory instead of with a script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2015 07:03 AM
I know when doing this in a catalog ui policy or catalog client script (which incidentally you can tick to run on items and task forms too).
then you just need to use g_form.setMandatory('variable_name'), not variables.variable_name.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2015 07:08 AM
Thanks but that didn't seem to work
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2015 07:22 AM
He's doing it on the catalog task itself and not on the variable/item level so he needs to use "variables.variable_name" in this case.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-16-2015 07:12 AM
I think you are creating this as a "normal" UI Policy on the Task form, correct? I would create it as a Catalog UI Policy instead and check the "Applies to Catalog Tasks" field:
You may have to switch to the the "Advanced" view to see the field. And then you can use a "Catalog UI Policy Action" to set the variable to mandatory instead of with a script.