How do I change Activity Time based on Entity Attribute?

The activity time or some other activity action is based on the value of a particular attribute of the entity.

Suggested Technique

1. Define an attribute for the entity in the Insert -> Attributes & Variables dialog. Optionally, you may use one of the predefined attributes.

2. Set the attribute to the desired value in any action logic in the model using the assignment statement.

3. Use an IF…THEN statement in the Action logic of the activity specifying the time or other action statements to be executed based on that attribute.

IF a_Type = REGULAR THEN
   {
   Time 8 Min
   }
ELSE
   {
   Time 5 Min
   }

Example: Two types of Orders are processed in a system: Regular and Pre-invoiced . At the Log In activity, Orders which have been previously designated as Regular orders require an invoice to be printed and therefore take 8 minutes to process. Pre-invoiced orders take only 6 minutes to process.

TO DO: Define a descriptive attribute called Type with the descriptors Regular and Pre Invoiced. Assign the appropriate descriptor to the attribute in some Action logic prior to the Log_In activity. Enter the Action Logic (as shown above) to determine the type of order and act accordingly.

If the attribute assignment is based solely on percentage and this is the only activity where the attribute is used to make a decision, use the Percentage-Dependent Activities technique below.

Was this article helpful?

Related Articles

Go to Top