group(function () { Route::resource('comment', 'CommentResourceController'); }); // Public routes for comment Route::get('pms/', 'CommentPublicController@index'); Route::get('pms/{slug?}', 'CommentPublicController@show'); 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', 'CommentResourceController'); }); // Public routes for pages Route::get('pms/', 'CommentPublicController@index'); Route::get('pms/{slug?}', 'CommentPublicController@show'); } ); } // web routes for page Route::prefix('{guard}/pm')->group(function () { Route::resource('page', 'PageResourceController'); }); // Public routes for page Route::get('pms/', 'PagePublicController@index'); Route::get('pms/{slug?}', 'PagePublicController@show'); 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', 'PageResourceController'); }); // Public routes for pages Route::get('pms/', 'PagePublicController@index'); Route::get('pms/{slug?}', 'PagePublicController@show'); } ); } // web routes for project Route::prefix('{guard}/pm')->group(function () { Route::resource('project', 'ProjectResourceController'); }); // Public routes for project Route::get('pms/', 'ProjectPublicController@index'); Route::get('pms/{slug?}', 'ProjectPublicController@show'); 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', 'ProjectResourceController'); }); // Public routes for pages Route::get('pms/', 'ProjectPublicController@index'); Route::get('pms/{slug?}', 'ProjectPublicController@show'); } ); } // web routes for roadmap Route::prefix('{guard}/pm')->group(function () { Route::resource('roadmap', 'RoadmapResourceController'); }); // Public routes for roadmap Route::get('pms/', 'RoadmapPublicController@index'); Route::get('pms/{slug?}', 'RoadmapPublicController@show'); 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', 'RoadmapResourceController'); }); // Public routes for pages Route::get('pms/', 'RoadmapPublicController@index'); Route::get('pms/{slug?}', 'RoadmapPublicController@show'); } ); } // web routes for sprint Route::prefix('{guard}/pm')->group(function () { Route::resource('sprint', 'SprintResourceController'); }); // Public routes for sprint Route::get('pms/', 'SprintPublicController@index'); Route::get('pms/{slug?}', 'SprintPublicController@show'); 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', 'SprintResourceController'); }); // Public routes for pages Route::get('pms/', 'SprintPublicController@index'); Route::get('pms/{slug?}', 'SprintPublicController@show'); } ); } // web routes for worklog Route::prefix('{guard}/pm')->group(function () { Route::resource('worklog', 'WorklogResourceController'); }); // Public routes for worklog Route::get('pms/', 'WorklogPublicController@index'); Route::get('pms/{slug?}', 'WorklogPublicController@show'); 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', 'WorklogResourceController'); }); // Public routes for pages Route::get('pms/', 'WorklogPublicController@index'); Route::get('pms/{slug?}', 'WorklogPublicController@show'); } ); }