A Catalog UI policy applies to either a specific catalog item or any item that uses a specific variable set.
It can only contain and reference variables that are defined for the catalog item or variable set, and can control the behavior of the same, as long as they are visible and have names. Properties of variables read only, visible and mandatory or any other can be controlled by creating Catalog UI Policy Action or by using Client Scripts.
It is not uncommon for any given Catalog Item to have UI Policies that apply to it from both Variable Sets and the Catalog Item itself. This can cause conflicts if the various UI Policies have actions on the same fields. To reduce this type of conflict there is an Order field on every UI Policy record. UI Policies with lower numeric order values are run before higher order variables. For example, 1 goes before 2. Because the UI Policy that runs last is the one whose operations will take effect, it is said that the UI Policies that run last take precedence.
However, there is also an order of precedence between UI Policies on Variable Sets and Catalog Items. UI Policies on Catalog Item take precedence over UI Policies on Variable Sets. UI Policies on the Variable Sets runs first and then the UI Policies of the Catalog Item. Hence, if there are conflicting UI Policies, UI Policies on Catalog Item will always takes precedence over UI Policies on Variable Sets.
NOTE: There is one exception to the above rule. If the glide.sc.ui_policiy.variable_set_run_first property is set to false, then UI Policies on Variable Sets will run second and therefore take precedence over UI Policies on Catalog Items.
The order of the policies come into picture only when we are dealing with either Catalog Item UI Policy or Variable Set UI policy, and the policy with higher order takes precedence.
Note that conflict cannot be resolved by reordering policies, which are one in each type, Catalog Item UI Policy and Variable Set UI policy.
- A field value is not as expected
- A field property such as read-only or visible is not as expected
The UI Policy that ran last will take precedence. A Variable Sets UI Policy, regardless of the value of the Order field, will never take precedence over any Catalog Item UI Policy.
Review the design of your solution and ensure that the UI Policies that you want to take precedence run after any conflicting UI Policies.
For more information, see Service Catalog UI Policy in the product documentation.