From 1191eff07843f976ba5cc0bcc271f03239470f20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=84=EC=83=81=ED=98=84?= Date: Sun, 2 Oct 2022 17:11:41 +0900 Subject: [PATCH 1/2] [modify]tab and group label change --- dashboard/nodes/locales/en-US/soop_tab.html | 5 - dashboard/nodes/locales/en-US/soop_tab.json | 9 -- dashboard/nodes/soop_group.html | 122 ++++++++++++-------- dashboard/nodes/soop_group.js | 19 ++- dashboard/nodes/soop_tab.html | 120 ++++++++++++++++++- dashboard/nodes/soop_tab.js | 8 +- 6 files changed, 211 insertions(+), 72 deletions(-) delete mode 100644 dashboard/nodes/locales/en-US/soop_tab.html delete mode 100644 dashboard/nodes/locales/en-US/soop_tab.json diff --git a/dashboard/nodes/locales/en-US/soop_tab.html b/dashboard/nodes/locales/en-US/soop_tab.html deleted file mode 100644 index 2ffe2068..00000000 --- a/dashboard/nodes/locales/en-US/soop_tab.html +++ /dev/null @@ -1,5 +0,0 @@ - \ No newline at end of file diff --git a/dashboard/nodes/locales/en-US/soop_tab.json b/dashboard/nodes/locales/en-US/soop_tab.json deleted file mode 100644 index 13296fd7..00000000 --- a/dashboard/nodes/locales/en-US/soop_tab.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "soop_tab": { - "label": { - "tab": "Tab ", - "name": "Name" - } - - } -} \ No newline at end of file diff --git a/dashboard/nodes/soop_group.html b/dashboard/nodes/soop_group.html index f9f7b22a..92d5c988 100644 --- a/dashboard/nodes/soop_group.html +++ b/dashboard/nodes/soop_group.html @@ -1,96 +1,122 @@ \ No newline at end of file diff --git a/dashboard/nodes/soop_group.js b/dashboard/nodes/soop_group.js index 712bd881..f445d312 100644 --- a/dashboard/nodes/soop_group.js +++ b/dashboard/nodes/soop_group.js @@ -1,24 +1,33 @@ module.exports = function(RED) { + const dashboard = require("../dashboard")(RED); function GroupNode(config) { + const node = this; RED.nodes.createNode(this, config); this.config = { name: config.name, displayVisible: config.displayVisible, - groupX: config.x, - groupY: config.y, + groupX: config.groupX, + groupY: config.groupY, width: config.width, height: config.height, order: config.order, tab: config.tab, groupState: config.groupState, - includedNodesId: config.includedNodesId + includedNodesId: config.includedNodesId, }; - if (!this.config.hasOwnProperty("displayVisible")) { this.config.displayVisible = true; } - if (this.config.displayVisible !== false) { this.config.displayVisible = true; } + if (!this.config.hasOwnProperty("displayVisible")) { + this.config.displayVisible = true; + } + if (this.config.displayVisible !== false) { + this.config.displayVisible = true; + } for (var i = 0; i < this.config.height; i++) { this.config.groupState[i] = new Array(this.config.width); } + dashboard.addNode({ + node: node, + }); } RED.nodes.registerType("soop_group", GroupNode); diff --git a/dashboard/nodes/soop_tab.html b/dashboard/nodes/soop_tab.html index b9346279..0775c071 100644 --- a/dashboard/nodes/soop_tab.html +++ b/dashboard/nodes/soop_tab.html @@ -1,18 +1,130 @@ \ No newline at end of file diff --git a/dashboard/nodes/soop_tab.js b/dashboard/nodes/soop_tab.js index a7f004c0..5d0dd313 100644 --- a/dashboard/nodes/soop_tab.js +++ b/dashboard/nodes/soop_tab.js @@ -1,11 +1,17 @@ module.exports = function(RED) { + const dashboard = require("../dashboard")(RED); function TabNode(config) { + const node = this; RED.nodes.createNode(this, config); this.config = { name: config.name, - includedGroups: config.includedGroups + includedGroups: config.includedGroups, + includedGroupsName: config.includedGroupsName }; + dashboard.addNode({ + node: node, + }); } RED.nodes.registerType("soop_tab", TabNode); From 44ec3c61d2213449ee82788b388d2ba2620083a0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=84=EC=83=81=ED=98=84?= Date: Sun, 2 Oct 2022 17:16:27 +0900 Subject: [PATCH 2/2] [modify]group typo change --- dashboard/nodes/soop_group.html | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dashboard/nodes/soop_group.html b/dashboard/nodes/soop_group.html index 92d5c988..f9cea069 100644 --- a/dashboard/nodes/soop_group.html +++ b/dashboard/nodes/soop_group.html @@ -104,10 +104,10 @@
- - - - + + + +