Trigger custom scripts on workflow states

As a library administrator, you can configure custom actions to trigger a specific custom script when a document enters or leaves a workflows state.

1. Open the library administration interface and select Workflow.

2. Press a workflow name to open the workflow configuration.

3. Select a workflow state and press Customize to configure a new custom action.

4. Press Add new action

Note: You can configure multiple custom actions in one workflow state.

5. Fill in the settings of the newly created custom action:

  • Action name: This value can be retrieved in your custom script by calling the method _getDisplayName
  • Event: Choose when to trigger the custom script:
    • run when document enters this state before inbound transition is completed
    • run when document enters this state after inbound transition is completed
    • run when document leaves this state before outbound transition is completed
    • run when document leaves this state after outbound transition is completed
  • Script name: Select the custom script you want to trigger from the drop-down list. 

Note: You can only select Workflow Transition Action custom scripts. Learn more: Create custom scripts.

6. Check the Parameters table.

Tip: As a custom script can be triggered on several workflow states, the custom script code can call specific parameters from the Parameters table. When configuring a custom script action, you can modify the second column Values of the Parameters table to adapt the custom script for the action you are configuring. 

image_01.png

Was this article helpful? 0 out of 0 found this helpful
If you didn’t find what you were looking for, don’t hesitate to leave a comment!
Have more questions? Submit a request

Comments

0 comments

Please sign in to leave a comment.