mirror of
https://github.com/ail-project/ail-framework.git
synced 2024-11-27 00:07:16 +00:00
Javascript modification dashboard log table
This commit is contained in:
parent
12dd16daf9
commit
7cf05f959d
1 changed files with 13 additions and 1 deletions
|
@ -39,6 +39,9 @@ function create_log_table(obj_json) {
|
||||||
else if ( chansplit[1] == "WARNING" ){
|
else if ( chansplit[1] == "WARNING" ){
|
||||||
tr.className = "warning";
|
tr.className = "warning";
|
||||||
}
|
}
|
||||||
|
else if ( chansplit[1] == "CRITICAL"){
|
||||||
|
tr.className = "critical"
|
||||||
|
}
|
||||||
|
|
||||||
source_link = document.createElement("A");
|
source_link = document.createElement("A");
|
||||||
if (parsedmess[1] == "slexy.org"){
|
if (parsedmess[1] == "slexy.org"){
|
||||||
|
@ -70,8 +73,17 @@ function create_log_table(obj_json) {
|
||||||
tr.appendChild(nam);
|
tr.appendChild(nam);
|
||||||
tr.appendChild(msage);
|
tr.appendChild(msage);
|
||||||
|
|
||||||
var sel = document.getElementById("log_select")
|
if (tr.className == document.getElementById("checkbox_log_info").value && document.getElementById("checkbox_log_info").checked == true) {
|
||||||
tableBody.appendChild(tr);
|
tableBody.appendChild(tr);
|
||||||
|
}
|
||||||
|
if (tr.className == document.getElementById("checkbox_log_warning").value && document.getElementById("checkbox_log_warning").checked == true) {
|
||||||
|
tableBody.appendChild(tr);
|
||||||
|
}
|
||||||
|
if (tr.className == document.getElementById("checkbox_log_critical").value && document.getElementById("checkbox_log_critical").checked == true) {
|
||||||
|
tableBody.appendChild(tr);
|
||||||
|
};
|
||||||
|
|
||||||
|
var sel = document.getElementById("log_select")
|
||||||
if (tableBody.rows.length > sel.options[sel.options.selectedIndex].value){
|
if (tableBody.rows.length > sel.options[sel.options.selectedIndex].value){
|
||||||
while (tableBody.rows.length != sel.options[sel.options.selectedIndex].value){
|
while (tableBody.rows.length != sel.options[sel.options.selectedIndex].value){
|
||||||
tableBody.deleteRow(0);
|
tableBody.deleteRow(0);
|
||||||
|
|
Loading…
Reference in a new issue