@5minds/node-red-contrib-processcube 0.3.3 → 0.3.5-feature-1092e6-lxhvslzu
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Dockerfile +8 -5
- package/docker-compose.yml +6 -6
- package/{.node-red/data/flows.json → nodered/.node-red-contrib-processcube-flows.json.backup} +128 -0
- package/nodered/node-red-contrib-processcube-flows.json +1007 -0
- package/nodered/package.json +16 -0
- package/nodered/sample_fields.json +159 -0
- package/package.json +5 -2
- package/processes/SampleUserTask.bpmn +76 -0
- package/usertask-input.html +31 -0
- package/usertask-input.js +64 -0
- package/usertask-output.html +31 -0
- package/usertask-output.js +45 -0
- package/.node-red/data/.config.nodes.json +0 -563
- package/.node-red/data/.config.nodes.json.backup +0 -563
- package/.node-red/data/.config.runtime.json +0 -4
- package/.node-red/data/.config.runtime.json.backup +0 -3
- package/.node-red/data/.config.users.json +0 -22
- package/.node-red/data/.config.users.json.backup +0 -22
- package/.node-red/data/package-lock.json +0 -19
- package/.node-red/data/package.json +0 -6
- package/.node-red/data/settings.js +0 -560
@@ -0,0 +1,16 @@
|
|
1
|
+
{
|
2
|
+
"name": "node-red-contrib-processcube-sample",
|
3
|
+
"version": "1.0.0",
|
4
|
+
"description": "A sample for the processcube node-red contrib package",
|
5
|
+
"scripts": {
|
6
|
+
"start": "./node_modules/.bin/node-red node-red-contrib-processcube-flows.json"
|
7
|
+
},
|
8
|
+
"dependencies": {
|
9
|
+
"@5minds/node-red-contrib-processcube": "file:..",
|
10
|
+
"@5minds/node-red-dashboard-2-processcube-dynamic-form": "file:../../../../moellenbeck/reps/node-red-dashboard-2-ui-example",
|
11
|
+
"@flowfuse/node-red-dashboard": "^1.11.1",
|
12
|
+
"node-red": "^3.1.10",
|
13
|
+
"node-red-debugger": "^1.1.1",
|
14
|
+
"openapi-red": "^1.2.5"
|
15
|
+
}
|
16
|
+
}
|
@@ -0,0 +1,159 @@
|
|
1
|
+
{
|
2
|
+
"formFields": [
|
3
|
+
{
|
4
|
+
"id": "text_id",
|
5
|
+
"type": "text",
|
6
|
+
"required": false,
|
7
|
+
"label": "Text Label",
|
8
|
+
"value": "",
|
9
|
+
"title": "Some helpful text"
|
10
|
+
},
|
11
|
+
{
|
12
|
+
"id": "number_id",
|
13
|
+
"type": "number",
|
14
|
+
"required": true,
|
15
|
+
"label": "Number Label",
|
16
|
+
"title": "Some helpful text"
|
17
|
+
},
|
18
|
+
{
|
19
|
+
"id": "date_id",
|
20
|
+
"type": "date",
|
21
|
+
"required": true,
|
22
|
+
"label": "Date Label",
|
23
|
+
"title": "Some helpful text"
|
24
|
+
},
|
25
|
+
{
|
26
|
+
"id": "select_id",
|
27
|
+
"type": "select",
|
28
|
+
"required": true,
|
29
|
+
"label": "Select Label",
|
30
|
+
"options": [
|
31
|
+
{
|
32
|
+
"id": "value_01",
|
33
|
+
"name": "Value 01"
|
34
|
+
},
|
35
|
+
{
|
36
|
+
"id": "value_02",
|
37
|
+
"name": "Value 02"
|
38
|
+
}
|
39
|
+
],
|
40
|
+
"title": "Choose an option"
|
41
|
+
},
|
42
|
+
{
|
43
|
+
"id": "boolean_id",
|
44
|
+
"type": "checkbox",
|
45
|
+
"required": false,
|
46
|
+
"label": "Boolean Label",
|
47
|
+
"title": "Check for Yes"
|
48
|
+
},
|
49
|
+
{
|
50
|
+
"id": "_flowNodeInstanceId",
|
51
|
+
"type": "hidden",
|
52
|
+
"value": "549abda6-911c-4b10-b8e3-f4d6383674b2"
|
53
|
+
}
|
54
|
+
],
|
55
|
+
"userTask": {
|
56
|
+
"flowNodeInstanceId": "549abda6-911c-4b10-b8e3-f4d6383674b2",
|
57
|
+
"flowNodeId": "Activity_0ljiko7",
|
58
|
+
"flowNodeName": "Hello world",
|
59
|
+
"flowNodeLane": "Lane",
|
60
|
+
"flowNodeType": "bpmn:UserTask",
|
61
|
+
"previousFlowNodeInstanceId": "a678b21e-db08-48e8-b228-ffc48618022b",
|
62
|
+
"parentProcessInstanceId": null,
|
63
|
+
"processDefinitionId": "SampleUserTask_Definition",
|
64
|
+
"processModelId": "SampleUserTask_Process",
|
65
|
+
"processInstanceId": "251bfdd1-16fb-4f2b-98b3-7c28a49eec4d",
|
66
|
+
"correlationId": "3c6dadd7-a0fe-43c0-a8aa-9b1b87c149f5",
|
67
|
+
"state": "suspended",
|
68
|
+
"tokens": [],
|
69
|
+
"startToken": {},
|
70
|
+
"endToken": {},
|
71
|
+
"ownerId": "dummy_token",
|
72
|
+
"startedAt": "2024-06-09T20:47:27.494Z",
|
73
|
+
"assignedUserIds": null,
|
74
|
+
"actualOwnerId": null,
|
75
|
+
"finishedByUserId": null,
|
76
|
+
"userTaskConfig": {
|
77
|
+
"formFields": [
|
78
|
+
{
|
79
|
+
"id": "text_id",
|
80
|
+
"label": "Text Label",
|
81
|
+
"type": "string"
|
82
|
+
},
|
83
|
+
{
|
84
|
+
"id": "number_id",
|
85
|
+
"label": "Number Label",
|
86
|
+
"type": "long",
|
87
|
+
"defaultValue": "undefined",
|
88
|
+
"customForm": "{\"hint\":\"Sample\"}"
|
89
|
+
},
|
90
|
+
{
|
91
|
+
"id": "date_id",
|
92
|
+
"label": "Date Label",
|
93
|
+
"type": "date"
|
94
|
+
},
|
95
|
+
{
|
96
|
+
"id": "select_id",
|
97
|
+
"label": "Select Label",
|
98
|
+
"type": "enum",
|
99
|
+
"enumValues": [
|
100
|
+
{
|
101
|
+
"id": "value_01",
|
102
|
+
"name": "Value 01"
|
103
|
+
},
|
104
|
+
{
|
105
|
+
"id": "value_02",
|
106
|
+
"name": "Value 02"
|
107
|
+
}
|
108
|
+
]
|
109
|
+
},
|
110
|
+
{
|
111
|
+
"id": "boolean_id",
|
112
|
+
"label": "Boolean Label",
|
113
|
+
"type": "boolean"
|
114
|
+
}
|
115
|
+
]
|
116
|
+
},
|
117
|
+
"userTaskConfigModel": {
|
118
|
+
"formFields": [
|
119
|
+
{
|
120
|
+
"id": "text_id",
|
121
|
+
"label": "Text Label",
|
122
|
+
"type": "string"
|
123
|
+
},
|
124
|
+
{
|
125
|
+
"id": "number_id",
|
126
|
+
"label": "Number Label",
|
127
|
+
"type": "long",
|
128
|
+
"defaultValue": "${token.current.sample}",
|
129
|
+
"customForm": "{\"hint\":\"Sample\"}"
|
130
|
+
},
|
131
|
+
{
|
132
|
+
"id": "date_id",
|
133
|
+
"label": "Date Label",
|
134
|
+
"type": "date"
|
135
|
+
},
|
136
|
+
{
|
137
|
+
"id": "select_id",
|
138
|
+
"label": "Select Label",
|
139
|
+
"type": "enum",
|
140
|
+
"enumValues": [
|
141
|
+
{
|
142
|
+
"id": "value_01",
|
143
|
+
"name": "Value 01"
|
144
|
+
},
|
145
|
+
{
|
146
|
+
"id": "value_02",
|
147
|
+
"name": "Value 02"
|
148
|
+
}
|
149
|
+
]
|
150
|
+
},
|
151
|
+
{
|
152
|
+
"id": "boolean_id",
|
153
|
+
"label": "Boolean Label",
|
154
|
+
"type": "boolean"
|
155
|
+
}
|
156
|
+
]
|
157
|
+
}
|
158
|
+
}
|
159
|
+
}
|
package/package.json
CHANGED
@@ -1,9 +1,10 @@
|
|
1
1
|
{
|
2
2
|
"name": "@5minds/node-red-contrib-processcube",
|
3
|
-
"version": "0.3.
|
3
|
+
"version": "0.3.5-feature-1092e6-lxhvslzu",
|
4
4
|
"license": "MIT",
|
5
5
|
"description": "Node-RED nodes for ProcessCube",
|
6
|
-
"authors": [
|
6
|
+
"authors": [
|
7
|
+
{
|
7
8
|
"name": "Martin Moellenbeck",
|
8
9
|
"email": "Martin.Moellenbeck@5Minds.de"
|
9
10
|
},
|
@@ -31,6 +32,8 @@
|
|
31
32
|
"externaltaskOutput": "externaltask-output.js",
|
32
33
|
"externaltaskError": "externaltask-error.js",
|
33
34
|
"processStart": "process-start.js",
|
35
|
+
"UserTaskInput": "usertask-input.js",
|
36
|
+
"UserTaskOutput": "usertask-output.js",
|
34
37
|
"processcubeEngineConfig": "processcube-engine-config.js"
|
35
38
|
}
|
36
39
|
},
|
@@ -0,0 +1,76 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="SampleUserTask_Definition" targetNamespace="http://bpmn.io/schema/bpmn" exporter="5Minds Studio" exporterVersion="1">
|
3
|
+
<bpmn:collaboration id="Collaboration_1cidyxu" name="">
|
4
|
+
<bpmn:participant id="Participant_0px403d" name="SampleUserTask" processRef="SampleUserTask_Process" />
|
5
|
+
</bpmn:collaboration>
|
6
|
+
<bpmn:process id="SampleUserTask_Process" name="SampleUserTask" isExecutable="true">
|
7
|
+
<bpmn:laneSet>
|
8
|
+
<bpmn:lane id="Lane_1xzf0d3" name="Lane">
|
9
|
+
<bpmn:flowNodeRef>StartEvent_1</bpmn:flowNodeRef>
|
10
|
+
<bpmn:flowNodeRef>Event_1eeiwx4</bpmn:flowNodeRef>
|
11
|
+
<bpmn:flowNodeRef>Activity_0ljiko7</bpmn:flowNodeRef>
|
12
|
+
</bpmn:lane>
|
13
|
+
</bpmn:laneSet>
|
14
|
+
<bpmn:startEvent id="StartEvent_1" name="Start">
|
15
|
+
<bpmn:extensionElements>
|
16
|
+
<camunda:properties>
|
17
|
+
<camunda:property name="studio.defaultCustomStartToken" value="{ "sample": "hello" }" />
|
18
|
+
</camunda:properties>
|
19
|
+
</bpmn:extensionElements>
|
20
|
+
<bpmn:outgoing>Flow_1h0giih</bpmn:outgoing>
|
21
|
+
</bpmn:startEvent>
|
22
|
+
<bpmn:sequenceFlow id="Flow_1h0giih" sourceRef="StartEvent_1" targetRef="Activity_0ljiko7" />
|
23
|
+
<bpmn:endEvent id="Event_1eeiwx4">
|
24
|
+
<bpmn:incoming>Flow_1laqnja</bpmn:incoming>
|
25
|
+
</bpmn:endEvent>
|
26
|
+
<bpmn:sequenceFlow id="Flow_1laqnja" sourceRef="Activity_0ljiko7" targetRef="Event_1eeiwx4" />
|
27
|
+
<bpmn:userTask id="Activity_0ljiko7" name="Hello world">
|
28
|
+
<bpmn:extensionElements>
|
29
|
+
<camunda:formData>
|
30
|
+
<camunda:formField id="text_id" label="Text Label" type="string" />
|
31
|
+
<camunda:formField id="number_id" label="Number Label" type="long" defaultValue="${token.current.sample}" customForm="{"hint":"Sample"}" />
|
32
|
+
<camunda:formField id="date_id" label="Date Label" type="date" />
|
33
|
+
<camunda:formField id="select_id" label="Select Label" type="enum">
|
34
|
+
<camunda:value id="value_01" name="Value 01" />
|
35
|
+
<camunda:value id="value_02" name="Value 02" />
|
36
|
+
</camunda:formField>
|
37
|
+
<camunda:formField id="boolean_id" label="Boolean Label" type="boolean" />
|
38
|
+
<camunda:formField id="customer_01" label="Custom_01" type="v-text-field" />
|
39
|
+
</camunda:formData>
|
40
|
+
</bpmn:extensionElements>
|
41
|
+
<bpmn:incoming>Flow_1h0giih</bpmn:incoming>
|
42
|
+
<bpmn:outgoing>Flow_1laqnja</bpmn:outgoing>
|
43
|
+
</bpmn:userTask>
|
44
|
+
</bpmn:process>
|
45
|
+
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
|
46
|
+
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Collaboration_1cidyxu">
|
47
|
+
<bpmndi:BPMNShape id="Participant_0px403d_di" bpmnElement="Participant_0px403d" isHorizontal="true">
|
48
|
+
<dc:Bounds x="5" y="4" width="435" height="346" />
|
49
|
+
</bpmndi:BPMNShape>
|
50
|
+
<bpmndi:BPMNShape id="Lane_1xzf0d3_di" bpmnElement="Lane_1xzf0d3" isHorizontal="true">
|
51
|
+
<dc:Bounds x="35" y="4" width="405" height="346" />
|
52
|
+
</bpmndi:BPMNShape>
|
53
|
+
<bpmndi:BPMNShape id="StartEvent_1_di" bpmnElement="StartEvent_1">
|
54
|
+
<dc:Bounds x="92" y="152" width="36" height="36" />
|
55
|
+
<bpmndi:BPMNLabel>
|
56
|
+
<dc:Bounds x="98" y="195" width="24" height="14" />
|
57
|
+
</bpmndi:BPMNLabel>
|
58
|
+
</bpmndi:BPMNShape>
|
59
|
+
<bpmndi:BPMNShape id="Event_1eeiwx4_di" bpmnElement="Event_1eeiwx4">
|
60
|
+
<dc:Bounds x="332" y="152" width="36" height="36" />
|
61
|
+
</bpmndi:BPMNShape>
|
62
|
+
<bpmndi:BPMNShape id="Activity_1uodwbi_di" bpmnElement="Activity_0ljiko7">
|
63
|
+
<dc:Bounds x="180" y="130" width="100" height="80" />
|
64
|
+
<bpmndi:BPMNLabel />
|
65
|
+
</bpmndi:BPMNShape>
|
66
|
+
<bpmndi:BPMNEdge id="Flow_1h0giih_di" bpmnElement="Flow_1h0giih">
|
67
|
+
<di:waypoint x="128" y="170" />
|
68
|
+
<di:waypoint x="180" y="170" />
|
69
|
+
</bpmndi:BPMNEdge>
|
70
|
+
<bpmndi:BPMNEdge id="Flow_1laqnja_di" bpmnElement="Flow_1laqnja">
|
71
|
+
<di:waypoint x="280" y="170" />
|
72
|
+
<di:waypoint x="332" y="170" />
|
73
|
+
</bpmndi:BPMNEdge>
|
74
|
+
</bpmndi:BPMNPlane>
|
75
|
+
</bpmndi:BPMNDiagram>
|
76
|
+
</bpmn:definitions>
|
@@ -0,0 +1,31 @@
|
|
1
|
+
<script type="text/javascript">
|
2
|
+
RED.nodes.registerType('usertask-input',{
|
3
|
+
category: 'ProcessCube',
|
4
|
+
color: '#00aed7',
|
5
|
+
defaults: {
|
6
|
+
name: {value: ""},
|
7
|
+
engine: {value: "", type: "processcube-engine-config"}
|
8
|
+
},
|
9
|
+
inputs: 0,
|
10
|
+
outputs: 1,
|
11
|
+
icon: "font-awesome/fa-envelope-open",
|
12
|
+
label: function() {
|
13
|
+
return this.name || "usertask-input";
|
14
|
+
}
|
15
|
+
});
|
16
|
+
</script>
|
17
|
+
|
18
|
+
<script type="text/html" data-template-name="usertask-input">
|
19
|
+
<div class="form-row">
|
20
|
+
<label for="node-input-name"><i class="fa fa-tag"></i> Name</label>
|
21
|
+
<input type="text" id="node-input-name" placeholder="Name">
|
22
|
+
</div>
|
23
|
+
<div class="form-row">
|
24
|
+
<label for="node-input-engine"><i class="fa fa-tag"></i> Engine-URL</label>
|
25
|
+
<input type="text" id="node-input-engine" placeholder="http://engine:8000">
|
26
|
+
</div>
|
27
|
+
</script>
|
28
|
+
|
29
|
+
<script type="text/html" data-help-name="usertask-input">
|
30
|
+
<p>A node which subscribes to an User Task of https://processcube.io</p>
|
31
|
+
</script>
|
@@ -0,0 +1,64 @@
|
|
1
|
+
const process = require('process');
|
2
|
+
const EventEmitter = require('node:events');
|
3
|
+
|
4
|
+
const engine_client = require('@5minds/processcube_engine_client');
|
5
|
+
|
6
|
+
function showStatus(node, msgCounter) {
|
7
|
+
if (msgCounter >= 1) {
|
8
|
+
node.status({fill: "blue", shape: "dot", text: `handling tasks ${msgCounter}`});
|
9
|
+
} else {
|
10
|
+
node.status({fill: "blue", shape: "ring", text: `subcribed ${msgCounter}`});
|
11
|
+
}
|
12
|
+
}
|
13
|
+
|
14
|
+
module.exports = function(RED) {
|
15
|
+
function UserTaskInput(config) {
|
16
|
+
RED.nodes.createNode(this,config);
|
17
|
+
var node = this;
|
18
|
+
var msgCounter = 0;
|
19
|
+
var flowContext = node.context().flow;
|
20
|
+
var nodeContext = node.context();
|
21
|
+
|
22
|
+
this.engine = this.server = RED.nodes.getNode(config.engine);
|
23
|
+
|
24
|
+
const engineUrl = this.engine?.url || process.env.ENGINE_URL || 'http://engine:8000';
|
25
|
+
|
26
|
+
var client = nodeContext.get('client');
|
27
|
+
|
28
|
+
if (!client) {
|
29
|
+
nodeContext.set('client', new engine_client.EngineClient(engineUrl));
|
30
|
+
client = nodeContext.get('client');
|
31
|
+
}
|
32
|
+
|
33
|
+
var eventEmitter = flowContext.get('emitter');
|
34
|
+
|
35
|
+
if (!eventEmitter) {
|
36
|
+
flowContext.set('emitter', new EventEmitter());
|
37
|
+
eventEmitter = flowContext.get('emitter');
|
38
|
+
}
|
39
|
+
|
40
|
+
client.userTasks.onUserTaskWaiting((userTaskWaitingNotification) => {
|
41
|
+
console.log(`UserTask with id ${userTaskWaitingNotification.flowNodeInstanceId} is waiting.`);
|
42
|
+
|
43
|
+
// Abschließend mit - client.userTasks.finishUserTask(waitingUserTask?.flowNodeInstanceId, sampleResult)
|
44
|
+
|
45
|
+
// flowNodeInstanceId
|
46
|
+
// processModelName
|
47
|
+
// flowNodeId
|
48
|
+
client.userTasks.query({
|
49
|
+
flowNodeInstanceId: userTaskWaitingNotification.flowNodeInstanceId,
|
50
|
+
processModelId: userTaskWaitingNotification.processModelId,
|
51
|
+
flowNodeId: userTaskWaitingNotification.flowNodeId,
|
52
|
+
}).then((matchingFlowNodes) => {
|
53
|
+
if (matchingFlowNodes && matchingFlowNodes.userTasks && matchingFlowNodes.userTasks.length == 1) {
|
54
|
+
userTask = matchingFlowNodes.userTasks[0];
|
55
|
+
|
56
|
+
node.send({ payload: {userTask: userTask }, "_flowNodeInstanceId": userTaskWaitingNotification.flowNodeInstanceId});
|
57
|
+
} else {
|
58
|
+
node.send({ payload: matchingFlowNodes.userTasks });
|
59
|
+
}
|
60
|
+
});
|
61
|
+
});
|
62
|
+
}
|
63
|
+
RED.nodes.registerType("usertask-input", UserTaskInput);
|
64
|
+
}
|
@@ -0,0 +1,31 @@
|
|
1
|
+
<script type="text/javascript">
|
2
|
+
RED.nodes.registerType('usertask-output',{
|
3
|
+
category: 'ProcessCube',
|
4
|
+
color: '#00aed7',
|
5
|
+
defaults: {
|
6
|
+
name: {value: ""},
|
7
|
+
engine: {value: "", type: "processcube-engine-config"}
|
8
|
+
},
|
9
|
+
inputs: 1,
|
10
|
+
outputs: 0,
|
11
|
+
icon: "font-awesome/fa-envelope",
|
12
|
+
label: function() {
|
13
|
+
return this.name || "usertask-output";
|
14
|
+
}
|
15
|
+
});
|
16
|
+
</script>
|
17
|
+
|
18
|
+
<script type="text/html" data-template-name="usertask-output">
|
19
|
+
<div class="form-row">
|
20
|
+
<label for="node-input-name"><i class="fa fa-tag"></i> Name</label>
|
21
|
+
<input type="text" id="node-input-name" placeholder="Name">
|
22
|
+
</div>
|
23
|
+
<div class="form-row">
|
24
|
+
<label for="node-input-engine"><i class="fa fa-tag"></i> Engine-URL</label>
|
25
|
+
<input type="text" id="node-input-engine" placeholder="http://engine:8000">
|
26
|
+
</div>
|
27
|
+
</script>
|
28
|
+
|
29
|
+
<script type="text/html" data-help-name="usertask-output">
|
30
|
+
<p>A node which send the result to an User Task of https://processcube.io</p>
|
31
|
+
</script>
|
@@ -0,0 +1,45 @@
|
|
1
|
+
const process = require('process');
|
2
|
+
const EventEmitter = require('node:events');
|
3
|
+
|
4
|
+
const engine_client = require('@5minds/processcube_engine_client');
|
5
|
+
|
6
|
+
module.exports = function(RED) {
|
7
|
+
function UserTaskOutput(config) {
|
8
|
+
|
9
|
+
RED.nodes.createNode(this, config);
|
10
|
+
|
11
|
+
var node = this;
|
12
|
+
var flowContext = node.context().flow;
|
13
|
+
var nodeContext = node.context();
|
14
|
+
|
15
|
+
this.engine = this.server = RED.nodes.getNode(config.engine);
|
16
|
+
|
17
|
+
const engineUrl = this.engine?.url || process.env.ENGINE_URL || 'http://engine:8000';
|
18
|
+
|
19
|
+
var client = nodeContext.get('client');
|
20
|
+
|
21
|
+
if (!client) {
|
22
|
+
nodeContext.set('client', new engine_client.EngineClient(engineUrl));
|
23
|
+
client = nodeContext.get('client');
|
24
|
+
}
|
25
|
+
|
26
|
+
var eventEmitter = flowContext.get('emitter');
|
27
|
+
|
28
|
+
if (!eventEmitter) {
|
29
|
+
flowContext.set('emitter', new EventEmitter());
|
30
|
+
eventEmitter = flowContext.get('emitter');
|
31
|
+
}
|
32
|
+
|
33
|
+
node.on('input', function(msg) {
|
34
|
+
console.log(`Try to finsih UserTask with id ${msg._flowNodeInstanceId}.`);
|
35
|
+
|
36
|
+
const flowNodeInstanceId = msg._flowNodeInstanceId;
|
37
|
+
|
38
|
+
client.userTasks.finishUserTask(flowNodeInstanceId, msg.payload).then(() => {
|
39
|
+
console.log(`UserTask with id ${flowNodeInstanceId} finished.`);
|
40
|
+
});
|
41
|
+
});
|
42
|
+
}
|
43
|
+
|
44
|
+
RED.nodes.registerType("usertask-output", UserTaskOutput);
|
45
|
+
}
|