Moving an object to the specified workflow state: PATCH¶
** PATCH method* * is used to force the object to move to the specified states of business processes. The request follows the path <URL сервера>/rest/<service name>/<class name>/<object id>
. The class name is specified with a namespace.
The request body passes an array of target states of workflows, which are specified as strings in the format <business process name>.<state>
. The name of the business process is indicated with the namespace. An object sequentially moves to each of the states.
Query example:
PATCH
https://localhost:8888/rest/workflows/workflowBase@develop-and-test/1
body: [
'simpleWorkflow@develop-and-test.canStart'
]
A list of errors that occurred during the movement or an empty list will be returned as a response.
The example of the PATCH
request to the workflows
in dnt: test/modules/rest/workflows.spec.js
/checking workflows service/# move the object to certain state in a workflow: PATCH