-
Notifications
You must be signed in to change notification settings - Fork 1
/
smartpi-input.html
56 lines (53 loc) · 1.99 KB
/
smartpi-input.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<script type="text/javascript">
RED.nodes.registerType('smartpi-input', {
category: 'SmartPi',
color: '#a6bbcf',
defaults: {
name: {
value: "smartpi-input"
},
indicator: {
value: ""
},
usetrigger: {
value: false,
},
},
inputs: 1,
outputs: 1,
icon: "arrow-in.png",
label: function() {
return this.name + " " + this.indicator || "smartpi-input " + this.indicator;
}
});
</script>
<script type="text/x-red" data-template-name="smartpi-input">
<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">
<label for="node-input-indicator"><i class="icon-random"></i> Indicator</label>
<select id="node-input-indicator">
<option value="p">Power total</option>
<option value="p1">Power phase 1</option>
<option value="p2">Power phase 2</option>
<option value="p3">Power phase 3</option>
<option value="i">Current total</option>
<option value="i1">Current phase 1</option>
<option value="i2">Current phase 2</option>
<option value="i3">Current phase 3</option>
<option value="i4">Current phase 4</option>
<option value="v1">Voltage phase 1</option>
<option value="v2">Voltage phase 2</option>
<option value="v3">Voltage phase 3</option>
</select>
</div>
<div class="form-row">
<input type="checkbox" id="node-input-usetrigger" style="display: inline-block; width: auto; vertical-align: top;">
<label for="node-input-usetrigger" style="width: 70%;"> <i class="fa fa-book"></i> Use trigger (output of values only if input 1 or true)</label>
</div>
</script>
<script type="text/x-red" data-help-name="smartpi-input">
<p>Input of measured values from the SmartPi.</p>
</script>