本文整理汇总了PHP中Illuminate\Contracts\Routing\Registrar类的典型用法代码示例。如果您正苦于以下问题:PHP Registrar类的具体用法?PHP Registrar怎么用?PHP Registrar使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了Registrar类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: map
/**
* Define the status page routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*
* @return void
*/
public function map(Registrar $router)
{
$router->group(['middleware' => ['web', 'ready']], function (Registrar $router) {
$router->get('/atom/{component_group?}', ['as' => 'feed.atom', 'uses' => 'FeedController@atomAction']);
$router->get('/rss/{component_group?}', ['as' => 'feed.rss', 'uses' => 'FeedController@rssAction']);
});
}
开发者ID:aksalj,项目名称:Cachet,代码行数:14,代码来源:FeedRoutes.php
示例2: map
/**
* Define the status page routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
$router->group(['middleware' => 'app.isSetup'], function ($router) {
$router->get('/', ['as' => 'status-page', 'uses' => 'StatusPageController@showIndex']);
$router->get('incident/{incident}', ['as' => 'incident', 'uses' => 'StatusPageController@showIncident']);
});
}
开发者ID:annggeel,项目名称:Cachet,代码行数:12,代码来源:StatusPageRoutes.php
示例3: map
/**
* Define the status page routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
$router->group(['middleware' => ['app.hasSetting', 'localize'], 'setting' => 'app_name'], function ($router) {
$router->get('/', ['as' => 'status-page', 'uses' => 'StatusPageController@showIndex']);
$router->get('incident/{incident}', ['as' => 'incident', 'uses' => 'StatusPageController@showIncident']);
});
}
开发者ID:minhkiller,项目名称:Cachet,代码行数:12,代码来源:StatusPageRoutes.php
示例4: map
public function map(Registrar $router)
{
$router->group(['prefix' => 'test'], function ($router) {
$router->get('/', ['uses' => 'TestController@test']);
$router->get('/queue', ['uses' => 'TestController@queue']);
});
}
开发者ID:tanteng,项目名称:tanteng.me,代码行数:7,代码来源:TestRoutes.php
示例5: map
/**
* Define the signup routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*
* @return void
*/
public function map(Registrar $router)
{
$router->group(['middleware' => ['web', 'ready', 'guest'], 'as' => 'signup.'], function (Registrar $router) {
$router->get('signup/invite/{code}', ['as' => 'invite', 'uses' => 'SignupController@getSignup']);
$router->post('signup/invite/{code}', ['uses' => 'SignupController@postSignup']);
});
}
开发者ID:aksalj,项目名称:Cachet,代码行数:14,代码来源:SignupRoutes.php
示例6: map
/**
* Define the signup routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
$router->group(['middleware' => ['app.hasSetting', 'guest'], 'setting' => 'app_name', 'as' => 'signup.'], function ($router) {
$router->get('signup/invite/{code}', ['as' => 'invite', 'uses' => 'SignupController@getSignup']);
$router->post('signup/invite/{code}', ['uses' => 'SignupController@postSignup']);
});
}
开发者ID:emtudo,项目名称:Gitamin,代码行数:12,代码来源:SignupRoutes.php
示例7: map
/**
* Define the status page routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
// Prevent access until the app is setup.
$router->group(['middleware' => 'app.hasSetting', 'setting' => 'app_name'], function ($router) {
$router->get('/', ['as' => 'status-page', 'uses' => 'HomeController@showIndex']);
});
}
开发者ID:anujaprasad,项目名称:Hihat,代码行数:12,代码来源:StatusPageRoutes.php
示例8: bind
public function bind(Registrar $router)
{
$router->group(['prefix' => 'admin', 'namespace' => 'App\\Http\\Admin\\Controllers', 'middleware' => ['web', 'guest'], 'category' => 'Sentinel'], function (Registrar $sentinel) {
$sentinel->get('dashboard', ['as' => 'admin.dashboard', 'uses' => 'Controller@index']);
$sentinel->get('account/user', ['as' => 'admin.account.user', 'uses' => 'Sentinel\\AccountController@editAccountUser']);
$sentinel->post('account/user-info/update', ['as' => 'admin.account.user.update', 'uses' => 'Sentinel\\AccountController@updateAccountUser']);
$sentinel->get('account/person', ['as' => 'admin.account.person', 'uses' => 'Sentinel\\AccountController@editAccountPerson']);
$sentinel->post('account/personal-info/update', ['as' => 'admin.account.person.update', 'uses' => 'Sentinel\\AccountController@updateAccountPerson']);
$sentinel->get('system', ['as' => 'admin.settings.user.system', 'uses' => 'Sentinel\\AccountController@editSystem']);
$sentinel->post('system/update', ['as' => 'admin.settings.user.system.update', 'uses' => 'Sentinel\\AccountController@updateSystem']);
});
$router->group(['prefix' => 'admin', 'namespace' => 'App\\Http\\Admin\\Controllers\\Sentinel', 'middleware' => ['web', 'guest', 'backendPermissions'], 'category' => 'Sentinel'], function (Registrar $sentinel) {
$sentinel->resource('user', 'UserController');
$sentinel->put('user/{userId}/restore', ['as' => 'admin.user.delete.restore', 'uses' => 'UserController@restore']);
$sentinel->put('user/{userId}/activate', ['as' => 'admin.user.edit.activate', 'uses' => 'UserController@activate']);
$sentinel->put('user/{userId}/deactivate', ['as' => 'admin.user.edit.deactivate', 'uses' => 'UserController@deactivate']);
$sentinel->resource('group', 'GroupController');
$sentinel->get('group/{group}/members', ['as' => 'admin.group.edit.members', 'uses' => 'GroupController@editMembers']);
$sentinel->post('group/{group}/attach/{user}', ['as' => 'admin.group.add.attach', 'uses' => 'GroupController@attach']);
$sentinel->delete('group/{group}/detach/{user}', ['as' => 'admin.group.delete.detach', 'uses' => 'GroupController@detach']);
});
$router->group(['prefix' => 'admin', 'namespace' => 'App\\Http\\Admin\\Controllers\\Sentinel', 'middleware' => ['web', 'guest'], 'category' => 'Sentinel'], function (Registrar $manager) {
$manager->get('user/{user}/permissions/edit', ['as' => 'admin.user.permission.edit', 'uses' => 'PermissionController@edit']);
$manager->post('user/{user}/{permission_type}/edit', ['as' => 'admin.user.permission.update', 'uses' => 'PermissionController@update']);
$manager->get('group/{group}/permissions/edit', ['as' => 'admin.group.permission.edit', 'uses' => 'PermissionController@edit']);
$manager->post('group/{group}/{permission_type}/edit', ['as' => 'admin.group.permission.update', 'uses' => 'PermissionController@update']);
$manager->post('user/{user}/{permission_type}/toggle', ['as' => 'admin.user.permission.toggle', 'uses' => 'PermissionController@toggle']);
$manager->post('group/{group}/{permission_type}/toggle', ['as' => 'admin.group.permission.toggle', 'uses' => 'PermissionController@toggle']);
});
}
开发者ID:linguisticteam,项目名称:laravel-boilerplate,代码行数:30,代码来源:Sentinel.php
示例9: map
/**
* Define the groups routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
// Project Sub-routes groups.group_show, groups.group_edit
$router->group(['middleware' => ['app.hasSetting', 'auth'], 'setting' => 'app_name', 'as' => 'owners.'], function ($router) {
$router->get('{owner_path}', ['as' => 'owner_show', 'uses' => 'OwnersController@showAction'])->where('owner_path', '[a-zA-z.0-9_\\-]+');
});
}
开发者ID:xiaobailc,项目名称:Gitamin,代码行数:12,代码来源:OwnersRoutes.php
示例10: map
/**
* Define the status page routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*
* @return void
*/
public function map(Registrar $router)
{
$router->group(['middleware' => ['web', 'ready', 'localize']], function ($router) {
$router->get('/', ['as' => 'status-page', 'uses' => 'StatusPageController@showIndex']);
$router->get('incident/{incident}', ['as' => 'incident', 'uses' => 'StatusPageController@showIncident']);
});
}
开发者ID:CMNatic,项目名称:Cachet,代码行数:14,代码来源:StatusPageRoutes.php
示例11: map
/**
* Define the routes for the application.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Router $router)
{
if ($this->isEnabled()) {
$router->group($this->routeAttributes(), function (Router $router) {
LogViewerRoute::register($router);
});
}
}
开发者ID:shellofyou,项目名称:laravel-boilerplate,代码行数:13,代码来源:RouteServiceProvider.php
示例12: map
/**
* Define the status page routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
// Prevent access until the app is setup.
$router->group(['middleware' => 'app.hasSetting', 'setting' => 'app_name'], function ($router) {
$router->get('/atom/{component_group?}', 'AtomController@feedAction');
$router->get('/rss/{component_group?}', 'RssController@feedAction');
});
}
开发者ID:anujaprasad,项目名称:Hihat,代码行数:13,代码来源:FeedRoutes.php
示例13: map
/**
* Define the feed routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
// Prevent access until the app is setup.
$router->group(['middleware' => 'app.hasSetting', 'setting' => 'app_name'], function ($router) {
$router->get('/atom/{project_group?}', ['as' => 'feed.atom', 'uses' => 'FeedController@atomAction']);
$router->get('/rss/{project_group?}', ['as' => 'feed.rss', 'uses' => 'FeedController@rssAction']);
});
}
开发者ID:emtudo,项目名称:Gitamin,代码行数:13,代码来源:FeedRoutes.php
示例14: mapBackEndRoutes
/**
* Define the foundation routes for the application.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
private function mapBackEndRoutes(Router $router)
{
$attributes = array_merge($this->getFoundationRouteGroup(), ['as' => 'pages::foundation.', 'namespace' => 'Arcanesoft\\Pages\\Http\\Controllers\\Back']);
$router->group(array_merge($attributes, ['prefix' => $this->getFoundationPagesPrefix()]), function (Router $router) {
Routes\Back\StatsRoutes::register($router);
Routes\Back\PagesRoutes::register($router);
});
}
开发者ID:arcanesoft,项目名称:pages,代码行数:13,代码来源:RouteServiceProvider.php
示例15: map
/**
* Define the auth routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
$router->group(['as' => 'auth.', 'middleware' => 'app.hasSetting', 'prefix' => 'auth', 'setting' => 'app_name'], function ($router) {
$router->get('login', ['middleware' => 'guest', 'as' => 'login', 'uses' => 'AuthController@loginAction']);
$router->post('login', ['middleware' => ['guest', 'csrf'], 'uses' => 'AuthController@loginPost']);
$router->get('logout', ['as' => 'logout', 'uses' => 'AuthController@logoutAction', 'middleware' => 'auth']);
});
}
开发者ID:xiaobailc,项目名称:Gitamin,代码行数:13,代码来源:AuthRoutes.php
示例16: map
/**
* Define the routes for the application.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Router $router)
{
$router->group($this->getFoundationRouteGroup(), function (Router $router) {
Routes\DashboardRoute::register($router);
Routes\SettingsRoutes::register($router);
Routes\SystemRoutes::register($router);
});
}
开发者ID:arcanesoft,项目名称:foundation,代码行数:13,代码来源:RouteServiceProvider.php
示例17: map
/**
* Define the auth routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
$router->group(['as' => 'auth.', 'namespace' => 'Auth', 'prefix' => 'auth'], function (Registrar $router) {
// Login routes
$router->get('login', ['middleware' => 'guest', 'as' => 'login', 'uses' => 'AuthController@showLogin']);
$router->get('youtube', ['middleware' => 'guest', 'as' => 'login', 'uses' => 'AuthController@postLogin']);
$router->get('logout', ['as' => 'logout', 'uses' => 'AuthController@logoutAction']);
});
}
开发者ID:JoeAlamo,项目名称:Playlister,代码行数:14,代码来源:AuthRoutes.php
示例18: loadRoutes
/**
* Load routes for active modules
*
* @param Registrar $router
* @param string|null $type
*/
public function loadRoutes(Registrar $router, $type = null)
{
$this->withRoutes($type)->each(function ($module) use($router, $type) {
/* @var Module $module */
$router->group(['namespace' => $module->routingControllerNamespace()], function ($router) use($module, $type) {
$this->app['files']->getRequire($this->app->basePath() . DIRECTORY_SEPARATOR . $module->routesFilePath($module->routePrefix(compact('type'))));
});
});
}
开发者ID:mnabialek,项目名称:laravel-simple-modules,代码行数:15,代码来源:Modular.php
示例19: mapAdminRoutes
/**
* Map the admin routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
private function mapAdminRoutes(Router $router)
{
$attributes = array_merge($this->getFoundationRouteGroup(), ['as' => 'admin::foundation.', 'namespace' => 'Arcanesoft\\Foundation\\Http\\Controllers\\Admin']);
$router->group($attributes, function (Router $router) {
Routes\Admin\DashboardRoute::register($router);
Routes\Admin\SettingsRoutes::register($router);
Routes\Admin\SystemRoutes::register($router);
});
}
开发者ID:ARCANESOFT,项目名称:Foundation,代码行数:14,代码来源:RouteServiceProvider.php
示例20: map
/**
* Define the home routes.
*
* @param \Illuminate\Contracts\Routing\Registrar $router
*/
public function map(Registrar $router)
{
$router->get('/', function () {
$gc = app('Playlister\\Services\\YoutubeAPI\\YoutubeAPI')->getClient();
$playlists = new \Google_Service_YouTube($gc);
dd($playlists->playlists->listPlaylists('contentDetails,snippet', ['mine' => true]));
return view('welcome');
});
}
开发者ID:JoeAlamo,项目名称:Playlister,代码行数:14,代码来源:HomeRoutes.php
注:本文中的Illuminate\Contracts\Routing\Registrar类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论