-
Notifications
You must be signed in to change notification settings - Fork 1
/
node-red-contrib-logsene.html
60 lines (54 loc) · 1.79 KB
/
node-red-contrib-logsene.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
57
58
59
60
<script type="text/javascript">
RED.nodes.registerType('logsene',{
category: 'storage-output',
color: 'lightblue',
defaults: {
name: {value:""},
server: {value:"", type:"logsene-saas"}
},
inputs:1,
outputs:0,
icon: "file.png",
label: function() {
return this.name||"logsene";
}
});
</script>
<script type="text/x-red" data-template-name="logsene">
<div class="form-row">
<label for="node-input-server"><i class="fa fa-file"></i> Server</label>
<input type="text" id="node-input-server" placeholder="Server">
</div>
<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>
</script>
<script type="text/x-red" data-help-name="logsene">
<p>A node that logs to Logsene by Sematext</p>
</script>
<script type="text/javascript">
RED.nodes.registerType('logsene-saas',{
category: 'config',
defaults: {
token: {value:"",required:true},
logname: {value:"", required: true}
// reserved for OnPremises Version
//host: {value:"",required:true},
//port: {value:80,required:true,validate:RED.validators.number()},
},
label: function() {
return this.logType + "--" + this.token;
}
});
</script>
<script type="text/x-red" data-template-name="logsene-saas">
<div class="form-row">
<label for="node-config-input-token"><i class="icon-bookmark"></i> Token</label>
<input type="text" id="node-config-input-token">
</div>
<div class="form-row">
<label for="node-config-input-logname"><i class="icon-bookmark"></i> Log Name</label>
<input type="text" id="node-config-input-logname">
</div>
</script>