[icinga-checkins] icinga.org: icinga-web/master: Fixed pending being listed as ok in some grids (fixes #2472)

git at icinga.org git at icinga.org
Fri Apr 27 11:47:21 CEST 2012


Module: icinga-web
Branch: master
Commit: aec4f22511be3cdbdf26d4b7b69b9324981664a1
URL:    https://git.icinga.org/?p=icinga-web.git;a=commit;h=aec4f22511be3cdbdf26d4b7b69b9324981664a1

Author: Jannis Mosshammer <jannis.mosshammer at netways.de>
Date:   Fri Apr 27 11:45:03 2012 +0200

Fixed pending being listed as ok in some grids (fixes #2472)

---

 .../renderer/AdvancedHostStatusColumnRenderer.js   |    4 ++--
 .../Cronks/lib/js/grid/renderer/ColumnRenderer.js  |    4 ++++
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/app/modules/Cronks/lib/js/grid/renderer/AdvancedHostStatusColumnRenderer.js b/app/modules/Cronks/lib/js/grid/renderer/AdvancedHostStatusColumnRenderer.js
index 3412c1d..d51d02c 100644
--- a/app/modules/Cronks/lib/js/grid/renderer/AdvancedHostStatusColumnRenderer.js
+++ b/app/modules/Cronks/lib/js/grid/renderer/AdvancedHostStatusColumnRenderer.js
@@ -112,8 +112,8 @@ Cronk.grid.AdvancedHostStatusColumnRenderer = new (function () {
     **/
     this.hostStatus = function() {
     	return function(value, metaData, record, rowIndex, colIndex, store) {
-			if(Ext.isDefined(record.json.host_is_pending)) {
-				if(record.json.host_is_pending > 0)
+			if(Ext.isDefined(record.json.host_has_been_checked)) {
+				if(record.json.host_has_been_checked == 0)
 					value=99;
 			}
 			if(!Ext.isDefined(value))
diff --git a/app/modules/Cronks/lib/js/grid/renderer/ColumnRenderer.js b/app/modules/Cronks/lib/js/grid/renderer/ColumnRenderer.js
index cb4fe0b..f657168 100755
--- a/app/modules/Cronks/lib/js/grid/renderer/ColumnRenderer.js
+++ b/app/modules/Cronks/lib/js/grid/renderer/ColumnRenderer.js
@@ -246,6 +246,10 @@ Ext.ns('Cronk.grid');
                         if (record.json.host_is_pending > 0) {
                             value = 99;
                         }
+                    } else if (Ext.isDefined(record.json.host_has_been_checked)) {
+                        if (record.json.host_has_been_checked == 0) {
+                            value = 99;
+                        }
                     }
                     if (!Ext.isDefined(value)) {
                         return "";





More information about the icinga-checkins mailing list