mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-13 04:00:21 +00:00
Show confirmation message in modal
This commit is contained in:
committed by
Maikel Linke
parent
bc621a3c43
commit
595bc5d1a5
@@ -1,4 +1,4 @@
|
||||
Darkswarm.controller "LoginCtrl", ($scope, $http, $window, AuthenticationService, Redirections, Loading) ->
|
||||
Darkswarm.controller "LoginCtrl", ($scope, $timeout, $location, $http, $window, AuthenticationService, Redirections, Loading) ->
|
||||
$scope.path = "/login"
|
||||
|
||||
$scope.submit = ->
|
||||
@@ -17,4 +17,11 @@ Darkswarm.controller "LoginCtrl", ($scope, $http, $window, AuthenticationService
|
||||
$http.post("/user/spree_user/confirmation", {spree_user: $scope.spree_user}).success (data)->
|
||||
$scope.messages = t('devise.confirmations.send_instructions')
|
||||
.error (data) ->
|
||||
$scope.errors = t('devise.confirmations.failed_to_send')
|
||||
$scope.errors = t('devise.confirmations.failed_to_send')
|
||||
|
||||
$timeout ->
|
||||
if angular.isDefined($location.search()['confirmation'])
|
||||
if $location.search()['confirmation'] == 'confirmed'
|
||||
$scope.messages = t('devise.confirmations.confirmed')
|
||||
if $location.search()['confirmation'] == 'not_confirmed'
|
||||
$scope.errors = t('devise.confirmations.not_confirmed')
|
||||
|
||||
Reference in New Issue
Block a user