Syncing up the email addresses between the SpreeUser tabs

This commit is contained in:
Will Marshall
2014-03-27 16:17:51 +11:00
parent d8160bc6d5
commit 54491e0de2
5 changed files with 12 additions and 11 deletions

View File

@@ -1,7 +1,5 @@
window.ForgotSidebarCtrl = Darkswarm.controller "ForgotSidebarCtrl", ($scope, $http, $location) ->
$scope.spree_user = {
email: null
}
window.ForgotSidebarCtrl = Darkswarm.controller "ForgotSidebarCtrl", ($scope, $http, $location, SpreeUser) ->
$scope.spree_user = SpreeUser.spree_user
$scope.active = ->
$location.path() == '/forgot'

View File

@@ -1,7 +1,5 @@
window.LoginSidebarCtrl = Darkswarm.controller "LoginSidebarCtrl", ($scope, $http, $location) ->
$scope.spree_user = {
remember_me: 0
}
window.LoginSidebarCtrl = Darkswarm.controller "LoginSidebarCtrl", ($scope, $http, $location, SpreeUser) ->
$scope.spree_user = SpreeUser.spree_user
$scope.active = ->
$location.path() == '/login'

View File

@@ -1,5 +1,5 @@
window.SignupSidebarCtrl = Darkswarm.controller "SignupSidebarCtrl", ($scope, $http, $location) ->
$scope.spree_user = {}
window.SignupSidebarCtrl = Darkswarm.controller "SignupSidebarCtrl", ($scope, $http, $location, SpreeUser) ->
$scope.spree_user = SpreeUser.spree_user
$scope.errors =
email: null
password: null

View File

@@ -0,0 +1,6 @@
Darkswarm.factory 'SpreeUser', ($resource) ->
new class SpreeUser
spree_user: {
remember_me: 0
email: null
}