From f0c0b273299432883ca9630ebc13945247137e75 Mon Sep 17 00:00:00 2001 From: David Baldwynn Date: Wed, 29 Jul 2015 10:53:22 -0700 Subject: [PATCH] got email verification to work --- bower.json | 3 ++- public/dist/application.js | 34 +++++++++++++++++++++------------- 2 files changed, 23 insertions(+), 14 deletions(-) diff --git a/bower.json b/bower.json index f348ff5e..cc0af266 100755 --- a/bower.json +++ b/bower.json @@ -27,7 +27,8 @@ "lodash": "~3.10.0", "angular-ui-sortable": "~0.13.4", "angular-busy": "~4.1.3", - "angular-permission": "~0.3.1" + "angular-permission": "~0.3.1", + "angular-input-stars": "*" }, "resolutions": { "angular": "~1.3.17" diff --git a/public/dist/application.js b/public/dist/application.js index 717a0754..5f93f0ab 100644 --- a/public/dist/application.js +++ b/public/dist/application.js @@ -113,7 +113,7 @@ ApplicationConfiguration.registerModule('core', ['users']); 'use strict'; // Use Application configuration module to register a new module -ApplicationConfiguration.registerModule('forms', ['ngFileUpload', 'ui.date', 'ui.sortable', 'users']); +ApplicationConfiguration.registerModule('forms', ['ngFileUpload', 'ui.date', 'ui.sortable', 'angular-input-stars', 'users']); 'use strict'; // Use Application configuration module to register a new module @@ -1180,7 +1180,8 @@ angular.module('forms').directive('fieldDirective', function($http, $compile) { 'hidden', 'password', 'radio', - 'legal' + 'legal', + 'statement' ]; if (__indexOf.call(supported_fields, type) >= 0) { return templateUrl += type + '.html'; @@ -1375,6 +1376,10 @@ angular.module('forms').service('FormFields', [ name : 'checkbox', value : 'Checkbox' }, + { + name : 'yes-no', + value : 'Yes or No' + }, { name : 'legal', value : 'Legal' @@ -1383,14 +1388,14 @@ angular.module('forms').service('FormFields', [ // name : 'file', // value : 'File Upload' // }, - // { - // name : 'rating', - // value : 'Rating' - // }, - // { - // name : 'link', - // value : 'Link' - // }, + { + name : 'rating', + value : 'Rating' + }, + { + name : 'link', + value : 'Link' + }, // { // name : 'scale', // value : 'Opinion Scale' @@ -1789,10 +1794,13 @@ angular.module('users').controller('VerifyController', ['$scope', '$state', '$ro } $scope.isReset = false; + $scope.credentials = {}; + // Submit forgotten password account id $scope.resendVerifyEmail = function() { - User.resendVerifyEmail($scope.email).then( + console.log($scope.credentials.email); + User.resendVerifyEmail($scope.credentials.email).then( function(response){ $scope.success = response.message; $scope.credentials = null; @@ -1985,9 +1993,9 @@ angular.module('users').factory('User', ['$window', '$q', '$timeout', '$http', ' return deferred.promise; }, - resendVerifyEmail: function(email) { + resendVerifyEmail: function(_email) { var deferred = $q.defer(); - $http.post('/auth/verify/', {email: email}).success(function(response) { + $http.post('/auth/verify/', {email: _email}).success(function(response) { deferred.resolve(response); }).error(function(error) { deferred.reject(error.message || error);