@5minds/node-red-contrib-processcube 1.8.0-feature-127d19-m6wfhcy6 → 1.8.0-feature-6eed29-m6wgknb1
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.
@@ -3244,9 +3244,9 @@
|
|
3244
3244
|
"id": "d75f8915b26e8f52",
|
3245
3245
|
"type": "externaltask-input-inject",
|
3246
3246
|
"z": "17865ef049c3b83d",
|
3247
|
-
"name": "",
|
3247
|
+
"name": "a",
|
3248
3248
|
"externaltask": "476cbb99633a9539",
|
3249
|
-
"x":
|
3249
|
+
"x": 370,
|
3250
3250
|
"y": 320,
|
3251
3251
|
"wires": [
|
3252
3252
|
[
|
@@ -3291,7 +3291,7 @@
|
|
3291
3291
|
"complete": "false",
|
3292
3292
|
"statusVal": "",
|
3293
3293
|
"statusType": "auto",
|
3294
|
-
"x":
|
3294
|
+
"x": 560,
|
3295
3295
|
"y": 320,
|
3296
3296
|
"wires": []
|
3297
3297
|
},
|
@@ -3319,7 +3319,7 @@
|
|
3319
3319
|
"z": "17865ef049c3b83d",
|
3320
3320
|
"name": "",
|
3321
3321
|
"x": 670,
|
3322
|
-
"y":
|
3322
|
+
"y": 200,
|
3323
3323
|
"wires": []
|
3324
3324
|
},
|
3325
3325
|
{
|
@@ -3339,8 +3339,28 @@
|
|
3339
3339
|
"drop": false,
|
3340
3340
|
"allowrate": false,
|
3341
3341
|
"outputs": 1,
|
3342
|
-
"x":
|
3342
|
+
"x": 400,
|
3343
3343
|
"y": 140,
|
3344
|
+
"wires": [
|
3345
|
+
[
|
3346
|
+
"59f385728d7d350d"
|
3347
|
+
]
|
3348
|
+
]
|
3349
|
+
},
|
3350
|
+
{
|
3351
|
+
"id": "59f385728d7d350d",
|
3352
|
+
"type": "function",
|
3353
|
+
"z": "17865ef049c3b83d",
|
3354
|
+
"name": "function 1",
|
3355
|
+
"func": "msg.payload.running = \"1\";\nmsg.payload.at = new Date().toISOString();\nreturn msg;",
|
3356
|
+
"outputs": 1,
|
3357
|
+
"timeout": 0,
|
3358
|
+
"noerr": 0,
|
3359
|
+
"initialize": "",
|
3360
|
+
"finalize": "",
|
3361
|
+
"libs": [],
|
3362
|
+
"x": 580,
|
3363
|
+
"y": 120,
|
3344
3364
|
"wires": [
|
3345
3365
|
[
|
3346
3366
|
"dd8e11733ed305c1"
|
@@ -0,0 +1,143 @@
|
|
1
|
+
[
|
2
|
+
{
|
3
|
+
"id": "17865ef049c3b83d",
|
4
|
+
"type": "tab",
|
5
|
+
"label": "External Task Testing",
|
6
|
+
"disabled": false,
|
7
|
+
"info": "",
|
8
|
+
"env": []
|
9
|
+
},
|
10
|
+
{
|
11
|
+
"id": "d75f8915b26e8f52",
|
12
|
+
"type": "externaltask-input-inject",
|
13
|
+
"z": "17865ef049c3b83d",
|
14
|
+
"name": "a",
|
15
|
+
"externaltask": "476cbb99633a9539",
|
16
|
+
"x": 370,
|
17
|
+
"y": 320,
|
18
|
+
"wires": [
|
19
|
+
[
|
20
|
+
"1afda17294a69742"
|
21
|
+
]
|
22
|
+
]
|
23
|
+
},
|
24
|
+
{
|
25
|
+
"id": "3c50b6d63b7b81d8",
|
26
|
+
"type": "inject",
|
27
|
+
"z": "17865ef049c3b83d",
|
28
|
+
"name": "",
|
29
|
+
"props": [
|
30
|
+
{
|
31
|
+
"p": "payload"
|
32
|
+
}
|
33
|
+
],
|
34
|
+
"repeat": "",
|
35
|
+
"crontab": "",
|
36
|
+
"once": false,
|
37
|
+
"onceDelay": 0.1,
|
38
|
+
"topic": "",
|
39
|
+
"payload": "{\"hello\":\"world\"}",
|
40
|
+
"payloadType": "json",
|
41
|
+
"x": 160,
|
42
|
+
"y": 320,
|
43
|
+
"wires": [
|
44
|
+
[
|
45
|
+
"d75f8915b26e8f52"
|
46
|
+
]
|
47
|
+
]
|
48
|
+
},
|
49
|
+
{
|
50
|
+
"id": "1afda17294a69742",
|
51
|
+
"type": "debug",
|
52
|
+
"z": "17865ef049c3b83d",
|
53
|
+
"name": "debug 4",
|
54
|
+
"active": true,
|
55
|
+
"tosidebar": true,
|
56
|
+
"console": false,
|
57
|
+
"tostatus": false,
|
58
|
+
"complete": "false",
|
59
|
+
"statusVal": "",
|
60
|
+
"statusType": "auto",
|
61
|
+
"x": 560,
|
62
|
+
"y": 320,
|
63
|
+
"wires": []
|
64
|
+
},
|
65
|
+
{
|
66
|
+
"id": "476cbb99633a9539",
|
67
|
+
"type": "externaltask-input",
|
68
|
+
"z": "17865ef049c3b83d",
|
69
|
+
"name": "test inject",
|
70
|
+
"engine": "b78932d162d8d468",
|
71
|
+
"topic": "test",
|
72
|
+
"topicType": "str",
|
73
|
+
"workerConfig": "{}",
|
74
|
+
"workerConfigType": "json",
|
75
|
+
"x": 220,
|
76
|
+
"y": 140,
|
77
|
+
"wires": [
|
78
|
+
[
|
79
|
+
"36c31ae7ce4b2536"
|
80
|
+
]
|
81
|
+
]
|
82
|
+
},
|
83
|
+
{
|
84
|
+
"id": "dd8e11733ed305c1",
|
85
|
+
"type": "externaltask-output",
|
86
|
+
"z": "17865ef049c3b83d",
|
87
|
+
"name": "",
|
88
|
+
"x": 670,
|
89
|
+
"y": 200,
|
90
|
+
"wires": []
|
91
|
+
},
|
92
|
+
{
|
93
|
+
"id": "36c31ae7ce4b2536",
|
94
|
+
"type": "delay",
|
95
|
+
"z": "17865ef049c3b83d",
|
96
|
+
"name": "",
|
97
|
+
"pauseType": "delay",
|
98
|
+
"timeout": "5",
|
99
|
+
"timeoutUnits": "seconds",
|
100
|
+
"rate": "1",
|
101
|
+
"nbRateUnits": "1",
|
102
|
+
"rateUnits": "second",
|
103
|
+
"randomFirst": "1",
|
104
|
+
"randomLast": "5",
|
105
|
+
"randomUnits": "seconds",
|
106
|
+
"drop": false,
|
107
|
+
"allowrate": false,
|
108
|
+
"outputs": 1,
|
109
|
+
"x": 400,
|
110
|
+
"y": 140,
|
111
|
+
"wires": [
|
112
|
+
[
|
113
|
+
"59f385728d7d350d"
|
114
|
+
]
|
115
|
+
]
|
116
|
+
},
|
117
|
+
{
|
118
|
+
"id": "59f385728d7d350d",
|
119
|
+
"type": "function",
|
120
|
+
"z": "17865ef049c3b83d",
|
121
|
+
"name": "function 1",
|
122
|
+
"func": "msg.payload.running = \"1\";\nmsg.payload.at = new Date().toISOString();\nreturn msg;",
|
123
|
+
"outputs": 1,
|
124
|
+
"timeout": 0,
|
125
|
+
"noerr": 0,
|
126
|
+
"initialize": "",
|
127
|
+
"finalize": "",
|
128
|
+
"libs": [],
|
129
|
+
"x": 580,
|
130
|
+
"y": 120,
|
131
|
+
"wires": [
|
132
|
+
[
|
133
|
+
"dd8e11733ed305c1"
|
134
|
+
]
|
135
|
+
]
|
136
|
+
},
|
137
|
+
{
|
138
|
+
"id": "b78932d162d8d468",
|
139
|
+
"type": "processcube-engine-config",
|
140
|
+
"name": "Engine Auth 8000",
|
141
|
+
"url": "http://engine:8000"
|
142
|
+
}
|
143
|
+
]
|
@@ -4,13 +4,26 @@
|
|
4
4
|
color: '#02AFD6',
|
5
5
|
defaults: {
|
6
6
|
name: { value: '' },
|
7
|
-
externaltask: { value: ''
|
7
|
+
externaltask: { value: '' }
|
8
8
|
},
|
9
9
|
inputs: 1,
|
10
10
|
outputs: 1,
|
11
11
|
icon: 'externaltask_input.svg',
|
12
12
|
label: function () {
|
13
|
-
|
13
|
+
const nodes = RED.nodes.filterNodes({ type: 'externaltask-input' });
|
14
|
+
|
15
|
+
if (nodes && nodes.length > 0) {
|
16
|
+
let foundNode = null;
|
17
|
+
nodes.forEach((node) => {
|
18
|
+
if (node.id === this.externaltask) {
|
19
|
+
foundNode = node;
|
20
|
+
}
|
21
|
+
});
|
22
|
+
|
23
|
+
return foundNode ? `inject '${foundNode.name}'` : this.name || 'externaltask-input-inject';
|
24
|
+
} else {
|
25
|
+
return this.name || 'externaltask-input-inject';
|
26
|
+
}
|
14
27
|
},
|
15
28
|
oneditprepare: function () {
|
16
29
|
|