Define the routes for the application.

@param \Illuminate\Routing\Router $router

@return void
545445
public function map(Router $router)
    {
        $router->group(['namespace' => $this->namespace], function (Router $router) {

            /*
             * Admin routes
             */
            $router->get('admin/attribute-groups', 'AttributeGroupsAdminController@index')->name('admin::index-attribute_groups');
            $router->get('admin/attribute-groups/create', 'AttributeGroupsAdminController@create')->name('admin::create-attribute_group');
            $router->get('admin/attribute-groups/{group}/edit', 'AttributeGroupsAdminController@edit')->name('admin::edit-attribute_group');
            $router->post('admin/attribute-groups', 'AttributeGroupsAdminController@store')->name('admin::store-attribute_group');
            $router->put('admin/attribute-groups/{group}', 'AttributeGroupsAdminController@update')->name('admin::update-attribute_group');

            $router->get('admin/attribute-groups/{group}/attributes', 'AdminController@index')->name('admin::index-attributes');
            $router->get('admin/attribute-groups/{group}/attributes/create', 'AdminController@create')->name('admin::create-attribute');
            $router->get('admin/attribute-groups/{group}/attributes/{attribute}/edit', 'AdminController@edit')->name('admin::edit-attribute');
            $router->post('admin/attribute-groups/{group}/attributes', 'AdminController@store')->name('admin::store-attribute');
            $router->put('admin/attribute-groups/{group}/attributes/{attribute}', 'AdminController@update')->name('admin::update-attribute');
            $router->post('admin/attributes/sort', 'AdminController@sort')->name('admin::sort-menulinks');

            /*
             * API routes
             */
            $router->get('api/attributes', 'ApiController@index')->name('api::index-attributes');
            $router->put('api/attributes/{attribute}', 'ApiController@update')->name('api::update-attribute');
            $router->delete('api/attributes/{attribute}', 'ApiController@destroy')->name('api::destroy-attribute');

            $router->get('api/attribute-groups', 'AttributeGroupsApiController@index')->name('api::index-attribute_groups');
            $router->put('api/attribute-groups/{attribute}', 'AttributeGroupsApiController@update')->name('api::update-attribute_group');
            $router->delete('api/attribute-groups/{attribute}', 'AttributeGroupsApiController@destroy')->name('api::destroy-attribute_group');
        });
    }
912972
public function boot(Router $router)
    {
        $this->app->singleton('cms', function ($app) {
            return app()->make(\LaravelFlare\Cms\CmsManager::class);
        });

        $this->publishes([
            __DIR__.'/Database/Migrations' => base_path('database/migrations'),
        ]);
        
        // Views
        $this->loadViewsFrom(__DIR__.'/../resources/views', 'flare');
        $this->publishes([
            __DIR__.'/../resources/views' => base_path('resources/views/vendor/flare'),
        ]);
        // Routes
       // if (!$this->app->routesAreCached()) {
            require __DIR__.'/Http/routes.php';
      //  }
      //  
    }
736552
protected function registerRouteFilters(Router $router) {
		foreach ( ( array ) $this->before as $before ) {
			$router->before ( $before );
		}
		
		foreach ( ( array ) $this->after as $after ) {
			$router->after ( $after );
		}
		
		foreach ( ( array ) $this->filters as $name => $filter ) {
			$router->filter ( $name, $filter );
		}
	}
