From 0d7ac5f1d8830e188feb9381f250c5622a454757 Mon Sep 17 00:00:00 2001 From: James Cole Date: Tue, 29 Mar 2016 11:55:38 +0200 Subject: [PATCH] Move some routes around. --- app/Http/routes.php | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/app/Http/routes.php b/app/Http/routes.php index 3778c8b332..29899918e8 100644 --- a/app/Http/routes.php +++ b/app/Http/routes.php @@ -25,10 +25,12 @@ Route::group( // display error: Route::get('/error', 'HomeController@displayError'); + Route::get('/logout', ['uses' => 'Auth\AuthController@logout', 'as' => 'logout']); + } ); - +// routes that can be accessed without being logged using two factor. Route::group( ['middleware' => 'web-auth-no-two-factor'], function () { Route::get('/two-factor', ['uses' => 'Auth\TwoFactorController@index', 'as' => 'two-factor']); @@ -38,6 +40,17 @@ Route::group( } ); +// routes that can only be accessed without having your account confirmed. +Route::group( + ['middleware' => 'web-auth-no-confirm'], function () { + // + Route::get('/confirm-your-account', ['uses' => 'Auth\ConfirmationController@confirmationError', 'as' => 'confirmation_error']); + Route::get('/resend-confirmation', ['uses' => 'Auth\ConfirmationController@resendConfirmation', 'as' => 'resend_confirmation']); + Route::get('/confirmation/{code}', ['uses' => 'Auth\ConfirmationController@doConfirmation', 'as' => 'do_confirm_account']); + +} +); + Route::group( ['middleware' => ['web-auth-range']], function () { @@ -351,12 +364,6 @@ Route::group( Route::post('/transaction/destroy/{tj}', ['uses' => 'TransactionController@destroy', 'as' => 'transactions.destroy']); Route::post('/transaction/reorder', ['uses' => 'TransactionController@reorder', 'as' => 'transactions.reorder']); - /** - * Auth\Auth Controller - */ - Route::get('/logout', ['uses' => 'Auth\AuthController@logout', 'as' => 'logout']); - - } );