HowTo: Create an Action in the GXflow Client

Unofficial Content
This documentation is valid for:

This article explains how to create a new action in the GXflow Client. Also, for the sake of example, it will explain how to create an action that calls a WebPanel and displays the parameters received.
It is important to understand that more useful actions than the explained below can be achieved with this functionality, but for simplicity purposes this article is focused on explaining how to create an action and not what an action does -in other words, its code.

Step 1 - Create a new WebPanel

Create a new Web Panel object called "ActionReceiveParms".

Rules

Parm(in:&char);

Variables

char (Type: Character)

Add a Textblock with the "Received:" caption and the "char" variable to the layout.

Step 2 - Run the GXflow Standard Client

First, open your GXflow Standard Client application. To do so, right-click on one of your Business Process Diagram object and select Run:

GXFlowDiagramRun

Step 3 - Login

Log in with a user that has the role GXflow Backend Administrator—see Management Console for details on how to manage users and roles.

Note: when using GeneXus Access Manager the GAM Web Backoffice must be used in order to manage users, roles and permissions.

Step 4 - Open the Actions component

Open the Actions component by selecting it—it is located under the Backend node.

GXFlowCustomActionsAndTree

The GXflow Actions dialog will be opened.

Step 5 - Create a new Action

Press the GXFlowNextButton button, and set the properties as follows:

GXFlowCustomNewActionGeneralParms   GXFlowCustomNewActionApplicationParm

It is important to set the ClassName property to "ActionReceiveParms"—the name of the Web Panel created in step 1— and to disable the "Is Batch?" property so the Web Panel is called as a popup.
Then the properties "Apply on selection" and "MultipleSelection" are used to use the IDs of the selected rows as parameters.

Therefore:

  • Apply on selection: if this property is enabled, a string containing the ID of the selected row is used as parameter.
  • Multiple Selection: if this property is enabled, a string containing the set of IDs separated by commas of the selected rows is used as parameter.

Step 6 - Add the new Action to a Component

Next, in order to use the newly created GXflow Actions you must add them to a Component. For simplicity purposes, add them to an existing Component.

To do so, open the "Components" component by selecting it—it is located under the Backend node:

GXFlowCustomComponentsAndTree

Select the "Inbox" component and press the GXFlowActionsButton button; a dialog will be displayed where you can select the actions you want to add or remove from the component.

GXFlowCustomAddNewActionParm

Add the "ActionReceiveParms" action by selecting it from the "Actions" grid and then using the GXFlowLeftGreenArrowButton. Press OK.

Note: when using GeneXus Access Manager, a permission will be created once the action is added to a component. The permission will be created with name "{COMPONENT_ID}_{ACTION_ID}"; in this case it will be: "INBOX_ActionReceiveParms".

Step 7 - Done!

Lastly, test your action. To do so, log in with a user that has permissions to use the "Desktop" menu— for example WFADMINISTRATOR.

Next, open the GXflow Inbox, select a Process Instance and click on "More Actions". Then click on "ActionReceiveParms".

GXFlowCustomSeeNewActionParm

The following will be displayed:

GXFlowCustomExecuteNewActionParm1

Where "8" is the ID of the selected Process Instance.

If two Process Instances are selected, the following will be displayed:

GXFlowCustomExecuteNewActionParm2

See Also