Activity - Submit Work
Overview
- Lets you automatically submit work items to the next task in another workflow
- Which work items gets submitted is based on which ones match a set of criteria
Video explanation on how to set up this activity
Steps to set up this activity
- Have or create the workflow that you want to trigger this activity and another workflow where you want work items to be automatically submitted in
- We will call these two workflows the source and target (automatic submit happens to this one) workflows
- On the source workflow create a relationship
- Set these properties
- “name”: Can be anything
- “flowName”: The “name” property from the target workflow
- “sourceName”: Can be anything
- “targetName”: Can be anything
- Create a submit work activity on the source workflow
- Set these properties
- “targetRelationshipName”: The name of the target workflow but remove all the spaces
- “relatedWork - flowName”: The “name” property from the target workflow
- “relatedWork - workFilters - targetPath”: the “dataPath” property from the component in the target workflow that, if on the target work item the value of this matches the source work item’s component’s value, it will automatically submit the target work item
- “relatedWork - workFilters - valuePath”: the “dataPath” property from the component in the source workflow
- “relatedWork - stepName”: The last part of the step’s “name” property”
- e.g. if the step’s “name” property is
- "name": "ecosystem/workflow/entity/generated-1af2a966-8383-467c-abe7-3be40544217b/untitledstep__generated-27fb4531-de5f-4bdf-8d1d-921f5f3c418b"
- Then the value to use in stepName would be
- /untitledstep__generated-27fb4531-de5f-4bdf-8d1d-921f5f3c418b
- Done!
- Now when you submit the task in the source work item it will conditionally submit the target work items too
Advanced Editor properties and what they do
Properties shared between activities
Property | What does the property do (in plain english) | Possible values | How to find these values (in plain english) |
displayName | label of the activity | any string | |
comments | additional comments on what the activity do | any string | |
executeWhen | decides on when to execute the activity
| BeforeExecute
AfterExecute
OnExecute
Manual | |
runOnSystemEvents | specify an action event (that starts with $) that this activity will be executed | [”$actionEvent1”, “$actionEvent1”] | |
expression | data path expression if it satisfies then it will execute this activity | e.g. "'{$.asset.id}' = “123" |
Properties unique to this activity
- All of these unique properties sit within a “properties” object e.g.
{
"property one shared between components": "",
"properties": {
"entityType": "",
"etc": "",
}
}
Property | What does the property do (in plain english) | Possible values | How to find these values (in plain english) |
targetRelationshipName | Tells the activity which workflow to look at | "SourceWorkflow" | The name of the target workflow but remove all the spaces |
relatedWork - workFilters - targetPath | If the value in the targetPath and the valuePath match then the target work item will automatically submit when the source work item is submitted | “$.taskOneInTarget.sectionInTaskOne.textComponent” | the “dataPath” property from the component in the target workflow |
relatedWork - workFilters - valuePath | If the value in the targetPath and the valuePath match then the target work item will automatically submit when the source work item is submitted | “$.taskOneInSource.sectionInTaskOne.textComponent” | The “name” property from the target workflow |
relatedWork - flowName | The name of the workflow this activity applies t o | "ecosystem/workflow/entity/generated-4b8c00cc-77eb-4c31-99a7-d81773faa2e4" | Found on the “name” property in the target workflow |
realtedWork - stepName | The step that the activity should look in, in the source workflow, to apply the work filters | "/untitledstep__generated-6c63c67f-4d86-4901-9227-868d8483f4d8" | Set stepName to be the last part of the step “name” property.
e.g. if the step name property is
* "name": "ecosystem/workflow/entity/generated-1af2a966-8383-467c-abe7-3be40544217b/untitledstep__generated-27fb4531-de5f-4bdf-8d1d-921f5f3c418b"
* Then the value to use in stepName would be
* /untitledstep__generated-27fb4531-de5f-4bdf-8d1d-921f5f3c418b |
OTHER OPTIONAL PROPERTIES | |||
relatedWork - addRelationship | Indicates whether a new relationship should be added as part of the related work process. | true or false | Set to true to add a new relationship between the current item and related work. |
eventName | The name of the event this activity is tied to. | "event name" | The specific event in the workflow that will trigger this activity. |
stepName | The name of the step this activity is associated with. | "Test Step" | Defines the step in the workflow to which this activity is attached. |
closeOutPrevious | Specifies whether the previous step or task should be closed when this activity starts. | true or false | Set to true to automatically close the previous step or activity when this one starts. |
previousStepName | The previous step in the workflow or process before the current step. | "previous step name" | Specifies the step that occurred before this one, useful for tracking the workflow progression. |
targetName | The name of the target entity in the workflow. | "target" | The entity or item that is the target of the current operation. |
sourceName | The name of the source entity in the workflow. | "source" | The entity or item that is the source of the current operation. |
skipLookupAndCreateWorkItem | If set to true, the system will skip the lookup of existing work items and directly create a new one. | true or false | Determines whether the lookup process should be bypassed when creating new work items. |
createWorkIfNotFound | If set to true, the system will create a new work item if no matching items are found. | true or false | Ensures that a work item is created if no existing ones are found. |
name | The name of this configuration or operation. | "test name" | The label or identifier for the current configuration or operation. |
removeExisting | If set to true , this configuration will remove any existing related work items that match the criteria. | true or false | Controls whether existing work items should be removed if they match the filters or conditions. |
Advanced Editor example of this activity fully set up
{
"continueOnError": false,
"executeWhen": "AfterExecute",
"runOnSystemEvents": [],
"properties": {
"targetDataPath": null,
"initiator": null,
"stepName": "Test Step",
"removePermissionAndSkipSendingInvite": false,
"targetRelationshipName": "$.data",
"relatedWork": {
"flowName": "flowName",
"workFilters": [
{
"targetPath": "target",
"valuePath": "valuePath"
}
],
"stepName": "step",
"previousStepName": "previous step name",
"targetName": "target",
"sourceName": "source",
"skipLookupAndCreateWorkItem": true,
"createWorkIfNotFound": true,
"name": "test name",
"removeExisting": true,
"addRelationship": true,
"isOneWayRelationship": false
},
"closeOutPrevious": false,
"eventName": "event name"
}
}