161024
public function boot(Router $router): void
    {
        // Bind route models and constrains
        $router->pattern('service', '[a-zA-Z0-9-]+');
        $router->pattern('service_rate', '[a-zA-Z0-9-]+');
        $router->pattern('service_booking', '[a-zA-Z0-9-]+');
        $router->pattern('service_availability', '[a-zA-Z0-9-]+');
        $router->pattern('event_booking', '[a-zA-Z0-9-]+');
        $router->pattern('event_ticket', '[a-zA-Z0-9-]+');
        $router->pattern('event', '[a-zA-Z0-9-]+');

        $router->model('service', config('cortex.bookings.models.service'));
        $router->model('service_rate', config('cortex.bookings.models.service_rate'));
        $router->model('service_booking', config('cortex.bookings.models.service_booking'));
        $router->model('service_availability', config('cortex.bookings.models.service_availability'));
        $router->model('event_booking', config('cortex.bookings.models.event_booking'));
        $router->model('event_ticket', config('cortex.bookings.models.event_ticket'));
        $router->model('event', config('cortex.bookings.models.event'));

        // Map relations
        Relation::morphMap([
            'service' => config('cortex.bookings.models.service'),
            'service_rate' => config('cortex.bookings.models.service_rate'),
            'service_booking' => config('cortex.bookings.models.service_booking'),
            'service_availability' => config('cortex.bookings.models.service_availability'),
            'event_booking' => config('cortex.bookings.models.event_booking'),
            'event_ticket' => config('cortex.bookings.models.event_ticket'),
            'event' => config('cortex.bookings.models.event'),
        ]);

        // Load resources
        require __DIR__.'/../../routes/breadcrumbs/adminarea.php';
        $this->loadRoutesFrom(__DIR__.'/../../routes/web/adminarea.php');
        $this->loadViewsFrom(__DIR__.'/../../resources/views', 'cortex/bookings');
        $this->loadTranslationsFrom(__DIR__.'/../../resources/lang', 'cortex/bookings');
        ! $this->app->runningInConsole() || $this->loadMigrationsFrom(__DIR__.'/../../database/migrations');
        $this->app->runningInConsole() || $this->app->afterResolving('blade.compiler', function () {
            require __DIR__.'/../../routes/menus/adminarea.php';
        });

        // Publish resources
        ! $this->app->runningInConsole() || $this->publishResources();
    }
1099083
public function setRoutes (Router $router)
    {
        // Filter
        $router->addFilter ('authenticated', array ($this, 'routerVerifier'));

        // Routes
        $router->match ('GET|POST', $this->routepath . '/login/{authenticator}', '\CatLab\Accounts\Controllers\LoginController@authenticator');
        $router->match ('GET', $this->routepath . '/login', '\CatLab\Accounts\Controllers\LoginController@login');
        $router->match ('GET', $this->routepath . '/welcome', '\CatLab\Accounts\Controllers\LoginController@welcome')->filter('authenticated');

        $router->match ('GET|POST', $this->routepath . '/notverified', '\CatLab\Accounts\Controllers\LoginController@requiresVerification');

        $router->match ('GET', $this->routepath . '/logout', '\CatLab\Accounts\Controllers\LoginController@logout');

        $router->match ('GET', $this->routepath . '/cancel', '\CatLab\Accounts\Controllers\LoginController@cancel');

        $router->match ('GET|POST', $this->routepath . '/register/{authenticator}', '\CatLab\Accounts\Controllers\RegistrationController@authenticator');
        $router->match ('GET|POST', $this->routepath . '/register', '\CatLab\Accounts\Controllers\RegistrationController@register');

        $router->get ($this->routepath . '/verify/{id}', '\CatLab\Accounts\Controllers\LoginController@verify');
    }
928807
public function boot(Router $router)
	{
		$this->setRootControllerNamespace();

		if ($this->app->routesAreCached())
		{
			$this->loadCachedRoutes();
		}
		else
		{
			$this->loadRoutes();
		}
	}
659734
public function boot(Router $router)
    {
        $this->defineRoutes($router);

        $this->loadViewsFrom(__DIR__.'/../resources/views', 'warden');
        $this->publishes([
            __DIR__.'/../resources/views' => base_path('resources/views/vendor/warden'),
        ], 'views');
        $this->publishes([
            __DIR__.'/../config/config.php' => config_path('kregel/warden.php'),
        ], 'config');
    }
123147
public function boot(Router $router)
    {
        $this->loadViewsFrom(__DIR__ . '/views', 'initialize');

        $this->publishes([
            __DIR__.'/config/wangeditor.php' => config_path('wangeditor.php'),
        ], 'config');

        $this->publishes([
            __DIR__ . '/assets/wangeditor' => public_path('vendor/wangeditor'),
        ], 'assets');

        $this->publishes([
            __DIR__ . '/views' => base_path('resources/views/vendor/wangeditor')
        ], 'resources');

        if (!app()->runningInConsole()) {
            $this->registerRoute($router);
        }
    }
985201
protected function handleRoutes(Router $router, $config = [])
    {
        if ($this->app->routesAreCached() === false) {
            $router->group(array_merge([
                'namespace' => $this->namespace,
            ], $config), function (Router $router) {
                require __DIR__.'/../routes/web.php';
            });
        }
    }
331249
public function setupRoutes(Router $router)
    {
        // by default, use the routes file provided in vendor
        $routeFilePathInUse = __DIR__.$this->routeFilePath;
        // but if there's a file with the same name in routes/backpack, use that one
        if (file_exists(base_path().$this->routeFilePath)) {
            $routeFilePathInUse = base_path().$this->routeFilePath;
        }
        $this->loadRoutesFrom($routeFilePathInUse);
    }
