As an instance administrator, you may need to create your own workflow activity endowed with the specific logic when the default activities set does not fit your needs. You can do this via SimpleOne agent interface.
Role required: admin, wf_admin. |
To create a new activity, you need to complete several steps:
In fact, every activity stores its settings in a child table of the Workflow Activity (wf_activity) table.
To create this child table, please complete the steps below:
For more information about the table attributes, please refer to the Table Attributes article.
Activity type is an entity intended for the categorization of the newly created or updated activities. It allows defining properties and behavior for an activity.
To create an activity type, please complete the steps below:
Activity type form fields
Field | Mandatory | Description | |
---|---|---|---|
Name | N | Specify the activity type name (for example, "Send Request"). | |
Active | N | Select this checkbox to activate or deactivate this activity type.
| |
Description | N | Type a brief description of the activity type. | |
Script | N | In this field, you can specify a JavaScript scenario implementing the activity logic. You are free to use SimpleOne Server-Side API there. | |
Image | N | Attach an image that will be displayed in the workflow editor for this activity.
| |
Activity Type Category | N | Specify a category for the activity. Click the magnifier icon | |
Activity Table | N | This is a reference field where you can specify a table for this activity type created before. Click the magnifier icon | |
When to Run | N | A condition that should be met to run the activity type. Available options:
|
To create an activity type exit, please complete the steps below:
Field | Mandatory | Description |
---|---|---|
Name | N | Activity type exit name. |
Activity Type | N | Activity type to which this exit is related. Click the magnifier icon |
Exit Condition | N | Specify a JS script that will return 'true' or 'false'. The script defines the condition that must be met to exit the activity. Example: activity.result == 'complete' |
Description | N | Activity type exit description. |
Order | N | Specify the exit order on the activity block. The order is defined in ascending order, and exits are displayed on the activity block from the upside-down depending on their order. |
To configure the activity form view displayed in the Workflow Editor, perform the following steps:
Copy the value from the Name field and paste it in the URL address after the /record/ line (see the example below).
In case you need to see the activity record often, create a menu item:
See the Navigation article to learn more about menu items and categories. |
It is not recommended to modify the form layout for out-of-the-box activities. This may cause troubles adding these activities to a workflow. |