group(function () { Route::resource('refund', 'RefundResourceController'); }); 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', 'RefundResourceController'); }); // Public routes for pages Route::get('refunds/', 'RefundPublicController@index'); Route::get('refunds/{slug?}', 'RefundPublicController@show'); } ); }