Exemplo n.º 1
0
            $persistence = Sentinel::getPersistenceRepository();
            return view('account.home', compact('user', 'persistence'));
        });
        Route::resource('profile', 'Accounts\\AccountsController', ['only' => ['show', 'edit', 'update']]);
        Route::get('kill', function () {
            $user = Sentinel::getUser();
            Sentinel::getPersistenceRepository()->flush($user);
            return Redirect::back();
        });
        Route::get('kill-all', function () {
            $user = Sentinel::getUser();
            Sentinel::getPersistenceRepository()->flush($user, false);
            return Redirect::back();
        });
        Route::get('kill/{code}', function ($code) {
            Sentinel::getPersistenceRepository()->remove($code);
            return Redirect::back();
        });
    });
});
/*******************************************************
 * //User login and active routes
 ******************************************************/
Route::get('login', ['as' => 'login', 'middleware' => 'guest', 'uses' => 'Auth\\AuthController@login']);
Route::post('login', 'Auth\\AuthController@processLogin');
Route::get('logout', 'Auth\\AuthController@logout');
Route::post('logout', 'Auth\\AuthController@logout');
Route::get('activate/{id}/{code}', 'Auth\\AuthController@getActivate')->where('id', '\\d+');
Route::get('activate/{id}/{code}', 'Auth\\AuthController@getReactivate')->where('id', '\\d+');
Route::get('deactivate', 'Auth\\AuthController@deactivate');
Route::get('wait', 'Auth\\AuthController@wait');