Module: check_mk
Branch: master
Commit: c9ac411584132f5b87d89c58b2f2d4519884a1ad
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=c9ac411584132f…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Mon Oct 1 11:29:35 2012 +0200
FIX: BI: Assuming "OK" for hosts is now possible
---
.bugs/779 | 7 +++++--
ChangeLog | 1 +
web/htdocs/js/bi.js | 8 +++++---
3 files changed, 11 insertions(+), 5 deletions(-)
diff --git a/.bugs/779 b/.bugs/779
index e6dd858..c37ddfb 100644
--- a/.bugs/779
+++ b/.bugs/779
@@ -1,9 +1,12 @@
Title: BI cannot assume UP host state
Component: bi
-State: open
+Class: bug
+State: done
Date: 2012-06-26 17:54:41
Targetversion: 1.2.0
-Class: bug
You can assume OK as service state but not UP
as host state (just DOWN and UNREACH).
+
+2012-10-01 11:29:28: changed state open -> done
+Has just been fixed.
diff --git a/ChangeLog b/ChangeLog
index db3f7e0..b879144 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -21,6 +21,7 @@
1.2.0p3:
Mulitisite
* Added "view" parameter to dashlet_pnpgraph webservice
+ * FIX: BI: Assuming "OK" for hosts is now possible
WATO
* Added "profile" option to be configurable via browser
diff --git a/web/htdocs/js/bi.js b/web/htdocs/js/bi.js
index 345001a..334de7e 100644
--- a/web/htdocs/js/bi.js
+++ b/web/htdocs/js/bi.js
@@ -87,14 +87,16 @@ function toggle_assumption(oImg, site, host, service)
current = current.substr(7);
current = current.substr(0, current.length - 4);
if (current == 'none')
+ // Assume WARN when nothing assumed yet
current = '1';
- else if (current == '3')
+ else if (current == '3' || (service == '' && current ==
'2'))
+ // Assume OK when unknown assumed (or when critical assumed for host)
current = '0'
else if (current == '0')
- current = 'none'
- else if (current == '2' && service == '')
+ // Disable assumption when ok assumed
current = 'none'
else
+ // In all other cases increas the assumption
current = parseInt(current) + 1;
var url = "bi_set_assumption.py?site=" + encodeURIComponent(site)