@5minds/node-red-contrib-processcube 1.7.4-feature-6f3b75-m6ksn7zb → 1.7.4-feature-a91d79-m6kzfb4g

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.
@@ -22,7 +22,7 @@
22
22
  }
23
23
  }
24
24
  },
25
- "menu-menu-item-sidebar": false,
25
+ "menu-menu-item-sidebar": true,
26
26
  "menu-menu-item-palette": true,
27
27
  "do": {
28
28
  "markNodes": true
@@ -111,14 +111,6 @@
111
111
  "info": "",
112
112
  "env": []
113
113
  },
114
- {
115
- "id": "d2d4021c0003f913",
116
- "type": "tab",
117
- "label": "TokenTest",
118
- "disabled": false,
119
- "info": "",
120
- "env": []
121
- },
122
114
  {
123
115
  "id": "4c59118134081e05",
124
116
  "type": "group",
@@ -677,12 +669,7 @@
677
669
  "id": "b78932d162d8d468",
678
670
  "type": "processcube-engine-config",
679
671
  "name": "Engine Auth 8000",
680
- "url": "http://engine:8000",
681
- "urlType": "str",
682
- "clientId": "nodered",
683
- "clientIdType": "str",
684
- "clientSecret": "nodered",
685
- "clientSecretType": "str"
672
+ "url": "http://engine:8000"
686
673
  },
687
674
  {
688
675
  "id": "2991a5e6df2b87d2",
@@ -3112,122 +3099,5 @@
3112
3099
  "af52431420fa7e15"
3113
3100
  ]
3114
3101
  ]
