cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wid...@apache.org
Subject [4/5] git commit: updated refs/heads/statscollector-graphite to 38cb7f5
Date Tue, 30 Sep 2014 09:01:55 GMT
CLOUDSTACK-7647: Fix 'isReverse' checkboxes which are checked by default


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/ef4b5d41
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/ef4b5d41
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/ef4b5d41

Branch: refs/heads/statscollector-graphite
Commit: ef4b5d41b7dd9ba16afd04c7716bada4a4721f79
Parents: 055fdd5
Author: Brian Federle <brian.federle@citrix.com>
Authored: Mon Sep 29 12:58:40 2014 -0700
Committer: Brian Federle <brian.federle@citrix.com>
Committed: Mon Sep 29 12:58:40 2014 -0700

----------------------------------------------------------------------
 ui/scripts/ui/dialog.js | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ef4b5d41/ui/scripts/ui/dialog.js
----------------------------------------------------------------------
diff --git a/ui/scripts/ui/dialog.js b/ui/scripts/ui/dialog.js
index 950d596..2bd0797 100644
--- a/ui/scripts/ui/dialog.js
+++ b/ui/scripts/ui/dialog.js
@@ -225,8 +225,11 @@
                     if ($dependsOn.is('[type=checkbox]')) {
                         
                         var isReverse = false;
-                        if (args.form.fields[dependsOn])
+                        if (args.form.fields[dependsOn]) {
                             isReverse = args.form.fields[dependsOn].isReverse;
+                            isChecked = args.form.fields[dependsOn].isChecked;
+                        }
+
 
                         // Checkbox
                         $dependsOn.bind('click', function(event) {
@@ -260,6 +263,10 @@
                         // Show fields by default if it is reverse checkbox
                         if (isReverse) {
                             $dependsOn.click();
+
+                            if (isChecked) {
+                                $dependsOn.attr('checked', true);
+                            }
                         }
                     }
                 }


Mime
View raw message