commit 61e85c6: [Minor] Remove virtual scan time from WebUI history

moisseev moiseev at mezonplus.ru
Fri Jul 19 13:00:05 UTC 2019


Author: moisseev
Date: 2019-07-19 14:07:42 +0300
URL: https://github.com/rspamd/rspamd/commit/61e85c6e7ad7a59b5f29465480a4b0c178ab740d (refs/pull/2988/head)

[Minor] Remove virtual scan time from WebUI history

---
 interface/js/app/history.js | 24 ++++++------------------
 1 file changed, 6 insertions(+), 18 deletions(-)

diff --git a/interface/js/app/history.js b/interface/js/app/history.js
index a3a1d813f..49e228e3a 100644
--- a/interface/js/app/history.js
+++ b/interface/js/app/history.js
@@ -231,13 +231,7 @@ define(["jquery", "footable", "humanize"],
                             sortValue: item.unix_time
                         }
                     };
-                    var scan_time = item.time_real.toFixed(3) + " / " + item.time_virtual.toFixed(3);
-                    item.scan_time = {
-                        options: {
-                            sortValue: item.time_real
-                        },
-                        value: scan_time
-                    };
+                    item.time_real = item.time_real.toFixed(3);
                     item.id = item["message-id"];
 
                     var rcpt = {};
@@ -272,12 +266,6 @@ define(["jquery", "footable", "humanize"],
             $.each(data, function (i, item) {
                 item.time = unix_time_format(item.unix_time);
                 preprocess_item(item);
-                item.scan_time = {
-                    options: {
-                        sortValue: item.scan_time
-                    },
-                    value: item.scan_time
-                };
                 item.symbols = Object.keys(item.symbols)
                     .map(function (key) {
                         return item.symbols[key];
@@ -395,14 +383,14 @@ define(["jquery", "footable", "humanize"],
                 },
                 formatter: Humanize.compactInteger
             }, {
-                name: "scan_time",
-                title: '<span title="real / virtual">Scan time</span>',
+                name: "time_real",
+                title: "Scan time",
                 breakpoints: "xs sm md",
                 style: {
                     "font-size": "11px",
                     "maxWidth": 72
                 },
-                sortValue: function (val) { return Number(val.options.sortValue); }
+                sortValue: function (val) { return Number(val); }
             }, {
                 sorted: true,
                 direction: "DESC",
@@ -484,13 +472,13 @@ define(["jquery", "footable", "humanize"],
                 formatter: Humanize.compactInteger
             }, {
                 name: "scan_time",
-                title: '<span title="real / virtual">Scan time</span>',
+                title: "Scan time",
                 breakpoints: "xs sm",
                 style: {
                     "font-size": "11px",
                     "maxWidth": 80
                 },
-                sortValue: function (val) { return Number(val.options.sortValue); }
+                sortValue: function (val) { return Number(val); }
             }, {
                 sorted: true,
                 direction: "DESC",


More information about the Commits mailing list