no message

This commit is contained in:
2025-07-03 16:42:22 +02:00
parent 3a49d32854
commit b2063fc58d
2 changed files with 19 additions and 38 deletions

View File

@@ -37,7 +37,6 @@
</div>
<script>
function Apply(data) {
console.log("Neue Daten:", data);
document.getElementById('barCons').style.width = data.prodCons + '%';
document.getElementById('barFeed').style.width = data.prodFeed + '%';
document.getElementById('barPV').style.width = data.consPV + '%';
@@ -65,18 +64,15 @@
if (typeof registerMessageHandler === 'function') {
registerMessageHandler(handleMessage);
} else {
console.warn("registerMessageHandler nicht verfügbar");
}
// Polling: hole alle 30 Sekunden frische Daten
// Live-Aktualisierung alle 30 Sekunden
function pollData() {
if (typeof IPS !== 'undefined') {
console.log("Poll: RequestAction(update)");
IPS.RequestAction('update', '');
}
}
setInterval(pollData, 30000);
</script>
</body>
</html>
</html>