1298002
public function boot(Router $router)
    {
        if (!$this->app->routesAreCached()) {
            $router->group([
                'namespace' => $this->namespace,
            ], function (Router $router) {
                require __DIR__.'/../routes/web.php';
            });
        }
    }
1328764
protected function buildRoutesForAuth(Router $router)
    {
        $auth = $this->core->auth();

        $router->group(
            [
                'prefix' => 'auth',
            ],
            function (Router $router) use ($auth) {

                $router->{$this->getLoginMethod()}($this->getLoginPath(), $auth->getApiRouteLoginAction());
                $router->{$this->getLogoutMethod()}($this->getLogoutPath(), $auth->getApiRouteLogoutAction());
            }
        );
    }
960428
public function boot(Router $router)
    {
        if (!$this->app->routesAreCached()) {
            require __DIR__ . '/../routes.php';
        }

        $this->loadMigrationsFrom(__DIR__ . '/../migrations');
        $router->aliasMiddleware('didbot.xml-http-request', \Didbot\DidbotApi\Middleware\XmlHttpRequest::class);
        $router->aliasMiddleware('didbot.throttle', \Didbot\DidbotApi\Middleware\ThrottleRequest::class);

        Passport::routes();


        Validator::extend('iso8601', function ($attribute, $value, $parameters, $validator) {

            return (preg_match('/^([\+-]?\d{4}(?!\d{2}\b))((-?)((0[1-9]|1[0-2])(\3([12]\d|0[1-9]|3[01]))?|W([0-4]\d|5[0-2])(-?[1-7])?|(00[1-9]|0[1-9]\d|[12]\d{2}|3([0-5]\d|6[1-6])))([T\s]((([01]\d|2[0-3])((:?)[0-5]\d)?|24\:?00)([\.,]\d+(?!:))?)?(\17[0-5]\d([\.,]\d+)?)?([zZ]|([\+-])([01]\d|2[0-3]):?([0-5]\d)?)?)?)?$/',
                    $value) === 1);
        });

        Validator::extend('uuid', function ($attribute, $value, $parameters, $validator) {

            return (preg_match('/^[a-f\d]{8}-(?:[a-f\d]{4}-){3}[a-f\d]{12}$/i',
                    $value) === 1);

        });

        Validator::extend('geo', function ($attribute, $value, $parameters, $validator) {

            return (preg_match('/^[-+]?([1-8]?\d(\.\d+)?|90(\.0+)?),\s*[-+]?(180(\.0+)?|((1[0-7]\d)|([1-9]?\d))(\.\d+)?)$/',
                    $value) === 1);

        });


        // Custom names for the Polymorphic relation on the Didbot\DidbotApi\Models\Source model
        Relation::morphMap([
            'client' => 'Laravel\Passport\Client',
            'token' => 'Laravel\Passport\Token',
        ]);
    }
572645
public function mapApiRoutes(Router $router)
    {
        $permissionPrefix = $this->routeHelper->getPermissionPrefixForModelSlug(
            $this->getModelSlug()
        );

        $router->group(
            [
                'prefix'     => $this->getRoutePrefix(),
                'as'         => $this->getRouteNamePrefix(),
                'middleware' => [ cms_mw_permission("{$permissionPrefix}*") ],
            ],
            function (Router $router) use ($permissionPrefix) {

                $controller = $this->getModelApiController();

                $router->get('/', [
                    'as'   => 'index',
                    'uses' => $controller . '@index',
                ]);

                $router->get('create', [
                    'as'         => 'create',
                    'middleware' => [cms_mw_permission("{$permissionPrefix}create")],
                    'uses'       => $controller . '@create',
                ]);

                $router->post('/', [
                    'as'         => 'store',
                    'middleware' => [cms_mw_permission("{$permissionPrefix}create")],
                    'uses'       => $controller . '@store',
                ]);

                $router->get('{key}', [
                    'as'   => 'show',
                    'uses' => $controller . '@show',
                ]);

                $router->get('{key}/edit', [
                    'as'         => 'edit',
                    'middleware' => [cms_mw_permission("{$permissionPrefix}edit")],
                    'uses'       => $controller . '@edit',
                ]);

                $router->put('{key}', [
                    'as'         => 'update',
                    'middleware' => [cms_mw_permission("{$permissionPrefix}edit")],
                    'uses'       => $controller . '@update',
                ]);

                $router->delete('{key}', [
                    'as'         => 'destroy',
                    'middleware' => [cms_mw_permission("{$permissionPrefix}delete")],
                    'uses'       => $controller . '@destroy',
                ]);
            }
        );
    }
