group(function () { Route::get('kitchen/form/{element}', 'KitchenAPIController@form'); Route::resource('kitchen', 'KitchenAPIController'); }); // Public routes for kitchen Route::get('kitchen_blogs/', 'KitchenPublicController@index'); Route::get('kitchen_blogs/{slug?}', 'KitchenPublicController@show'); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for kitchen_blogs Route::prefix('{guard}/kitchen_blog')->group(function () { Route::get('kitchen/form/{element}', 'KitchenAPIController@form'); Route::apiResource('kitchen', 'KitchenAPIController'); }); // Public routes for kitchen_blogs Route::get('kitchen_blog/Kitchen', 'KitchenPublicController@getKitchen'); } ); } // API routes for kitchen_category Route::prefix('{guard}/kitchen_blog')->group(function () { Route::get('kitchen_category/form/{element}', 'KitchenCategoryAPIController@form'); Route::resource('kitchen_category', 'KitchenCategoryAPIController'); }); // Public routes for kitchen_category Route::get('kitchen_blogs/', 'KitchenCategoryPublicController@index'); Route::get('kitchen_blogs/{slug?}', 'KitchenCategoryPublicController@show'); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for kitchen_blogs Route::prefix('{guard}/kitchen_blog')->group(function () { Route::get('kitchen_category/form/{element}', 'KitchenCategoryAPIController@form'); Route::apiResource('kitchen_category', 'KitchenCategoryAPIController'); }); // Public routes for kitchen_blogs Route::get('kitchen_blog/KitchenCategory', 'KitchenCategoryPublicController@getKitchenCategory'); } ); } // API routes for kitchen_comment Route::prefix('{guard}/kitchen_blog')->group(function () { Route::get('kitchen_comment/form/{element}', 'KitchenCommentAPIController@form'); Route::resource('kitchen_comment', 'KitchenCommentAPIController'); }); // Public routes for kitchen_comment Route::get('kitchen_blogs/', 'KitchenCommentPublicController@index'); Route::get('kitchen_blogs/{slug?}', 'KitchenCommentPublicController@show'); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for kitchen_blogs Route::prefix('{guard}/kitchen_blog')->group(function () { Route::get('kitchen_comment/form/{element}', 'KitchenCommentAPIController@form'); Route::apiResource('kitchen_comment', 'KitchenCommentAPIController'); }); // Public routes for kitchen_blogs Route::get('kitchen_blog/KitchenComment', 'KitchenCommentPublicController@getKitchenComment'); } ); } // API routes for kitchen_tag Route::prefix('{guard}/kitchen_blog')->group(function () { Route::get('kitchen_tag/form/{element}', 'KitchenTagAPIController@form'); Route::resource('kitchen_tag', 'KitchenTagAPIController'); }); // Public routes for kitchen_tag Route::get('kitchen_blogs/', 'KitchenTagPublicController@index'); Route::get('kitchen_blogs/{slug?}', 'KitchenTagPublicController@show'); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for kitchen_blogs Route::prefix('{guard}/kitchen_blog')->group(function () { Route::get('kitchen_tag/form/{element}', 'KitchenTagAPIController@form'); Route::apiResource('kitchen_tag', 'KitchenTagAPIController'); }); // Public routes for kitchen_blogs Route::get('kitchen_blog/KitchenTag', 'KitchenTagPublicController@getKitchenTag'); } ); }