Laravel 定制资源路由器的路由名称

Laravel

Route::resource('photos', 'PhotosController', ['names' => [
    'index' => 'photos.index',
    'create' => 'photos.create',
    'store' => 'photos.store',
    'show' => 'photos.show',
    'edit' => 'photos.edit',
    'update' => 'photos.update',
    'destroy' => 'photos.destroy'
]]);
评论数量: 0

5
点赞
401
浏览
0
评论

贡献 535
Summer
Building Products Users Love