Switch to using a common directive for user setup (sign in, sign up, recover account) everywhere
This commit is contained in:
parent
abe6db334d
commit
9dbbd33afc
6 changed files with 105 additions and 87 deletions
|
@ -16,16 +16,6 @@ $.fn.clipboardCopy = function() {
|
|||
};
|
||||
|
||||
function SigninCtrl($scope, $location, $timeout, Restangular, KeyService, UserService) {
|
||||
$scope.sendRecovery = function() {
|
||||
var signinPost = Restangular.one('recovery');
|
||||
signinPost.customPOST($scope.recovery).then(function() {
|
||||
$scope.invalidEmail = false;
|
||||
$scope.sent = true;
|
||||
}, function(result) {
|
||||
$scope.invalidEmail = true;
|
||||
$scope.sent = false;
|
||||
});
|
||||
};
|
||||
};
|
||||
|
||||
function PlansCtrl($scope, $location, UserService, PlanService) {
|
||||
|
@ -40,8 +30,11 @@ function PlansCtrl($scope, $location, UserService, PlanService) {
|
|||
|
||||
$scope.signedIn = function() {
|
||||
$('#signinModal').modal('hide');
|
||||
PlanService.handleNotedPlan();
|
||||
|
||||
PlanService.handleNotedPlan();
|
||||
};
|
||||
|
||||
$scope.cancelNotedPlan = function() {
|
||||
PlanService.notePlan('');
|
||||
};
|
||||
|
||||
$scope.buyNow = function(plan) {
|
||||
|
|
Reference in a new issue