From a2cfd0c8cea18861ad20f7eb535a98394f9239ff Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Wed, 13 Jul 2016 16:59:21 +0200 Subject: [statistics] Change delimiter to something more unusual, add captions for filter options --- .../statistics/templates/clientlist.html | 74 ++++++++++++++-------- 1 file changed, 47 insertions(+), 27 deletions(-) (limited to 'modules-available/statistics/templates') diff --git a/modules-available/statistics/templates/clientlist.html b/modules-available/statistics/templates/clientlist.html index 1ec3a143..57ec7f64 100644 --- a/modules-available/statistics/templates/clientlist.html +++ b/modules-available/statistics/templates/clientlist.html @@ -16,7 +16,7 @@ - @@ -30,7 +30,6 @@
- @@ -137,16 +136,28 @@ var filterSelectize; -document.addEventListener("DOMContentLoaded", function () { +var slxFilterNames = { + machineuuid: '{{lang_uuid}}', + macaddr: '{{lang_macAddr}}', + firstseen: '{{lang_firstSeen}}', + lastseen: '{{lang_lastSeen}}', + lastboot: '{{lang_lastBoot}}', + logintime: '{{lang_lastLogin}}', + realcores: '{{lang_cores}}', + systemmodel: '{{lang_model}}', + cpumodel: '{{lang_cpuModel}}', + hddgb: '{{lang_tmpGb}}', + gbram: '{{lang_gbRam}}', + kvmstate: '{{lang_kvmSupport}}', + badsectors: '{{lang_reallocatedSectors}}', + clientip: '{{lang_ip}}', + state: '{{lang_usageState}}' +}; + +var slxFilterDel = '{{delimiter}}'; - var initComplete = false; - var comp = ['=', '!=']; - var ordered = ['<', '<=', '=', '>=', '>']; - // var filter = { - // 'machine' : {'op' : comp, 'type' : 'string'}, - // 'ram' : {'op' : ordered, 'type' : 'string'}, - // 'lastSeen' : {'op' : ordered, 'type' : 'date'}, - // }; + +document.addEventListener("DOMContentLoaded", function () { /* some objects */ var $columnSelect = $('#columnSelect'); @@ -158,13 +169,13 @@ document.addEventListener("DOMContentLoaded", function () { /* add options to column select */ for (var key in columns) { $columnSelect.append($('