@gregoriusrippenstein/node-red-contrib-nodedev 0.5.4 → 0.5.6

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.
@@ -58,6 +58,7 @@ RED.nodes.registerType('NodeDevOps', {
58
58
 
59
59
  nodered_uninstall: { value: false },
60
60
 
61
+ create_control_center: { value: false },
61
62
  ignore_package_check: { value: false },
62
63
 
63
64
  gitcommit: { value: false },
@@ -99,6 +100,12 @@ RED.nodes.registerType('NodeDevOps', {
99
100
  },
100
101
 
101
102
  oneditprepare: function () {
103
+ $('#node-input-create_control_center').on('change', () => {
104
+ if ($('#node-input-create_control_center').is(":checked") ) {
105
+ $('#node-input-gitcommit').prop('checked', true).trigger('change')
106
+ }
107
+ })
108
+
102
109
  $('#node-input-nodered_uninstall').on('change', () => {
103
110
  if ($('#node-input-nodered_uninstall').is(":checked")) {
104
111
  $('#node-input-noderedinstall').prop('checked', false).trigger('change')
@@ -260,6 +267,13 @@ RED.nodes.registerType('NodeDevOps', {
260
267
  <input type="text" id="node-input-pdescription" placeholder="Package description"/>
261
268
  </div>
262
269
 
270
+ <div class="form-row">
271
+ <label for="node-input-create_control_center" style="min-width: 150px;"">
272
+ <span>Create Control Center?</span>
273
+ </label>
274
+ <input type="checkbox" id="node-input-create_control_center" style="display:inline-block; width:15px; vertical-align:baseline;">
275
+ </div>
276
+
263
277
  <div class="form-row">
264
278
  <label for="node-input-ignore_package_check" style="min-width: 150px;"">
265
279
  <span>No package check?</span>
@@ -254,6 +254,7 @@ module.exports = function (RED) {
254
254
  var jsPath = path.join(__dirname, 'templates', 'tmpl.js');
255
255
  var localeJsonPath = path.join(__dirname, 'templates', 'locale', 'en-US', 'tmpl.json')
256
256
  var localeHtmlPath = path.join(__dirname, 'templates', 'locale', 'en-US', 'tmpl.html')
257
+ var localeMarkdownPath = path.join(__dirname, 'templates', 'locale', 'en-US', 'tmpl.md')
257
258
 
258
259
  var content = {};
259
260
 
@@ -263,13 +264,15 @@ module.exports = function (RED) {
263
264
  handleTemplate(msg, node, fs.readFileSync(jsPath, 'utf8')).then((c) => { content["jasc"] = c }),
264
265
  handleTemplate(msg, node, fs.readFileSync(localeJsonPath, 'utf8')).then((c) => { content["ljsn"] = c }),
265
266
  handleTemplate(msg, node, fs.readFileSync(localeHtmlPath, 'utf8')).then((c) => { content["lhtm"] = c }),
267
+ handleTemplate(msg, node, fs.readFileSync(localeMarkdownPath, 'utf8')).then((c) => { content["lmkd"] = c }),
266
268
  ];
267
269
 
268
270
  return Promise.all(promises).then(() => {
269
- var secondId = RED.util.generateId();
271
+ var secondId = RED.util.generateId();
270
272
  var secondIdTempJs = RED.util.generateId();
271
- var thirdId = RED.util.generateId();
272
- var fourthId = RED.util.generateId();
273
+ var thirdId = RED.util.generateId();
274
+ var fourthId = RED.util.generateId();
275
+ var fifthId = RED.util.generateId();
273
276
 
274
277
  return [{
275
278
  id: RED.util.generateId(),
@@ -293,13 +296,10 @@ module.exports = function (RED) {
293
296
  "format": "javascript",
294
297
  "syntax": "mustache",
295
298
  "template": content["htjs"],
299
+ "output": "str",
296
300
  "x": 100,
297
301
  "y": 100,
298
- "wires": [
299
- [
300
- secondId
301
- ]
302
- ]
302
+ "wires": [[secondId]]
303
303
  },
304
304
  {
305
305
  id: secondId,
@@ -329,6 +329,20 @@ module.exports = function (RED) {
329
329
  },
330
330
  {
331
331
  id: fourthId,
332
+ type: "template",
333
+ name: "Locale: " + msg.node.name + " Markdown",
334
+ field: msg.node.name + "TmplMarkdown",
335
+ fieldType: "msg",
336
+ template: content["lmkd"],
337
+ syntax: "mustache",
338
+ format: "markdown",
339
+ output: "str",
340
+ x: 120,
341
+ y: 250,
342
+ wires: [[fifthId]]
343
+ },
344
+ {
345
+ id: fifthId,
332
346
  type: "PkgFile",
333
347
  name: "Locale: " + msg.node.name + ".html",
334
348
  filename: "nodes/locales/en-US/" + msg.node.namelwr + ".html",
@@ -337,7 +351,7 @@ module.exports = function (RED) {
337
351
  format: "html",
338
352
  output: "str",
339
353
  x: 120,
340
- y: 250,
354
+ y: 300,
341
355
  wires: [[]]
342
356
  }
343
357
  ]
@@ -1,18 +1,3 @@
1
1
  <script type="text/markdown" data-help-name="{{ node.name }}">
2
- {{{ node.summary }}}
3
-
4
- ### Inputs
5
-
6
- : payload (any) : what is expected as payload input.
7
- : topic (string) : (optional) is a topic expected or handled.
8
-
9
- ### Outputs
10
-
11
- : payload (any) : what is returned as payload.
12
-
13
- ### Description
14
-
15
- {{{ node.description }}}
16
-
17
- <!-- [Markdown documentation details](https://nodered.org/docs/creating-nodes/help-style-guide) -->
2
+ {{ __.ocb3 }} {{ node.name }}TmplMarkdown {{ __.ccb3 }}
18
3
  </script>
@@ -0,0 +1,16 @@
1
+ {{{ node.summary }}}
2
+
3
+ ### Inputs
4
+
5
+ : payload (any) : what is expected as payload input.
6
+ : topic (string) : (optional) is a topic expected or handled.
7
+
8
+ ### Outputs
9
+
10
+ : payload (any) : what is returned as payload.
11
+
12
+ ### Description
13
+
14
+ {{{ node.description }}}
15
+
16
+ <!-- [Markdown documentation details](https://nodered.org/docs/creating-nodes/help-style-guide) -->
@@ -81,6 +81,12 @@
81
81
  return this.name?"node_label_italic":"";
82
82
  },
83
83
 
84
+ // called when node is added to workspace also if copied and pasted.
85
+ // once for each node added to the workspace
86
+ onadd: function() {
87
+ },
88
+
89
+ // called when node added to palette - one time
84
90
  onpaletteadd: function() {
85
91
  {{#node.bak2frtcomm}}
86
92
  this.messageFromBackendHandler = (topic,dataobj) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name" : "@gregoriusrippenstein/node-red-contrib-nodedev",
3
- "version": "0.5.4",
3
+ "version": "0.5.6",
4
4
  "dependencies": {
5
5
  "pako": "^2.1.0",
6
6
  "tar-stream": "^3.1.6",