diff --git a/api/admin/perf-dashboard.cfm b/api/admin/perf-dashboard.cfm index 498b00a..c89fa7e 100644 --- a/api/admin/perf-dashboard.cfm +++ b/api/admin/perf-dashboard.cfm @@ -129,6 +129,12 @@ let refreshTimer = null; function qs(s) { return document.querySelector(s); } function fmt(n) { return n == null ? '-' : Number(n).toLocaleString(); } +function fmtDate(s) { + if (!s || s === 'none') return 'none'; + var d = new Date(s.replace(' ', 'T')); + if (isNaN(d)) return s; + return d.toLocaleDateString('en-US', { month: 'short', day: 'numeric', year: 'numeric' }) + ' ' + d.toLocaleTimeString('en-US', { hour: 'numeric', minute: '2-digit', hour12: true }); +} function fmtMs(n) { if (n == null) return '-'; n = Number(n); @@ -191,7 +197,7 @@ async function loadAll() { card('Avg DB Time', s.OverallAvgDbMs || 0, 'ms') + card('Avg App Time', s.OverallAvgAppMs || 0, 'ms') + card('Avg Queries', s.OverallAvgQueries || 0, '/req') + - card('Data Since', s.FirstLog || 'none', ''); + card('Data Since', fmtDate(s.FirstLog), ''); qs('#summarySection').style.display = ''; // Count table