1By default, Route::resource will create the route parameters
2for your resource routes based on the "singularized" version
3of the resource name. You can easily override this on a per resource
4basis using the parameters method. The array passed into the parameters
5method should be an associative array of resource names and parameter names:
6
7use App\Http\Controllers\AdminUserController;
8
9Route::resource('users', AdminUserController::class)->parameters([
10 'users' => 'admin_user'
11]);
1Route::resource('faq', 'ProductFaqController', [
2 'names' => [
3 'index' => 'faq',
4 'store' => 'faq.new',
5 // etc...
6 ]
7]);