forked from soef/ioBroker.samsung
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
132 lines (111 loc) · 4.2 KB
/
index.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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
<html>
<!-- these 4 files always have to be included -->
<link rel="stylesheet" type="text/css" href="../../lib/css/themes/jquery-ui/redmond/jquery-ui.min.css"/>
<script type="text/javascript" src="../../lib/js/jquery-1.11.1.min.js"></script>
<script type="text/javascript" src="../../socket.io/socket.io.js"></script>
<script type="text/javascript" src="../../lib/js/jquery-ui-1.10.3.full.min.js"></script>
<!-- optional: use jqGrid
<link rel="stylesheet" type="text/css" href="../../lib/css/jqGrid/ui.jqgrid-4.5.4.css"/>
<script type="text/javascript" src="../../lib/js/jqGrid/jquery.jqGrid-4.5.4.min.js"></script>
<script type="text/javascript" src="../../lib/js/jqGrid/i18n/grid.locale-all.js"></script>
-->
<!-- optional: use multiselect
<link rel="stylesheet" type="text/css" href="../../lib/css/jquery.multiselect-1.13.css"/>
<script type="text/javascript" src="../../lib/js/jquery.multiselect-1.13.min.js"></script>
-->
<!-- these two file always have to be included -->
<link rel="stylesheet" type="text/css" href="../../css/adapter.css"/>
<script type="text/javascript" src="../../js/translate.js"></script>
<script type="text/javascript" src="../../js/adapter-settings.js"></script>
<script type="text/javascript">
systemDictionary = {
"samsung adapter settings": {"de": "Samsung Einstellungen", "ru": "Samsung"},
"IP": {
"en": "IP",
"de": "IP",
"ru": "IP"
},
"Info": {
"de": "Hinweis",
"en": "Info"
},
"Settings": {
"de": "Einstellungen",
"en": "Settings"
},
"on save adapter restarts with new config immediately": {
"de": "Beim Speichern der Einstellungen wird der Adapter automatisch neu gestartet.",
"ru": "Сразу после сохранения настроек драйвер перезапуститься с новыми значениями"
}
};
function load(settings, onChange) {
for (var key in settings) {
if ($('#' + key + '.value').attr('type') == 'checkbox') {
$('#' + key + '.value').prop('checked', settings[key]).change(function () {
onChange();
});
} else {
$('#' + key + '.value').val(settings[key]).change(function () {
onChange();
}).keyup(function () {
$(this).trigger('change');
});
}
}
onChange(false);
}
function save(callback) {
var obj = {};
$('.value').each(function () {
var $this = $(this);
var id = $this.attr('id');
if ($this.attr('type') == 'checkbox') {
obj[$this.attr('id')] = $this.prop('checked');
} else {
obj[$this.attr('id')] = $this.val();
}
});
callback(obj);
}
</script>
<style>
td {
font-size: 13px;
padding-left:1px;
padding-right: 4px;
padding-top: 3px;
padding-bottom: 3px;
}
input {
font-size: 13px;
}
h1 {
font-size: 11px;
color: #505050;
font-weight: bold;
width: 100%;
padding-left:6px;
padding-right: 5px;
padding-top: 5px;
padding-bottom: 5px;
background-color: #e0e0e0;
/*background-image: linear-gradient(to right, #e0e0e0, rgba(224,224,224,0.0));*/
/*background-image: linear-gradient(to right, #e0e0e0, #e8e8e8 50%, #e0e0e0);*/
}
</style>
<div id="adapter-container" style="padding-left: 6px; padding-right: 0px; width: 97%;">
<table>
<td><img src="samsung.png" /></td>
<td style="padding-top: 20px;padding-left: 10px"><h3 class="translate">samsung adapter settings</h3></td>
</table>
<h1 class="translate">Settings</h1>
<table>
<tr><td class="translate">IP</td><td><input class="value" id="ip" type="input" size="15" /></td></tr>
</table>
<div style="padding: 10px"></div>
<h1 class="translate">Info</h1>
<table>
<tr><td class="translate">on save adapter restarts with new config immediately</td></tr>
</table>
</div>
</html>