diff --git a/app/templates/ajax/alerts_history.html b/app/templates/ajax/alerts_history.html index 94c3abcf..0bfe105e 100644 --- a/app/templates/ajax/alerts_history.html +++ b/app/templates/ajax/alerts_history.html @@ -22,30 +22,17 @@ } ); - - - - - {% if action != "checker_history" %} - - {% endif %} - - - - + + + + {% if action != "checker_history" %} + + {% endif %} + + + + {% if smon != '' %} @@ -59,27 +46,18 @@ {% endif %} {{t.1 |upper}} - + {% if action != "checker_history" %} - + {% endif %} - - - + + {% endfor %} {% else %} Table is empty {% endif %} -
- Level - - Host - - Port - - Alert - - Date - - Time -
LevelHostPortAlertDateTime
- {{t.2}} - {{t.2}} - {{t.3}} - {{t.3}} - {{t.0}} - - {{t.4.split(' ')[0]}} - - {{t.4.split(' ')[1]}} + {{t.0}}{{t.4.split(' ')[0]}} {{t.4.split(' ')[1]}}
+ \ No newline at end of file diff --git a/app/templates/ajax/bin_bout.html b/app/templates/ajax/bin_bout.html index dde6befb..94769091 100644 --- a/app/templates/ajax/bin_bout.html +++ b/app/templates/ajax/bin_bout.html @@ -1,7 +1,8 @@ +{% if service != 'nginx' %}
Bytes in - + @@ -37,9 +38,17 @@ {{total|round(2)}} {{metric}}
+{% endif %}
Current ses + {% if service == 'nginx' %} + + + + + + {% endif %}
{{bin_bout.2}} diff --git a/app/templates/ajax/check_version.html b/app/templates/ajax/check_version.html index 47c676f0..c786204d 100644 --- a/app/templates/ajax/check_version.html +++ b/app/templates/ajax/check_version.html @@ -8,6 +8,7 @@ {% if new_ver_without_dots > current_ver_without_dots and new_ver != "Sorry cannot get current version" %} v{{current_ver}} + {% else %} v{{current_ver}} {% endif %} diff --git a/inc/script.js b/inc/script.js index cf305cbe..acf4209c 100644 --- a/inc/script.js +++ b/inc/script.js @@ -622,6 +622,32 @@ function viewLogs() { } } $( function() { + $.ajax( { + url: "options.py", + data: { + show_versions: 1, + token: $('#token').val() + }, + type: "POST", + success: function( data ) { + $('#version').html(data); + var showUpdates = $( "#show-updates" ).dialog({ + autoOpen: false, + width: 600, + modal: true, + title: 'There is a new version HAProxy-WI', + buttons: { + Close: function() { + $( this ).dialog( "close" ); + clearTips(); + } + } + }); + $('#show-updates-button').click(function() { + showUpdates.dialog('open'); + }); + } + } ); $('a').click(function(e) { try { var cur_path = window.location.pathname; @@ -838,33 +864,6 @@ $( function() { } return false; }); - $.ajax( { - url: "options.py", - data: { - show_versions: 1, - token: $('#token').val() - }, - type: "POST", - success: function( data ) { - $('#version').html(data); - } - } ); - var showUpdates = $( "#show-updates" ).dialog({ - autoOpen: false, - width: 600, - modal: true, - title: 'There is a new version HAProxy-WI', - buttons: { - Close: function() { - $( this ).dialog( "close" ); - clearTips(); - } - } - }); - - $('#show-updates-button').click(function() { - showUpdates.dialog('open'); - }); var showUserSettings = $( "#show-user-settings" ).dialog({ autoOpen: false, width: 600, @@ -955,6 +954,7 @@ $( function() { $(this).children(".services").css('padding-left', '30px'); $(this).children(".services").css('border-left', '4px solid #5D9CEB'); }); + loadServices(); $( "#tabs" ).tabs( "option", "active", 7 ); } ); $( ".updatehapwi" ).on( "click", function() { @@ -965,6 +965,7 @@ $( function() { $(this).children(".updatehapwi").css('border-left', '4px solid #5D9CEB'); }); $( "#tabs" ).tabs( "option", "active", 8 ); + loadupdatehapwi(); } ); } else { $( ".runtime" ).on( "click", function() {