group(function () { Route::resource('category', 'CategoryResourceController'); }); // Guard routes for property Route::prefix('{guard}/property')->group(function () { Route::resource('property', 'PropertyResourceController'); }); // Public routes for property Route::get('properties/', 'PropertyPublicController@index'); Route::get('property/{slug?}', 'PropertyPublicController@show'); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for category Route::prefix('{guard}/property')->group(function () { Route::resource('category', 'CategoryResourceController'); }); // Guard routes for property Route::prefix('{guard}/property')->group(function () { Route::resource('property', 'PropertyResourceController'); }); // Public routes for property Route::get('properties/', 'PropertyPublicController@index'); Route::get('property/{slug?}', 'PropertyPublicController@show'); } ); }