You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by an...@apache.org on 2013/10/03 08:06:02 UTC
[04/50] git commit: updated refs/heads/4.2 to 86c9363
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
Commit: 7f08333cc66f5e13bf66d0c4a086c56c69caf858
Parents: f4066b5
Author: Jessica Wang <je...@apache.org>
Authored: Wed Sep 18 16:43:18 2013 -0700
Committer: Jessica Wang <je...@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()