@frangoteam/fuxa-min 1.3.0 → 1.3.1
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/api/command/index.js +1 -1
- package/api/index.js +3 -0
- package/api/scripts/index.js +7 -3
- package/dist/assets/i18n/en.json +10 -3
- package/dist/assets/i18n/fr.json +2 -1
- package/dist/assets/i18n/ja.json +2 -1
- package/dist/assets/i18n/sv.json +2 -1
- package/dist/assets/i18n/zh-cn.json +2 -1
- package/dist/assets/i18n/zh-tw.json +2 -1
- package/dist/assets/lib/svgeditor/fuxa-editor.min.js +17 -23
- package/dist/index.html +1 -1
- package/dist/{main.bafae830903d548e.js → main.72bdfed42c527918.js} +6 -6
- package/docs/openapi.yaml +3 -0
- package/integrations/node-red/index.js +4 -5
- package/integrations/node-red/node-red-contrib-fuxa/nodes/fuxa-get-tag.html +39 -35
- package/integrations/node-red/node-red-contrib-fuxa/nodes/fuxa-get-tag.js +43 -17
- package/integrations/node-red/node-red-contrib-fuxa/nodes/fuxa-set-tag.html +42 -34
- package/integrations/node-red/node-red-contrib-fuxa/nodes/fuxa-set-tag.js +32 -12
- package/main.js +3 -0
- package/package.json +1 -1
- package/runtime/alarms/alarmstorage.js +45 -30
- package/runtime/apikeys/apiKeysStorage.js +34 -22
- package/runtime/devices/odbc/index.js +9 -4
- package/runtime/devices/s7/index.js +2 -2
- package/runtime/notificator/notifystorage.js +34 -23
- package/runtime/project/index.js +16 -0
- package/runtime/project/prjstorage.js +78 -40
- package/runtime/scripts/index.js +6 -2
- package/runtime/storage/calculator.js +17 -13
- package/runtime/storage/influxdb/index.js +8 -3
- package/runtime/storage/questdb/index.js +1 -1
- package/runtime/storage/sqlite/index.js +11 -8
- package/runtime/storage/tdengine/index.js +24 -9
- package/runtime/users/usrstorage.js +65 -61
- package/settings.default.js +3 -0
package/api/command/index.js
CHANGED
|
@@ -78,7 +78,7 @@ module.exports = {
|
|
|
78
78
|
if (res.statusCode === 403) {
|
|
79
79
|
runtime.logger.error("api get getTagValue: Tocken Expired");
|
|
80
80
|
} else if (!authJwt.haveAdminPermission(permission) && !runtime.scriptsMgr.isAuthorisedByScriptName(req.query.sourceScriptName, permission)) {
|
|
81
|
-
res.status(
|
|
81
|
+
res.status(401).json({error:"unauthorized_error", message: "Unauthorized!"});
|
|
82
82
|
runtime.logger.error("api get getTagValue: Unauthorized");
|
|
83
83
|
} else {
|
|
84
84
|
try {
|
package/api/index.js
CHANGED
|
@@ -229,6 +229,9 @@ function mergeUserSettings(settings) {
|
|
|
229
229
|
if (settings.language) {
|
|
230
230
|
runtime.settings.language = settings.language;
|
|
231
231
|
}
|
|
232
|
+
if (!utils.isNullOrUndefined(settings.hideEditorOnboarding)) {
|
|
233
|
+
runtime.settings.hideEditorOnboarding = settings.hideEditorOnboarding;
|
|
234
|
+
}
|
|
232
235
|
runtime.settings.broadcastAll = settings.broadcastAll;
|
|
233
236
|
runtime.settings.secureEnabled = settings.secureEnabled;
|
|
234
237
|
runtime.settings.logFull = settings.logFull;
|
package/api/scripts/index.js
CHANGED
|
@@ -32,15 +32,19 @@ module.exports = {
|
|
|
32
32
|
*/
|
|
33
33
|
scriptsApp.post("/api/runscript", secureFnc, function (req, res, next) {
|
|
34
34
|
const permission = checkGroupsFnc(req);
|
|
35
|
+
const script = req.body?.params?.script;
|
|
35
36
|
if (res.statusCode === 403) {
|
|
36
37
|
runtime.logger.error("api post runscript: Tocken Expired");
|
|
37
38
|
//runtime.settings.secureEnabled
|
|
38
|
-
} else if (!
|
|
39
|
+
} else if (script?.test && (!req.isAuthenticated || !authJwt.haveAdminPermission(permission))) {
|
|
40
|
+
res.status(401).json({ error: "unauthorized_error", message: "Unauthorized!" });
|
|
41
|
+
runtime.logger.error("api post runscript: Unauthorized test mode");
|
|
42
|
+
} else if (!runtime.scriptsMgr.isAuthorised(script, permission)) {
|
|
39
43
|
res.status(400).json({ error: "unauthorized_error", message: "Unauthorized!" });
|
|
40
44
|
runtime.logger.error("api post runscript: Unauthorized");
|
|
41
45
|
} else {
|
|
42
46
|
//req.body.params.script.parameters.permission = groups;
|
|
43
|
-
runtime.scriptsMgr.runScript(
|
|
47
|
+
runtime.scriptsMgr.runScript(script, req.body.params.toLogEvent).then(function (result) {
|
|
44
48
|
res.json(result);
|
|
45
49
|
}).catch(function (err) {
|
|
46
50
|
if (err.code) {
|
|
@@ -82,4 +86,4 @@ module.exports = {
|
|
|
82
86
|
});
|
|
83
87
|
return scriptsApp;
|
|
84
88
|
}
|
|
85
|
-
}
|
|
89
|
+
}
|
package/dist/assets/i18n/en.json
CHANGED
|
@@ -307,6 +307,9 @@
|
|
|
307
307
|
"chart.property-refresh-interval": "Refresh interval (min.)",
|
|
308
308
|
"chart.property-hide-toolbar": "Hide toolbar",
|
|
309
309
|
"chart.property-thouch-zoom": "Thouch Zoom",
|
|
310
|
+
"chart.property-mouse-wheel-scroll": "Mouse wheel scroll",
|
|
311
|
+
"chart.property-mouse-wheel-zoom": "Mouse wheel zoom",
|
|
312
|
+
"chart.property-static-chart": "Static chart",
|
|
310
313
|
"chart.property-load-old-values": "Load history",
|
|
311
314
|
"chart.property-date.format": "Date format",
|
|
312
315
|
"chart.property-time.format": "Time format",
|
|
@@ -575,6 +578,12 @@
|
|
|
575
578
|
"editor.controls-slider": "Slider",
|
|
576
579
|
"editor.controls-slider-settings": "Slider settings",
|
|
577
580
|
"editor.controls-shape-settings": "Shape settings",
|
|
581
|
+
"editor.onboarding-wizard-title": "Initial Security Setup",
|
|
582
|
+
"editor.onboarding-wizard-message": "Configure the editor's initial security now to avoid unprotected access and the use of default credentials.",
|
|
583
|
+
"editor.onboarding-wizard-hide": "Do not show this wizard again",
|
|
584
|
+
"editor.onboarding-wizard-admin-password": "Administrator password",
|
|
585
|
+
"editor.onboarding-wizard-admin-password-message": "Set a new password for the default administrator account 'admin'.",
|
|
586
|
+
"editor.onboarding-wizard-admin-password-required": "Administrator password required",
|
|
578
587
|
"editor.controls-html-switch-settings": "Switch settings",
|
|
579
588
|
"editor.controls-switch": "Switch",
|
|
580
589
|
"editor.controls-graphbar": "Bar Graph",
|
|
@@ -1618,6 +1627,7 @@
|
|
|
1618
1627
|
"report.item-interval": "Interval (period)",
|
|
1619
1628
|
"report.item-interval-min5": "5 minutes",
|
|
1620
1629
|
"report.item-interval-min10": "10 minutes",
|
|
1630
|
+
"report.item-interval-min15": "15 minutes",
|
|
1621
1631
|
"report.item-interval-min30": "30 minutes",
|
|
1622
1632
|
"report.item-interval-hour": "1 Hour",
|
|
1623
1633
|
"report.item-interval-day": "1 Day",
|
|
@@ -1938,6 +1948,3 @@
|
|
|
1938
1948
|
"msg.operation-unauthorized": "Operation Unauthorized!",
|
|
1939
1949
|
"msg.secret-code-required": "Secret code required to sign authentication tokens"
|
|
1940
1950
|
}
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
package/dist/assets/i18n/fr.json
CHANGED
|
@@ -293,6 +293,8 @@
|
|
|
293
293
|
"chart.property-refresh-interval": "Intervalle de rafraîchissement (min.)",
|
|
294
294
|
"chart.property-hide-toolbar": "Masquer la barre d'outils",
|
|
295
295
|
"chart.property-thouch-zoom": "Zoom tactile",
|
|
296
|
+
"chart.property-mouse-wheel-scroll": "Défilement molette souris",
|
|
297
|
+
"chart.property-mouse-wheel-zoom": "Zoom molette souris",
|
|
296
298
|
"chart.property-load-old-values": "Charger l'historique",
|
|
297
299
|
"chart.property-date.format": "Format de la date",
|
|
298
300
|
"chart.property-time.format": "Format de l'heure",
|
|
@@ -1724,4 +1726,3 @@
|
|
|
1724
1726
|
}
|
|
1725
1727
|
|
|
1726
1728
|
|
|
1727
|
-
|
package/dist/assets/i18n/ja.json
CHANGED
|
@@ -298,6 +298,8 @@
|
|
|
298
298
|
"chart.property-refresh-interval": "更新間隔 (分)",
|
|
299
299
|
"chart.property-hide-toolbar": "ツールバー非表示",
|
|
300
300
|
"chart.property-thouch-zoom": "タッチズーム",
|
|
301
|
+
"chart.property-mouse-wheel-scroll": "マウスホイールスクロール",
|
|
302
|
+
"chart.property-mouse-wheel-zoom": "マウスホイールズーム",
|
|
301
303
|
" chart.property-load-old-values": "履歴を読み込む",
|
|
302
304
|
"chart.property-date.format": "日付形式",
|
|
303
305
|
"chart.property-time.format": "時刻形式",
|
|
@@ -1757,4 +1759,3 @@
|
|
|
1757
1759
|
"msg.operation-unauthorized": "操作が許可されていません!"
|
|
1758
1760
|
}
|
|
1759
1761
|
|
|
1760
|
-
|
package/dist/assets/i18n/sv.json
CHANGED
|
@@ -296,6 +296,8 @@
|
|
|
296
296
|
"chart.property-refresh-interval": "Uppdateringsintervall (min.)",
|
|
297
297
|
"chart.property-hide-toolbar": "Dölj verktygsfält",
|
|
298
298
|
"chart.property-thouch-zoom": "Pekzoom",
|
|
299
|
+
"chart.property-mouse-wheel-scroll": "Mushjulsskroll",
|
|
300
|
+
"chart.property-mouse-wheel-zoom": "Mushjulszoom",
|
|
299
301
|
"chart.property-load-old-values": "Ladda historik",
|
|
300
302
|
"chart.property-date.format": "Datumformat",
|
|
301
303
|
"chart.property-time.format": "Tidsformat",
|
|
@@ -1702,4 +1704,3 @@
|
|
|
1702
1704
|
"msg.operation-unauthorized": "Operation obehörig!"
|
|
1703
1705
|
}
|
|
1704
1706
|
|
|
1705
|
-
|
|
@@ -293,6 +293,8 @@
|
|
|
293
293
|
"chart.property-refresh-interval": "刷新间隔(分钟)",
|
|
294
294
|
"chart.property-hide-toolbar": "隐藏工具栏",
|
|
295
295
|
"chart.property-thouch-zoom": "触摸缩放",
|
|
296
|
+
"chart.property-mouse-wheel-scroll": "鼠标滚轮滚动",
|
|
297
|
+
"chart.property-mouse-wheel-zoom": "鼠标滚轮缩放",
|
|
296
298
|
"chart.property-load-old-values": "加载历史",
|
|
297
299
|
"chart.property-date.format": "日期格式",
|
|
298
300
|
"chart.property-time.format": "时间格式",
|
|
@@ -1727,4 +1729,3 @@
|
|
|
1727
1729
|
}
|
|
1728
1730
|
|
|
1729
1731
|
|
|
1730
|
-
|
|
@@ -293,6 +293,8 @@
|
|
|
293
293
|
"chart.property-refresh-interval": "重新整理間隔(分鐘)",
|
|
294
294
|
"chart.property-hide-toolbar": "隱藏工具列",
|
|
295
295
|
"chart.property-thouch-zoom": "觸控縮放",
|
|
296
|
+
"chart.property-mouse-wheel-scroll": "滑鼠滾輪捲動",
|
|
297
|
+
"chart.property-mouse-wheel-zoom": "滑鼠滾輪縮放",
|
|
296
298
|
"chart.property-load-old-values": "載入歷史",
|
|
297
299
|
"chart.property-date.format": "日期格式",
|
|
298
300
|
"chart.property-time.format": "時間格式",
|
|
@@ -1725,4 +1727,3 @@
|
|
|
1725
1727
|
}
|
|
1726
1728
|
|
|
1727
1729
|
|
|
1728
|
-
|