node-red-contrib-prib-functions
Version:
Node-RED added node functions.
68 lines (64 loc) • 2.2 kB
HTML
<script type="text/javascript">
/*globals RED */
RED.nodes.registerType('eChart', {
category: 'function',
color: '#fdeea2',
defaults: {
name: {value: ""},
source1Property:{value:"msg.payload"},
source2Property:{value:"msg.payload"},
targetProperty:{value:"msg.payload"}
},
inputs: 1,
outputs: 2,
icon: "Tape-Measure-icchart-671.png",
align: 'left',
paletteLabel: "eChart",
inputLabels: "Message In",
outputLabels: ["Message Out","Error"],
label: function () {
return this.name || "eChart";
},
oneditprepare: function() {
},
oneditsave: function() {
},
oneditresize: function() {
},
resizeRule: function(file,newWidth) {
}
});
</script>
<script type="text/x-red" data-template-name="eChart">
<div class="form-row">
<label for="node-input-name"><i class="fa fa-tag"></i> Name </label>
<input type="text" id="node-input-name" placeholder="Name">
</div>
<div class="form-row form-row-http-in-source1Property show">
<label for="node-input-source1Property" style="white-space: nowrap"><i class="icon-bookmark"></i> Argument 1</label>
<input type="text" id="node-input-source1Property" placeholder="msg.payload">
</div>
<div class="form-row form-row-http-in-source1Property show">
<label for="node-input-source2Property" style="white-space: nowrap"><i class="icon-bookmark"></i> Argument 2</label>
<input type="text" id="node-input-source2Property" placeholder="msg.payload">
</div>
<div class="form-row form-row-http-in-targetProperty show">
<label for="node-input-targetProperty" style="white-space: nowrap"><i class="icon-bookmark"></i> Target Property </label>
<input type="text" id="node-input-targetProperty" placeholder="msg.payload">
</div>
</script>
<script type="text/x-red" data-help-name="eChart">
<p>
eChart for two strings
</p>
<p>
Source/Target/Topic/Columns allows the override of the property to an expression which can reference RED, node or msg variables.
</p>
<h3>Inputs</h3>
<dl class="message-properties">
<dt>msg <span class="property-type">topic</span></dt>
<dd>incoming message with topic</dd>
<dt>msg <span class="property-type">payload</span></dt>
<dd></dd>
</dl>
</script>