From 5ed4757e201836484dfe10d26423e0f9772f8910 Mon Sep 17 00:00:00 2001 From: Echo Date: Sun, 15 Feb 2026 23:28:42 +0000 Subject: [PATCH] Update ashboard, dashboard (~2) --- dashboard/eco.html | 22 ---------------------- dashboard/index.html | 19 +++++++++++++++++++ 2 files changed, 19 insertions(+), 22 deletions(-) diff --git a/dashboard/eco.html b/dashboard/eco.html index d9f5f78..3485e0f 100644 --- a/dashboard/eco.html +++ b/dashboard/eco.html @@ -649,10 +649,6 @@ Refresh - @@ -1241,24 +1237,6 @@ } } - // ── Taskboard Restart ───────────────────────────────────── - - async function restartTaskboard() { - if (!confirm('Restart taskboard? Pagina va fi indisponibila ~5 secunde.')) return; - try { - await fetch('/echo/api/eco/restart-taskboard', { method: 'POST' }); - } catch (e) { /* expected — server dies */ } - // Wait for restart, then reload - setTimeout(() => { - const check = setInterval(async () => { - try { - const r = await fetch('/echo/api/status'); - if (r.ok) { clearInterval(check); location.reload(); } - } catch (e) { /* still restarting */ } - }, 1000); - }, 2000); - } - // ── Init ──────────────────────────────────────────────── loadStatus(); diff --git a/dashboard/index.html b/dashboard/index.html index 7817a4f..5d6addf 100644 --- a/dashboard/index.html +++ b/dashboard/index.html @@ -1100,6 +1100,9 @@ + @@ -1507,6 +1510,22 @@ updateStatusSummary(); } + async function restartTaskboard() { + if (!confirm('Restart taskboard? Pagina va fi indisponibilă ~5 secunde.')) return; + showToast('Se restartează taskboard...', 'info'); + try { + await fetch('/echo/api/eco/restart-taskboard', { method: 'POST' }); + } catch (e) { /* expected — server dies */ } + setTimeout(() => { + const check = setInterval(async () => { + try { + const r = await fetch('/echo/api/status'); + if (r.ok) { clearInterval(check); location.reload(); } + } catch (e) { /* still restarting */ } + }, 1000); + }, 2000); + } + async function gitCommit() { if (!confirm('Fac commit și push la toate modificările?')) return; showToast('Se execută commit...', 'info');