]> source.dussan.org Git - rspamd.git/commitdiff
[WebUI] Highlight uptime of restarted servers 3466/head
authormoisseev <moiseev@mezonplus.ru>
Sun, 9 Aug 2020 14:50:13 +0000 (17:50 +0300)
committermoisseev <moiseev@mezonplus.ru>
Sun, 9 Aug 2020 14:50:13 +0000 (17:50 +0300)
interface/css/rspamd.css
interface/js/app/stats.js

index 6394e449c798d46659b5b7381111f220a52313c1..51a1bb85b5ce6027c763d1ff6c904c958a0f3b7d 100644 (file)
@@ -57,6 +57,9 @@ small,
 .success > td {
     background-color: #eef9e7;
 }
+td.warning {
+    background-color: #fff8e6;
+}
 
 /* bootstrap 4 additionals */
 .btn-group-xs > .btn,
index 38578866e760d4b7ba87919b301d6997826eb3ec..ea1919af514d65aa953eabb47ea5e7efc4c79d77 100644 (file)
@@ -128,7 +128,9 @@ define(["jquery", "d3pie"],
                 "<td>" + key + "</td>" +
                 "<td>" + val.host + "</td>" +
                 '<td class="text-center"><span class="icon"><i class="' + glyph_status + '"></i></span></td>' +
-                '<td class="text-right">' + uptime + "</td>" +
+                '<td class="text-right' +
+                  (val.data.uptime < 3600 ? ' warning" title="Has been restarted within the last hour"' : "") +
+                  '">' + uptime + "</td>" +
                 "<td>" + version + "</td>" +
                 "<td>" + short_id + "</td></tr>");