Event processing with action sets
A user interface (UI) can include controls that allow users to perform certain actions before submitting a form to provide a more interactive user experience.
The event-action model
Actionable controls are based on an event-action model, which establishes a cause-and-effect relationship for a control such as a check box or a button. The event is a trigger caused by user activity, such as a button click or field entry. The action is a response by the application, such as creating a case or displaying information about a field to guide user input.
For example, an online retailer wants to allow customers to use the shipping address for an order as the billing address for payment. The form for entering the billing address provides users with a check box. When the user selects the check box, the application copies the shipping address information to the billing address fields and disables any editing of the billing address fields. When the user clears the check box, the application removes any entries in the billing address fields and allows the user to enter an address.
In the center of the following image, slide the vertical line to view how the display of the address form changes when the user clicks and clears the check box.
The following table lists examples of event-action pairs.
|Click a control such as a button, link, or icon
|Open a new window
|Double-click a row in the grid
|Allow editing of the contents of the row
|Press the Enter key on the keyboard
|Display a menu
|Select a value from a list of states or provinces
|Update the list of office locations
|Enter a value in the Quantity field
|Verify that inventory is sufficient to fulfill the order
In a Pega Platform™ application, you use an action set to configure an actionable control. An action set consists of one or more events and one or more actions. Optionally, you can add conditions to each action so that the action occurs only when the conditions are met.
In the following image, click the + icons to explore how an action set can populate the billing address fields on a form when submitting an order to an online retailer.
Check your knowledge with the following interaction.