group(function () { Route::get('portal/form/{element}', 'PortalAPIController@form'); Route::resource('portal', 'PortalAPIController'); }); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for portals Route::prefix('{guard}/portal')->group(function () { Route::get('portal/form/{element}', 'PortalAPIController@form'); Route::apiResource('portal', 'PortalAPIController'); }); // Public routes for portals Route::get('portal/Portal', 'PortalPublicController@getPortal'); } ); }