cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jessicaw...@apache.org
Subject git commit: updated refs/heads/4.2-forward to 7f08333
Date Wed, 18 Sep 2013 23:44:24 GMT
Updated Branches:
  refs/heads/4.2-forward f4066b51f -> 7f08333cc


CLOUDSTACK-4702: UI > Network menu > Add Guest Network dialog > UI shouldn't pass
null zoneid to listnetworkofferings API when zone dropdown is empty (i.e. when no advanced
zone exists).


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

Branch: refs/heads/4.2-forward
Commit: 7f08333cc66f5e13bf66d0c4a086c56c69caf858
Parents: f4066b5
Author: Jessica Wang <jessicawang@apache.org>
Authored: Wed Sep 18 16:43:18 2013 -0700
Committer: Jessica Wang <jessicawang@apache.org>
Committed: Wed Sep 18 16:43:18 2013 -0700

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


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/7f08333c/ui/scripts/sharedFunctions.js
----------------------------------------------------------------------
diff --git a/ui/scripts/sharedFunctions.js b/ui/scripts/sharedFunctions.js
index 16ca41f..5369cee 100644
--- a/ui/scripts/sharedFunctions.js
+++ b/ui/scripts/sharedFunctions.js
@@ -450,7 +450,14 @@ var addGuestNetworkDialog = {
                     label: 'label.network.offering',
                     docID: 'helpGuestNetworkZoneNetworkOffering',
                     dependsOn: ['zoneId', 'scope'],
-                    select: function(args) {
+                    select: function(args) {                    	
+                    	if(args.$form.find('.form-item[rel=zoneId]').find('select').val() ==
null || args.$form.find('.form-item[rel=zoneId]').find('select').val().length == 0) {
+                    		args.response.success({
+                                data: null
+                            });
+                    		return;
+                    	}
+                    	
                         var data = {
                             state: 'Enabled',
                             zoneid: args.$form.find('.form-item[rel=zoneId]').find('select').val()


Mime
View raw message