#6 UI Updates senden und anzeigen

This commit is contained in:
David Zingg 2019-11-20 21:54:23 +01:00
parent 0a7aea4f35
commit 8cc9e20741

View File

@ -142,9 +142,8 @@ $(function() {
} }
self.mystromswitchEnabled(data.mystromswitchEnabled); self.mystromswitchEnabled(data.mystromswitchEnabled);
if (data.type == "timeout") { if (data.power != null) {
if ((data.timeout_value != null) && (data.timeout_value > 0)) { self.timeoutPopupOptions.text = self.timeoutPopupText + data.power;
self.timeoutPopupOptions.text = self.timeoutPopupText + data.timeout_value;
if (typeof self.timeoutPopup != "undefined") { if (typeof self.timeoutPopup != "undefined") {
self.timeoutPopup.update(self.timeoutPopupOptions); self.timeoutPopup.update(self.timeoutPopupOptions);
} else { } else {
@ -157,7 +156,6 @@ $(function() {
self.timeoutPopup = undefined; self.timeoutPopup = undefined;
} }
} }
}
} }
self.abortShutdown = function(abortShutdownValue) { self.abortShutdown = function(abortShutdownValue) {