3115
- },
3116
- {
3117
- "id": "6498965c90a69b52",
3118
- "type": "externaltask-input",
3119
- "z": "d2d4021c0003f913",
3120
- "name": "",
3121
- "engine": "b78932d162d8d468",
3122
- "topic": "TriggerPCNode",
3123
- "topicType": "str",
3124
- "workerConfig": "{}",
3125
- "workerConfigType": "json",
3126
- "x": 410,
3127
- "y": 200,
3128
- "wires": [
3129
- [
3130
- "04d89e4c96b9b2a6",
3131
- "718a8f661fef6590"
3132
- ]
3133
- ]
3134
- },
3135
- {
3136
- "id": "718a8f661fef6590",
3137
- "type": "externaltask-output",
3138
- "z": "d2d4021c0003f913",
3139
- "name": "",
3140
- "x": 910,
3141
- "y": 200,
3142
- "wires": []
3143
- },
3144
- {
3145
- "id": "04d89e4c96b9b2a6",
3146
- "type": "debug",
3147
- "z": "d2d4021c0003f913",
3148
- "name": "debug 3",
3149
- "active": true,
3150
- "tosidebar": true,
3151
- "console": false,
3152
- "tostatus": false,
3153
- "complete": "true",
3154
- "targetType": "full",
3155
- "statusVal": "",
3156
- "statusType": "auto",
3157
- "x": 660,
3158
- "y": 300,
3159
- "wires": []
3160
- },
3161
- {
3162
- "id": "5b61ceb915a981c1",
3163
- "type": "inject",
3164
- "z": "d2d4021c0003f913",
3165
- "name": "",
3166
- "props": [],
3167
- "repeat": "",
3168
- "crontab": "",
3169
- "once": false,
3170
- "onceDelay": 0.1,
3171
- "topic": "",
3172
- "x": 270,
3173
- "y": 420,
3174
- "wires": [
3175
- [
3176
- "b89a529a7e0b5f75"
3177
- ]
3178
- ]
3179
- },
3180
- {
3181
- "id": "b89a529a7e0b5f75",
3182
- "type": "function",
3183
- "z": "d2d4021c0003f913",
3184
- "name": "function 1",
3185
- "func": "msg = { \"_event\": { \"type\": \"click\", \"clientX\": 892, \"clientY\": 123, \"bbox\": { \"x\": 832.5, \"y\": 119, \"width\": 310, \"height\": 38, \"top\": 119, \"right\": 1142.5, \"bottom\": 157, \"left\": 832.5 } }, \"_client\": { \"user\": { \"id\": \"ca4ca3de-3e80-40f9-8233-453cf2233fc2\", \"displayName\": \"admin\", \"username\": \"admin\", \"profileUrl\": \"\", \"emails\": [{ \"value\": \"admin@admin.de\" }], \"claims\": { \"sub\": \"ca4ca3de-3e80-40f9-8233-453cf2233fc2\", \"profile\": \"\", \"email\": \"admin@admin.de\", \"locale\": \"\", \"nickname\": \"\", \"website\": \"\", \"middle_name\": \"\", \"zoneinfo\": \"\", \"given_name\": \"\", \"birthdate\": \"\", \"gender\": \"\", \"company\": \"\", \"family_name\": \"\", \"updated_at\": null, \"email_verified\": true, \"preferred_username\": \"\", \"picture\": \"\", \"name\": \"admin\", \"jti\": \"6CQecbRqFPnsTLKV_cbG9\", \"iat\": 1738242946, \"exp\": 1738246546, \"scope\": \"openid profile email lanes\", \"client_id\": \"PassportTestClient\", \"iss\": \"http://authority:11560/\", \"aud\": \"PassportTestClient\" }, \"accessToken\": \"eyJhbGciOiJSUzI1NiIsInR5cCI6ImF0K2p3dCIsImtpZCI6IlA1RXlTLVFjem80Z2IxQUNiNmxadmhDQTBpdWVNUnpqTlRuNnVpRl94RkkifQ.eyJzdWIiOiJjYTRjYTNkZS0zZTgwLTQwZjktODIzMy00NTNjZjIyMzNmYzIiLCJwcm9maWxlIjoiIiwiZW1haWwiOiJhZG1pbkBhZG1pbi5kZSIsImxvY2FsZSI6IiIsIm5pY2tuYW1lIjoiIiwid2Vic2l0ZSI6IiIsIm1pZGRsZV9uYW1lIjoiIiwiem9uZWluZm8iOiIiLCJnaXZlbl9uYW1lIjoiIiwiYmlydGhkYXRlIjoiIiwiZ2VuZGVyIjoiIiwiY29tcGFueSI6IiIsImZhbWlseV9uYW1lIjoiIiwidXBkYXRlZF9hdCI6bnVsbCwiZW1haWxfdmVyaWZpZWQiOnRydWUsInByZWZlcnJlZF91c2VybmFtZSI6IiIsInBpY3R1cmUiOiIiLCJuYW1lIjoiYWRtaW4iLCJqdGkiOiI2Q1FlY2JScUZQbnNUTEtWX2NiRzkiLCJpYXQiOjE3MzgyNDI5NDYsImV4cCI6MTczODI0NjU0Niwic2NvcGUiOiJvcGVuaWQgcHJvZmlsZSBlbWFpbCBsYW5lcyIsImNsaWVudF9pZCI6IlBhc3Nwb3J0VGVzdENsaWVudCIsImlzcyI6Imh0dHA6Ly9hdXRob3JpdHk6MTE1NjAvIiwiYXVkIjoiUGFzc3BvcnRUZXN0Q2xpZW50In0.sBPvFE38A1RX7bs_tjZf8IjOaMVmKqdCxlZo0r9YJvCRwC_kM6G-n4CQEYJkTkO4ZmNpCPk01vNasCsXPG-bUedHJzIPb1DxuHQX7N51jepjgf6SY_BOKhSftw0jJvnvTUfxzPBE4gb6a5VO02mPfTyt8Vqx54mM3tZgoA_OEg-T0Uv0PTYd4VT671TUwACVhFSN43njJ04jX...\" }, \"socketId\": \"RunwgKI4_c0wEvu3AAAB\", \"socketIp\": \"172.20.0.1\" }, \"topic\": \"\", \"payload\": \"\", \"_msgid\": \"98958041794d2d15\" }\nreturn msg;",
3186
- "outputs": 1,
3187
- "timeout": 0,
3188
- "noerr": 0,
3189
- "initialize": "",
3190
- "finalize": "",
3191
- "libs": [],
3192
- "x": 440,
3193
- "y": 420,
3194
- "wires": [
3195
- [
3196
- "4cc598063a38db82"
3197
- ]
3198
- ]
3199
- },
3200
- {
3201
- "id": "4cc598063a38db82",
3202
- "type": "process-start",
3203
- "z": "d2d4021c0003f913",
3204
- "name": "",
3205
- "engine": "b78932d162d8d468",
3206
- "processmodel": "StartProcessSample_Process",
3207
- "startevent": "StartEvent_1",
3208
- "x": 630,
3209
- "y": 420,
3210
- "wires": [
3211
- [
3212
- "da96fb5b9dfe8b66"
3213
- ]
3214
- ]
3215
- },
3216
- {
3217
- "id": "da96fb5b9dfe8b66",
3218
- "type": "debug",
3219
- "z": "d2d4021c0003f913",
3220
- "name": "debug 4",
3221
- "active": true,
3222
- "tosidebar": true,
3223
- "console": false,
3224
- "tostatus": false,
3225
- "complete": "true",
3226
- "targetType": "full",
3227
- "statusVal": "",
3228
- "statusType": "auto",
3229
- "x": 820,
3230
- "y": 420,
3231
- "wires": []
3232
3102
  }
3233
3103
  ]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@5minds/node-red-contrib-processcube",
3
- "version": "1.7.4-feature-6f3b75-m6ksn7zb",
3
+ "version": "1.7.4-feature-a91d79-m6kzfb4g",
4
4
  "license": "MIT",
5
5
  "description": "Node-RED nodes for ProcessCube",
6
6
  "scripts": {
@@ -4,14 +4,14 @@ module.exports = function (RED) {
4
4
  var node = this;
5
5
 
6
6
  node.engine = RED.nodes.getNode(config.engine);
7
- const isUser = !!msg._client?.user
8
- const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;
9
-
7
+
10
8
  let subscription = null;
11
9
  let subscribe = null;
12
-
10
+
13
11
  node.on('input', async function (msg) {
14
12
  const client = node.engine.engineClient;
13
+ const isUser = !!msg._client?.user
14
+ const userIdentity = isUser ? { userId: msg._client.user.id, token: msg._client.user.accessToken } : null;
15
15
  subscribe = async () => {
16
16
  if (!client) {
17
17
  node.error('No engine configured.', msg);