debug: surplus_w in API + Live-Tab anzeigen

This commit is contained in:
retr0
2026-05-04 11:31:06 +02:00
parent 06bc030b07
commit 58a33f966d
2 changed files with 7 additions and 1 deletions
+5
View File
@@ -1079,10 +1079,15 @@ function renderSurplusStatus(surplusData) {
</div>`;
}).join('');
if (!rows) return '';
const surplusW = surplusData.surplus_w ?? null;
const surplusInfo = surplusW !== null
? `<span style="font-size:11px;color:var(--text-dim);margin-left:auto">${surplusW >= 0 ? '+' : ''}${Math.round(surplusW)} W Überschuss</span>`
: '';
return `<div class="inv-section">
<div class="inv-header">
<div class="inv-title">Überschuss-Geräte</div>
<div class="inv-badge ok">Z2M</div>
${surplusInfo}
</div>
<div style="padding:0 2px">${rows}</div>
</div>`;