Hi,
i've trouble finding how to hide/show node input pin and node output pin, in the html script configuration node.
Can someone help me in that?
Thanks.
Hi @Supergiovane - Hope you are well
You can set the input/output pin via a config entry.
See:
color: 'rgb(46,145,205)',
defaults: {
networkIdentifier: { value: undefined },
name: { value: 'ZWave Device' },
filteredNodeId: { value: 'All' },
multicast: { value: false },
datamode: { value: 'Send/Receive' },
messagesPerMS: { value: 1 },
messageInterval: { value: 250 },
isolated: { value: false },
outputs: { value: 1 },
inputs: { value: 1 },
showStatus: { value: true }
},
inputs: 1,
outputs: 1,
icon: 'Node.svg',
label: function () {
return this.name;
},
oneditprepare: SortUI,
And:
outputs: 1,
icon: 'Node.svg',
label: function () {
return this.name;
},
oneditprepare: SortUI,
oneditsave: SetIO,
paletteLabel: 'ZWave Device'
});
function SetIO() {
// Set Pins
switch ($('#node-input-datamode').val()) {
case 'Send':
this.outputs = 0;
this.inputs = 1;
break;
case 'Receive':
this.outputs = 1;
this.inputs = 0;
2 Likes
system
Closed
17 November 2023 09:47
4
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.