From daebdc20c871689e971d058cb3a8cddc8a24c8fb Mon Sep 17 00:00:00 2001 From: Heikki Hannikainen Date: Fri, 26 Oct 2012 08:39:38 +0300 Subject: [PATCH] web: display additional dupecheck thread counters --- src/web/aprsc.css | 10 ++++++++++ src/web/aprsc.js | 20 +++++++++++++++++++- src/web/index.html | 3 ++- 3 files changed, 31 insertions(+), 2 deletions(-) diff --git a/src/web/aprsc.css b/src/web/aprsc.css index 6221586..05e9c59 100644 --- a/src/web/aprsc.css +++ b/src/web/aprsc.css @@ -9,6 +9,10 @@ body { .red { color: #ff5370; } .rxerr { color: #0000ff; cursor: pointer; } .rxerr_red { color: #ff5370; cursor: pointer; } +.link { color: #0000ff; cursor: pointer; } +/* show/hide buttons */ +.show { color: #0000ff; cursor: pointer; } +.hide { color: #0000ff; cursor: pointer; display: none; } div.page_title { color: #000; @@ -84,3 +88,9 @@ div.ttip { display: none; } +/* specific tables */ + +div#dupecheck_more { + display: none; + margin-left: 20px; +} diff --git a/src/web/aprsc.js b/src/web/aprsc.js index 16a55c4..68cc400 100644 --- a/src/web/aprsc.js +++ b/src/web/aprsc.js @@ -158,7 +158,8 @@ function conv_none(s) return s; } -var listeners_table, uplinks_table, peers_table, clients_table, memory_table, dupecheck_table, totals_table; +var listeners_table, uplinks_table, peers_table, clients_table, memory_table, + dupecheck_table, dupecheck_more_table, totals_table; var rx_err_strings = { "unknown": 'Unknown error', @@ -194,6 +195,13 @@ var key_translate = { 'dupes_dropped': 'Duplicate packets dropped', 'uniques_out': 'Unique packets seen', + // dupecheck_more (variations) block + 'exact': 'Exact duplicates', + 'space_trim': 'Dupes with spaces trimmed from end', + '8bit_strip': 'Dupes with 8-bit chars stripped out', + '8bit_clear': 'Dupes with 8th bit set to 0', + '8bit_spaced': 'Dupes with 8-bit characters replaced with spaces', + // totals block 'clients': 'Clients', 'connects': 'Connects', @@ -626,6 +634,8 @@ function render(d) u['dupes_dropped'] = calc_rate('dupecheck.dupes_dropped', u['dupes_dropped']); u['uniques_out'] = calc_rate('dupecheck.uniques_out', u['uniques_out']); render_block('dupecheck', dupecheck_table, u); + if (u['variations']) + render_block(0, dupecheck_more_table, u['variations']); } if (d['totals']) { @@ -815,6 +825,13 @@ function gr_switch(id) load_graph(); } +function toggle(id) +{ + $('#' + id + '_show').toggle(100); + $('#' + id + '_hide').toggle(100); + $('#' + id).toggle(200); +} + function init() { listeners_table = $('#listeners'); @@ -823,6 +840,7 @@ function init() clients_table = $('#clients'); memory_table = $('#memory'); dupecheck_table = $('#dupecheck'); + dupecheck_more_table = $('#dupecheck_more'); totals_table = $('#totals'); server_table = $('#server'); diff --git a/src/web/index.html b/src/web/index.html index 46d6105..8d7df50 100644 --- a/src/web/index.html +++ b/src/web/index.html @@ -22,8 +22,9 @@
-

Duplicate filter

+

Duplicate filter +-

+

Port listeners