@zigasebenik/node-red-zte-sms
Version:
A Node-RED node to send sms messages using ZTE modem.
40 lines (37 loc) ⢠1.32 kB
HTML
<script type="text/javascript">
RED.nodes.registerType('zte-sms-mark', {
category: 'ZTE',
color: '#E9967A',
defaults: {
name: { value: '_DEFAULT_' },
modem: { value: '', type: 'zte-modem', required: true },
},
inputs: 1,
outputs: 1,
paletteLabel: 'SMS Mark Read',
align: 'right',
icon: 'font-awesome/fa-envelope-open-o',
label: function () {
return `${(this.name || 'zte-sms-mark')} \tš`;
},
onadd: function() {
if (this.name === '_DEFAULT_') {
this.name = '';
RED.actions.invoke("core:generate-node-names", this, { generateHistory: false });
}
},
});
</script>
<script type="text/html" data-template-name="zte-sms-mark">
<div class="form-row">
<label for="node-input-name"><i class="icon-tag"></i> Name</label>
<input type="text" id="node-input-name" placeholder="Name">
</div>
<div class="form-row">
<label for="node-input-modem"><i class="fa fa-wifi"></i> Modem</label>
<input id="node-input-modem" type="node-input-modem" style="width: 70%">
</div>
</script>
<script type="text/html" data-help-name="zte-sms-mark">
<a href="https://github.com/sebenik/node-red-zte-sms?tab=readme-ov-file">Documentation available here.</a>
</script>