diff --git a/static/js/controllers.js b/static/js/controllers.js index ff7d4e354..ad97a6042 100644 --- a/static/js/controllers.js +++ b/static/js/controllers.js @@ -2335,10 +2335,10 @@ function NewOrgCtrl($scope, $routeParams, $timeout, $location, UserService, Plan // Load the list of plans. PlanService.getPlans(function(plans) { $scope.plans = plans; - $scope.currentPlan = null; + $scope.holder.currentPlan = null; if (requested) { PlanService.getPlan(requested, function(plan) { - $scope.currentPlan = plan; + $scope.holder.currentPlan = plan; }); } }); @@ -2359,7 +2359,7 @@ function NewOrgCtrl($scope, $routeParams, $timeout, $location, UserService, Plan }; $scope.setPlan = function(plan) { - $scope.currentPlan = plan; + $scope.holder.currentPlan = plan; }; $scope.createNewOrg = function() { @@ -2387,7 +2387,7 @@ function NewOrgCtrl($scope, $routeParams, $timeout, $location, UserService, Plan }; // If the selected plan is free, simply move to the org page. - if (!Features.BILLING || $scope.currentPlan.price == 0) { + if (!Features.BILLING || $scope.holder.currentPlan.price == 0) { showOrg(); return; } @@ -2401,7 +2401,7 @@ function NewOrgCtrl($scope, $routeParams, $timeout, $location, UserService, Plan 'failure': showOrg }; - PlanService.changePlan($scope, org.name, $scope.currentPlan.stripeId, callbacks); + PlanService.changePlan($scope, org.name, $scope.holder.currentPlan.stripeId, callbacks); }, function(result) { $scope.creating = false; $scope.createError = result.data.message || result.data;