Warning attributes identify when a configuration has entered a disallowed state and inform the user. These rules can be arbitrarily complex and are frequently used in composite configuration scenarios. Triggered warning attributes prevent the promotion of a configuration's state and, depending on the configuration state, can also block the user from saving the configuration.
An attribute used as a rule
A warning attribute is an attribute that is used as a rule. Therefore, warning attributes are created like any other attribute and are found in the product's list of attributes, rather than among the rules.
Settings for warning attributes
The settings below are important to consider for a warning attribute:
Setting name |
Description |
|---|---|
Sum type |
Recommended to be set to New line separated. In this way, the same warning attribute can be linked to a product multiple times with different triggers and messages. If multiple instances of the attribute are triggered, a combined message with line breaks between the individual messages will be generated. |
Value type |
Must be String. |
Is warning |
Must be checked. |
Resolve warning mandatory from state |
Defines the state from which it is mandatory to resolve the warning. Promoting to this state or higher is not allowed while the warning is triggered. If the configuration is already in the specified state, saving the configuration is blocked as long as the warning remains active. |
Title |
The title can often be left blank for warning attributes. This allows the message generated by the Value expression to use the full available space when the warning is displayed in an attribute panel. |
Inclusion expression (Product / Attribute link) |
Defines the trigger for the warning. |
Value expression (Product / Attribute link) |
Defines the message for the warning. |
Sum with previous value (Product / Attribute link) |
Must be checked if the same warning attribute is linked to a product multiple times. |
Display warning messages
Warning messages are automatically displayed in pop-up dialogs when saving or promoting a configuration's state is blocked due to a triggered warning attribute. However, it is also useful to display warning messages directly within the user interface so that users are immediately notified of problems after warning attributes are triggered.
To display a warning message, use an attribute panel and place it close to the parameters that can trigger the warning, or on a separate tab that is visible at all times. Ensure that the Hide attributes with empty values option is enabled for the attribute panel so that empty (non-triggered) messages are not displayed.