Loading
The online Trailblazer Community becomes read-only Oct 30, 2026Read More
Important Advisory: iOS Update Impacting CG Mobile ApplicationRead More
Insurance
Create Attribute Rules

Create Attribute Rules

Create attribute rules that define how attributes and their values are shown or hidden from users.

  1. Open the child spec or root product spec you want to add attribute rules to.
  2. On the Attributes tab, click the row of the attribute you want to add a rule to.
  3. On the right pane where the attribute details are, click the Rules icon The rules icon. at the top of the pane.
  4. Click Add Rule.
  5. Choose a Type.
    • Hide

      Hides this attribute/value if the expression you enter in step 4 = true.

    • Message

      Displays a message if the expression = true.

      You can choose from four message types:

      • Information: Black text

      • Warning: Orange text

      • Error: Red text

        In an OmniScript LWC, if you select Error for tasks associated with an attribute value rule the error message displays, but the user can continue with the task without resolving the error.

      • Recommendation: Blue text

    • Set Value

      Displays a value if the expression = true. You must enter a value to set. The value can be calculated, static, or any of the functions listed in the Functions box below.

    • Set Default Value

      Sets a default value for this attribute to display if the rule condition is met. The user can change this value when going through a quote or policy flow.

      The InsProductService: getRatedProducts runs this rule.

  6. Enter the rule into Expression.

    If you're creating a Set Value or Set Default Value attribute rule that applies to a specific user profile, use the syntax USER_PROFILE == '<profile name>'. For example:

    USER_PROFILE == 'Customer Service Representative'

    Important
    Important

    If you use a Picklist attribute in a Set Value or Set Default Value rule, verify that the rule expresses the attribute's data type as text for the Value to Set and in the rule's Expression. Picklist attribute values are stored as text, even if the corresponding picklist has another Data Type, such as Number.

 
Loading
Salesforce Help | Article