diff --git a/plugins/sentinel/dashboard.html b/plugins/sentinel/dashboard.html index 395575d..87aa53b 100644 --- a/plugins/sentinel/dashboard.html +++ b/plugins/sentinel/dashboard.html @@ -223,6 +223,11 @@ var body = card.querySelector('.metrics-body'); if (!body) return; + var oldCpu = parseFloat(body.getAttribute('data-cpu')||(sys.cpu||{}).percent||0); + var oldMem = parseFloat(body.getAttribute('data-mem')||(sys.memory||{}).percent||0); + body.setAttribute('data-cpu', (sys.cpu||{}).percent||0); + body.setAttribute('data-mem', (sys.memory||{}).percent||0); + if (isRow) { body.querySelector('.net-down').textContent = fmtSpeed(net.rx_bytes_sec||0); body.querySelector('.net-up').textContent = fmtSpeed(net.tx_bytes_sec||0);