protected function registerDefaultRoutes(Router $router)
    {
        $router->group(
            [
                'prefix' => \Flare::config('admin_url'),
                'as' => 'flare::',
                'middleware' => ['web', 'flarebase'],
            ],
            function ($router) {
                // Logout route...
                $router->get('logout', $this->adminController('getLogout'))->name('logout');

                if (\Flare::show('login')) {
                    // Login request reoutes...
                    $router->get('login', $this->adminController('getLogin'))->name('login');
                    $router->post('login', $this->adminController('postLogin'))->name('login');

                    // Password reset link request routes...
                    $router->get('email', $this->adminController('getEmail'))->name('email');
                    $router->post('email', $this->adminController('postEmail'))->name('email');

                    // Password reset routes...
                    $router->get('reset/{token}', $this->adminController('getReset'))->name('reset');
                    $router->post('reset', $this->adminController('postReset'))->name('reset');
                }
            }
        );
    }
protected function registerDefaultRoutes(Router $router)
    {
        $router->group(
            [
                'prefix' => \Flare::config('admin_url'),
                'as' => 'flare::',
                'middleware' => ['web', 'flarebase'],
            ],
            function ($router) {
                // Logout route...
                $router->get('logout', $this->adminController('getLogout'))->name('logout');

                if (\Flare::show('login')) {
                    // Login request reoutes...
                    $router->get('login', $this->adminController('getLogin'))->name('login');
                    $router->post('login', $this->adminController('postLogin'))->name('login');

                    // Password reset link request routes...
                    $router->get('email', $this->adminController('getEmail'))->name('email');
                    $router->post('email', $this->adminController('postEmail'))->name('email');

                    // Password reset routes...
                    $router->get('reset/{token}', $this->adminController('getReset'))->name('reset');
                    $router->post('reset', $this->adminController('postReset'))->name('reset');
                }
            }
        );
    }
protected function registerDefaultRoutes ( Router $ router ) { $ router -> group ( [ 'prefix' => \ Flare :: config ( 'admin_url' ) , 'as' => 'flare::' , 'middleware' => [ 'web' , 'flarebase' ] , ] , function ( $ router ) { // Logout route... $ router -> get ( 'logout' , $ this -> adminController ( 'getLogout' ) ) -> name ( 'logout' ) ; if ( \ Flare :: show ( 'login' ) ) { // Login request reoutes... $ router -> get ( 'login' , $ this -> adminController ( 'getLogin' ) ) -> name ( 'login' ) ; $ router -> post ( 'login' , $ this -> adminController ( 'postLogin' ) ) -> name ( 'login' ) ; // Password reset link request routes... $ router -> get ( 'email' , $ this -> adminController ( 'getEmail' ) ) -> name ( 'email' ) ; $ router -> post ( 'email' , $ this -> adminController ( 'postEmail' ) ) -> name ( 'email' ) ; // Password reset routes... $ router -> get ( 'reset/{token}' , $ this -> adminController ( 'getReset' ) ) -> name ( 'reset' ) ; $ router -> post ( 'reset' , $ this -> adminController ( 'postReset' ) ) -> name ( 'reset' ) ; } } ) ; }
Register the Default Routes.

This registers all the default routes which are included
with Flare. These consist of things which will probably
be included with every application such as the login,
logout and password reset forms.

The login form can however be hidden by setting the
'show' config for 'login' to false.

@param Router $router
Register the Default Routes .