DmitrMakeev commited on
Commit
b41ae96
1 Parent(s): d642526

Update settings.html

Browse files
Files changed (1) hide show
  1. settings.html +43 -0
settings.html CHANGED
@@ -161,6 +161,49 @@ input[type="number"] {
161
  setInterval(fetchValues, 10000);
162
  </script>
163
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
164
  <script>
165
  document.getElementById("pH_set_but").addEventListener("click", function() {
166
  var pHValue = document.getElementById("pH_set").value;
 
161
  setInterval(fetchValues, 10000);
162
  </script>
163
 
164
+
165
+
166
+
167
+ <script>
168
+
169
+
170
+ function updateValues_eep_set(data) {
171
+ document.getElementById("pH_set").textContent = data.ph_eep;
172
+ document.getElementById("ph_on_set").textContent = data.ph_on_eep;
173
+ document.getElementById("ec_set").textContent = data.ec_eep;
174
+ document.getElementById("ec_A_set").textContent = data.ec_A_eep;
175
+ document.getElementById("ec_B_set").textContent = data.ec_B_eep;
176
+ document.getElementById("ec_C_set").textContent = data.ec_C_eep;
177
+ document.getElementById("l_ON_h_set").textContent = data.l_ON_h_eep;
178
+ document.getElementById("l_ON_m_set").textContent = data.l_ON_m_eep;
179
+ document.getElementById("l_OFF_h_set").textContent = data.l_OFF_h_eep;
180
+ document.getElementById("l_OFF_m_set").textContent = data.l_OFF_m_eep;
181
+ document.getElementById("t_Voz_set").textContent = data.t_Voz_eep;
182
+
183
+ }
184
+
185
+ function fetchValues_eep_set() {
186
+ var xhr = new XMLHttpRequest();
187
+ xhr.open("GET", "/settings_api_eep_set", true);
188
+ xhr.setRequestHeader("Content-Type", "application/json");
189
+ xhr.onreadystatechange = function () {
190
+ if (xhr.readyState === 4 && xhr.status === 200) {
191
+ var response = JSON.parse(xhr.responseText);
192
+ updateValues_eep_set(response);
193
+ }
194
+ };
195
+ xhr.send();
196
+ }
197
+
198
+ fetchValues_eep_set();
199
+
200
+ </script>
201
+
202
+
203
+
204
+
205
+
206
+
207
  <script>
208
  document.getElementById("pH_set_but").addEventListener("click", function() {
209
  var pHValue = document.getElementById("pH_set").value;