You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by je...@apache.org on 2012/08/08 19:37:00 UTC
[1/2] git commit: cloudstack 3.0 UI - autoscale - existing LB -
configure AutoScale - fix a JS bug "otherdeployparams is undefined".
Updated Branches:
refs/heads/autoscale 92ff9b03e -> 383884137
cloudstack 3.0 UI - autoscale - existing LB - configure AutoScale - fix a JS bug "otherdeployparams is undefined".
Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/38388413
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/38388413
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/38388413
Branch: refs/heads/autoscale
Commit: 3838841378c86a53ee42bf3c87f2ac4a709a58a0
Parents: 16046e2
Author: Jessica Wang <je...@citrix.com>
Authored: Tue Aug 7 14:09:40 2012 -0700
Committer: Jessica Wang <je...@citrix.com>
Committed: Wed Aug 8 10:36:08 2012 -0700
----------------------------------------------------------------------
ui/scripts/autoscaler.js | 20 +++++++++++---------
1 files changed, 11 insertions(+), 9 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/38388413/ui/scripts/autoscaler.js
----------------------------------------------------------------------
diff --git a/ui/scripts/autoscaler.js b/ui/scripts/autoscaler.js
index 8967d6a..37bb806 100644
--- a/ui/scripts/autoscaler.js
+++ b/ui/scripts/autoscaler.js
@@ -142,15 +142,17 @@
var diskOfferingId, securityGroups;
var otherdeployparams = autoscaleVmProfile.otherdeployparams;
- var array1 = otherdeployparams.split('&');
- $(array1).each(function(){
- var array2 = this.split('=');
- if(array2[0] == 'diskofferingid')
- diskOfferingId= array2[1];
- if(array2[0] == 'securitygroupids')
- securityGroups = array2[1];
- });
-
+ if(otherdeployparams != null && otherdeployparams.length > 0) {
+ var array1 = otherdeployparams.split('&');
+ $(array1).each(function(){
+ var array2 = this.split('=');
+ if(array2[0] == 'diskofferingid')
+ diskOfferingId= array2[1];
+ if(array2[0] == 'securitygroupids')
+ securityGroups = array2[1];
+ });
+ }
+
var originalAutoscaleData = {
templateNames: autoscaleVmProfile.templateid,
serviceOfferingId: autoscaleVmProfile.serviceofferingid,