[icinga-checkins] icinga.org: icinga-web/next: Icinga-Web Downtime Bug

git at icinga.org git at icinga.org
Thu Apr 11 11:29:13 CEST 2013


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

Author: Marius Hein <marius.hein at netways.de>
Date:   Thu Apr 11 11:27:40 2013 +0200

Icinga-Web Downtime Bug

Fix toggle handler for downtime command handler. Applies patch
from max, thank for that.

fixes #3719

---

 .../Cronks/lib/js/Cronk/grid/CommandHandler.js     |    8 ++++----
 doc/THANKS                                         |    1 +
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/app/modules/Cronks/lib/js/Cronk/grid/CommandHandler.js b/app/modules/Cronks/lib/js/Cronk/grid/CommandHandler.js
index ab9ad66..a79f85c 100644
--- a/app/modules/Cronks/lib/js/Cronk/grid/CommandHandler.js
+++ b/app/modules/Cronks/lib/js/Cronk/grid/CommandHandler.js
@@ -206,14 +206,14 @@ Ext.ns('Cronk.grid');
                         inputValue: 1,
                         columnWidth: 0.5,
                         name: o.fieldName,
-                        checked: o.fieldValue === "true"
+                        checked: o.fieldValue !== "true"
                     }, {
                         xtype: 'radio',
                         boxLabel: _('No'),
                         inputValue: 0,
                         name: o.fieldName,
                         columnWidth: 0.5,
-                        checked: o.fieldValue !== "true"
+                        checked: o.fieldValue === "true"
                     }]
                 });
                 if (o.fieldName === "fixed") {
@@ -227,8 +227,8 @@ Ext.ns('Cronk.grid');
                                     var m = form.getForm().findField(affectedForms[i]);
 
                                     if (m) {
-                                        m.setReadOnly((checkedBox.initialConfig.boxLabel === _('Yes')) ? !val : val);
-                                        m.container.setVisible((checkedBox.initialConfig.boxLabel === _('Yes')) ? val : !val);
+                                        m.setReadOnly((checkedBox.initialConfig.boxLabel === _('No')) ? !val : val);
+                                        m.container.setVisible((checkedBox.initialConfig.boxLabel === _('No')) ? val : !val);
                                     }
                                 }
                             }
diff --git a/doc/THANKS b/doc/THANKS
index cef39c6..d101d4d 100644
--- a/doc/THANKS
+++ b/doc/THANKS
@@ -30,6 +30,7 @@ name, please let us know.
     * Philipp Deneu
     * abraxas
     * Thorsten Fohrer
+    * Max Stephan
 
 * Design stuff
     * Karolina Hein





More information about the icinga-checkins mailing list