452333
public function loadModules(Router $router) {
        $this->modules = require_once BASE_DIR . '/config/modules.php';

        foreach ($this->modules['modules'] as $module) {
            if (!file_exists(MODULES_DIR . '/' . $module . '/Config/routes.php')) {
                throw new \Exception(_message(ExceptionMessages::MODULE_NOT_FOUND, $module));
            }

            $routesClosure = require_once MODULES_DIR . '/' . $module . '/Config/routes.php';

            if (!$routesClosure instanceof \Closure) {
                throw new \Exception(ExceptionMessages::ROUTES_NOT_CLOSURE);
            }

            $route = new Route($module);
            $routesClosure($route);
            $router->routes = $route->getRuntimeRoutes();
        }
    }
1027379
public static function routes(Router $router)
    {
        $controllers = config('forum.frontend.controllers');

        // Forum index
        $router->get('/', ['as' => 'index', 'uses' => "{$controllers['category']}@index"]);

        // New/updated threads
        $router->get('new', ['as' => 'index-new', 'uses' => "{$controllers['thread']}@indexNew"]);
        $router->patch('new', ['as' => 'mark-new', 'uses' => "{$controllers['thread']}@markNew"]);

        // Categories
        $router->post('category/create', ['as' => 'category.store', 'uses' => "{$controllers['category']}@store"]);
        $router->group(['prefix' => '{category}-{category_slug}'], function ($router) use ($controllers) {
            $router->get('/', ['as' => 'category.show', 'uses' => "{$controllers['category']}@show"]);
            $router->patch('/', ['as' => 'category.update', 'uses' => "{$controllers['category']}@update"]);
            $router->delete('/', ['as' => 'category.delete', 'uses' => "{$controllers['category']}@destroy"]);

            // Threads
            $router->get('{thread}-{thread_slug}', ['as' => 'thread.show', 'uses' => "{$controllers['thread']}@show"]);
            $router->get('thread/create', ['as' => 'thread.create', 'uses' => "{$controllers['thread']}@create"]);
            $router->post('thread/create', ['as' => 'thread.store', 'uses' => "{$controllers['thread']}@store"]);
            $router->patch('{thread}-{thread_slug}', ['as' => 'thread.update', 'uses' => "{$controllers['thread']}@update"]);
            $router->delete('{thread}-{thread_slug}', ['as' => 'thread.delete', 'uses' => "{$controllers['thread']}@destroy"]);

            // Posts
            $router->get('{thread}-{thread_slug}/post/{post}', ['as' => 'post.show', 'uses' => "{$controllers['post']}@show"]);
            $router->get('{thread}-{thread_slug}/reply', ['as' => 'post.create', 'uses' => "{$controllers['post']}@create"]);
            $router->post('{thread}-{thread_slug}/reply', ['as' => 'post.store', 'uses' => "{$controllers['post']}@store"]);
            $router->get('{thread}-{thread_slug}/post/{post}/edit', ['as' => 'post.edit', 'uses' => "{$controllers['post']}@edit"]);
            $router->patch('{thread}-{thread_slug}/{post}', ['as' => 'post.update', 'uses' => "{$controllers['post']}@update"]);
            $router->delete('{thread}-{thread_slug}/{post}', ['as' => 'post.delete', 'uses' => "{$controllers['post']}@destroy"]);
        });

        // Bulk actions
        $router->group(['prefix' => 'bulk', 'as' => 'bulk.'], function ($router) use ($controllers) {
            $router->patch('thread', ['as' => 'thread.update', 'uses' => "{$controllers['thread']}@bulkUpdate"]);
            $router->delete('thread', ['as' => 'thread.delete', 'uses' => "{$controllers['thread']}@bulkDestroy"]);
            $router->patch('post', ['as' => 'post.update', 'uses' => "{$controllers['post']}@bulkUpdate"]);
            $router->delete('post', ['as' => 'post.delete', 'uses' => "{$controllers['post']}@bulkDestroy"]);
        });
    }
903452
protected function defineRoutes()
    {
        if (!$this->app->routesAreCached()) {
            $router = app('router');
            $this->defineWebRoutes($router);
            $this->defineApiRoutes($router);
        }
    }