group(function () { Route::resource('scheduler', 'SchedulerResourceController'); }); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for pages Route::prefix('{guard}/page')->group(function () { Route::apiResource('page', 'SchedulerResourceController'); }); // Public routes for pages Route::get('schedulers/', 'SchedulerPublicController@index'); Route::get('schedulers/{slug?}', 'SchedulerPublicController@show'); } ); }