Adding rules to relationship fields

You can apply Rules to all types of relationship fields (cards, charts, counts, grids, and trees).

About this task

Rules allow you to more precisely control whether a relationship field is visible or hidden. For cards and grids, rules can also control some aspects of what users can do with related objects.

Rules on relationship fields are based on the fields for the object type of the view. For example, if you are building a view for Risk objects and the relationship field is for Control objects, the rules are based on fields for the Risk object not the Control object.

In a rule, you specify a condition that checks for the existence of any value of a field or specific values of one or more fields on a object. If the condition is met, the rule is applied to the relationship field.

In all types of relationship fields (cards, charts, counts, grids, and trees), you can apply the following rule types:

  • Visible

    Shows the relationship field in a view if the rule is met.

  • Hidden

    Hides the relationship field in a view if the rule is met.

In cards and grids, you can apply the following additional rule types:

  • Editable

    Makes buttons in a card or grid visible and actionable if the rule is met.

  • Read Only

    Hides buttons in a card or grid if the rule is met. Users can view objects in the card or grid but cannot change them.

  • Required

    Makes it mandatory for the user to provide one object in a card or grid if the rule is met.

Procedure

  1. In the View Designer, click the Design tab.
    The palette is displayed.
  2. First, move the fields that are used in the rule from the palette to the canvas.
    In the following steps, the options in Rule Type vary depending on the relationship field type.
  3. In the property panel of a relationship fields, click New Rule.
  4. Select a Rule Type.
  5. In Controlled By, choose One field with any value or Multiple controllers or values.
  6. If you choose One field with any value:
    1. Select a Controlling Field. The system lists fields for the object type of the view that are on the canvas.
    2. Click Done.
  7. If you choose Multiple controllers or values:
    1. In Controlling Field Logic select All controlling field conditions must be met or Any controlling field condition may be met.
    2. Click New Controller.
    3. Choose a field in Controlling Field. The system lists fields for the object type of the view that are on the canvas. The next selections depend on the field type.
      • For actor fields, you can set Match Current User and/or select other users or user groups in Other Users or Groups. Any match on either field resolves the controller to true. If Match Current User is set to true, the signed on user must be the user or be in a user group for the value in the Controlling Field.
      • For enumerated type fields, click Values and you can choose one or more individual values.
      • Click Done.
    4. Click New Controller to add the next controller field. Repeat the previous steps. Continue until all controller fields have been added. Although you can change the order of the controller fields, it has no effect in the view.
  8. Click Done.