Enabled Condition is a general model class in which relationships can be linked to actions, tools or dialog input fields. This determines the conditions under which the execution of an action or tool is permitted or an input dialog field is editable, grayed out or hidden.
The boolean attribute Hide triggers whether the disabled action or dialog field will be grayed out or completely hidden from a UI context menu or dialog. This attribute is ignored for tool enabled conditions.
When modeling an enabled condition, the administrator defines the permitted values for certain properties, so that the action can be executed. By doing this, simple and complex rules can be defined, where complex rules link the simple rules via operators.
Simple Enabled Condition Example:
A Complex Enabled Condition contains any number of simple and complex enabled conditions, and links these via operators.
In addition, the number of resources that can/must be selected so that an action is executable can be determined for an enabled condition. This value is ignored for tool enabled conditions and for dialog fields enabled Conditions.
The enabled condition for an element action is defined here. It begins with a complex enabled condition (center, bottom), which links the two simple enabled conditions (lower left and right) with the AND operator. AWM interprets this model as follows:
Action ACT_X from ElementType ELE1 can only be executed if the property value of PROP_Protected is false and corresponds to the property value of Property PROP_Group “TEST”. In addition, exactly one Element must be marked.
A simple enabled condition checks a property value for a defined value or status, and activates or deactivates the action depending on the result of the check.
The meanings of the various operators are shown in the following table:
Operator | Meaning | Example |
---|---|---|
Equals… | Checks whether the property value of the referenced property has the same value as specified in "Value". | The action can only be executed if the selected element is a COBOL program: |
Equals not… | Checks whether the property value of the referenced property has a value different from the specified "Value". | The action can only be executed if the selected element is not in production: |
Regular Expression | Checks whether the property value of the referenced property matches with the regular expression specified in "Value". | The action can only be executed on COBOL files: |
NULL | Checks whether the referenced property has no property value. | The action can only be executed if the selected element has no access key: |
NOT_NULL | Checks whether the referenced property has any property value. | The action can only be executed if the selected element has a change date: |
TRUE | Checks whether the referenced property has the Boolean value true. The valid value for true which is checked during run time is defined in the property definition. | The action can only be executed if the selected element can be edited: |
FALSE | Checks whether the referenced property has the Boolean value false. The valid value for false which is checked during run time is defined in the property definition. | The action can only be executed if the selected element is not write-protected: |