Skip to content

Commit

Permalink
Fix for: hostgroup display, refresh link
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikWegner committed Jul 23, 2015
1 parent e8514c7 commit 8756edc
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
8 changes: 3 additions & 5 deletions data/panel.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ function renderServiceTemplate(servicedata) {

span = document.createElement("span");
span.setAttribute("class", "actions");
span.setAttribute("data-hostname", servicedata.hostname);
span.setAttribute("data-hostname", servicedata.host_name);
span.setAttribute("data-servicename", servicedata.service_description);
span.appendChild(ackimg.cloneNode(true));
span.appendChild(document.createTextNode(" "));
Expand Down Expand Up @@ -255,7 +255,6 @@ function renderMainTemplate() {

// list 3
hostdetail.servicesdata = all_serviceshtml;
debugger
html3.appendChild(renderHostTemplate(hostdetail));
}

Expand All @@ -272,14 +271,13 @@ function renderMainTemplate() {
var r = document.createElement("div");
r.setAttribute("style", "text-align:center");

var p, a, div1, table, tr, th, td, input, label;
var p, a, div1, table, tr, th, td;
r.appendChild(p = document.createElement("p"));
p.appendChild(a = document.createElement("a"));
a.setAttribute("class", "refresh");
a.setAttribute("href", "javascript:void(0);");
a.appendChild(document.createTextNode("↺ Refresh"));
p.appendChild(a);
if (statusdata.hostgroupinfo !== null && statusdata.hostgroupinfo !== "") p.appendChild(" " + statusdata.hostgroupinfo);
if (statusdata.hostgroupinfo !== null && statusdata.hostgroupinfo !== "") p.appendChild(document.createTextNode(" " + statusdata.hostgroupinfo));

r.appendChild(div1 = document.createElement("div"));

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"title": "Path to icinga/nagios",
"description": "Complete path to cgi-bin/, e.g. https://www.examle.com/icinga/cgi-bin/",
"type": "string",
"value": "http://localhost:1080/"
"value": ""
},{
"name": "extensions.imoin.updateinterval",
"title": "Refresh interval",
Expand Down Expand Up @@ -49,5 +49,5 @@
"icon64": "data/icon-64.png",
"author": "Erik Wegner",
"license": "MPL 2.0",
"version": "9"
"version": "10"
}

0 comments on commit 8756edc

Please sign in to comment.