Skip to content

Commit

Permalink
default load_1 show
Browse files Browse the repository at this point in the history
  • Loading branch information
ubuntu committed Feb 1, 2019
1 parent cee65ee commit 039a2cc
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions web/js/serverstatus.js
Original file line number Diff line number Diff line change
Expand Up @@ -185,17 +185,11 @@ function uptime() {
// Uptime
TableRow.children["uptime"].innerHTML = result.servers[i].uptime;

// Load
// Load: default load_1, you can change show: load_1, load_5, load_15
if(result.servers[i].load == -1) {
TableRow.children["load"].innerHTML = "–";
} else {
var loadstr = ""
loadstr += result.servers[i].load_1.toFixed(2);
loadstr += " | "
loadstr += result.servers[i].load_5.toFixed(2);
loadstr += " | "
loadstr += result.servers[i].load_15.toFixed(2);
TableRow.children["load"].innerHTML = loadstr
TableRow.children["load"].innerHTML = result.servers[i].load_1.toFixed(2);
}

// Network
Expand Down

0 comments on commit 039a2cc

Please sign in to comment.