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/master to 723ef6e
Date Wed, 18 Sep 2013 23:45:10 GMT
Updated Branches:
  refs/heads/master 3ab8d8d8f -> 723ef6e49


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/723ef6e4
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/723ef6e4
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/723ef6e4

Branch: refs/heads/master
Commit: 723ef6e49552f7407194b701927a0b2a167a4ced
Parents: 3ab8d8d
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:45:01 2013 -0700

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


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/723ef6e4/ui/scripts/sharedFunctions.js
----------------------------------------------------------------------
diff --git a/ui/scripts/sharedFunctions.js b/ui/scripts/sharedFunctions.js
index b6a1c1f..1596973 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