src/Routing/RouteServiceProvider.php
/**
     * Define your route model bindings, pattern filters, etc.
     *
     * @return void
     */
Define your route model bindings, pattern filters, etc.
@return void
Define your route model bindings pattern filters etc . @return void
public function boot()
    {
        $router = $this->app['router'];
        $router->middlewareGroup('soda.web', [Drafting::class]);
        $router->middlewareGroup('soda.api', [Drafting::class]);
        $router->pushMiddlewareToGroup('web', TransferSession::class);
        $router->pushMiddlewareToGroup('web', DraftAlert::class);
        $router->pushMiddlewareToGroup('web', ToggleLocale::class);
        if (config('soda.cms.https')) {
            $router->pushMiddlewareToGroup('soda.web', ForceHttps::class);
        }
        $router->aliasMiddleware('soda.auth', Authenticate::class);
        $router->aliasMiddleware('soda.guest', RedirectIfAuthenticated::class);
        $router->aliasMiddleware('soda.role', HasRole::class);
        $router->aliasMiddleware('soda.permission', HasPermission::class);
        $router->aliasMiddleware('soda.ability', HasAbility::class);
        $middlewareGroups = $router->getMiddlewareGroups();
        if (isset($middlewareGroups['web'])) {
            if (($key = array_search('Illuminate\Session\Middleware\StartSession', $middlewareGroups['web'])) !== false) {
                $middlewareGroups['web'][$key] = SluggableSession::class;
                array_unshift($router->middlewarePriority, SluggableSession::class);
            }
            $router->middlewareGroup('soda.sluggable-web', $middlewareGroups['web']);
        }
        parent::boot();
    }
public function boot ( ) { $ router = $ this -> app [ 'router' ] ; $ router -> middlewareGroup ( 'soda.web' , [ Drafting :: class ] ) ; $ router -> middlewareGroup ( 'soda.api' , [ Drafting :: class ] ) ; $ router -> pushMiddlewareToGroup ( 'web' , TransferSession :: class ) ; $ router -> pushMiddlewareToGroup ( 'web' , DraftAlert :: class ) ; $ router -> pushMiddlewareToGroup ( 'web' , ToggleLocale :: class ) ; if ( config ( 'soda.cms.https' ) ) { $ router -> pushMiddlewareToGroup ( 'soda.web' , ForceHttps :: class ) ; } $ router -> aliasMiddleware ( 'soda.auth' , Authenticate :: class ) ; $ router -> aliasMiddleware ( 'soda.guest' , RedirectIfAuthenticated :: class ) ; $ router -> aliasMiddleware ( 'soda.role' , HasRole :: class ) ; $ router -> aliasMiddleware ( 'soda.permission' , HasPermission :: class ) ; $ router -> aliasMiddleware ( 'soda.ability' , HasAbility :: class ) ; $ middlewareGroups = $ router -> getMiddlewareGroups ( ) ; if ( isset ( $ middlewareGroups [ 'web' ] ) ) { if ( ( $ key = array_search ( 'Illuminate\Session\Middleware\StartSession' , $ middlewareGroups [ 'web' ] ) ) !== false ) { $ middlewareGroups [ 'web' ] [ $ key ] = SluggableSession :: class ; array_unshift ( $ router -> middlewarePriority , SluggableSession :: class ) ; } $ router -> middlewareGroup ( 'soda.sluggable-web' , $ middlewareGroups [ 'web' ] ) ; } parent :: boot ( ) ; }
Define your route model bindings, pattern filters, etc.
Define your route model bindings pattern filters etc .