Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

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. So, you You can do this via SimpleOne administrative interface.

...

  1. Create a table storing settings for the newly created activity;.
  2. Create an activity type that will store parameters and bear the functionality of your newly created activity;.
  3. Create activity exit types that will specify the exit condition from this activity.

...

In fact, every activity stores its settings in a child table child for of the Workflow Activity (wf_activity) table.

...

  1. Navigate to Workflow → Activities.
  2. Enter the hamburger menu at the top left of the page.
  3. Enter the Configure menu and select the Table item.
  4. On the page opened, scroll down to the related list Related Lists area and click on the Table tab.
  5. Click New and fill in the fields. For more information about the table attributes, please refer to the Table Attributes article.
  6. Click Save or Save and Exit to apply changes.

...

FieldMandatoryDescription
TitleYThe activity title. When filling in this field, the Name field is populated automatically with a corresponding name.
NameY

The activity name. This field is populated automatically with a name corresponding to the Title field.

...

FieldValue
TitleRun Script
Namewf_activity_run_script

...


ParentNChoose the table named Workflow Activity (wf_activity).
Is ExtendableNIf an activity has this property set to true, it can be a parent for another activity.
Add Menu ItemNSelect this checkbox to create a new menu category in the Navigation menu. If the checkbox is set to true, the Menu Item tab will appear in the Related Lists area.
Menu Item tab
Menu CategoryYSpecify a menu category to which the menu item should be related.
Menu ItemNThe name of the new menu item.
NewN

Select this checkbox if you want to create a new category item. Then the following fields will appear:

FieldMandatoryDescription
New CategoryYDisplayed category title.
OrderYCategory order in the interface (categories are arranged in ascending order).
Menu ItemNThe name of the new menu item.

For more information about menu categories and category items, please refer to the Navigation article.


Creating an activity type

...

Activity type form fields

Active
FieldMandatoryDescription
NameNSpecify the activity type name (for example, "Begin").
DescriptionSpecify the activity type description.
ActiveN

Select this checkbox to activate or deactivate this activity type.

Note

If you unselect this checkbox, then you'll not be able to use this activity type when creating or modifying activities.


DescriptionNSpecify the activity type description.
ScriptNIn this field, you can specify a JavaScript scenario implementing the activity logic. You are free to use SimpleOne Server-Side API there.
ImageNSpecify the favicon that will be displayed in the workflow editor for this activity.
Activity type categoryType CategoryNSpecify a category for the activity creating.
Activity tableTableNThis is a reference field where you can specify a table for this activity type created before.
When to RunN

A condition that should be met to run the activity type. Available options:

  • On Change - it starts when the specified field in the form is changed.
  • Immediately.
Updated byYThe name of the user who has updated this record. The field is populated automatically.
Created byYThe name of the user who initiated the creation of this record. The field is populated automatically.

Create an activity type exit

...

Tip

The easier way to create activity type exits is described below:

  1. Navigate to Workflow → Activity Types.
  2. Click on the activity type name for which you need to create an exit;.
  3. In the Workflow Activity Type Exit related list, click New ;Fill and fill in the fields and click Save.
  4. Click Save or Save and Exit to apply changes.


Activity type exit form fields

Description description
FieldMandatoryDescription
NameNActivity type exit name.
Activity TypeNActivity type to which this exit is related.
Exit conditionConditionNSpecify a trigger condition that must be met to exit the activity.
DescriptionNActivity type exit description.
OrderNSpecify 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.

...