Programming Language PHP
Namespace Oro\Component\Routing\Resolver
Class RouteCollectionAccessor
Method/Function append
Total Examples 1
1 code examples of PHP Oro\Component\Routing\Resolver\RouteCollectionAccessor::append extracted from open source projects
private function addTestRoutes(RouteCollectionAccessor $routes)
{
$routes->append(
'oro_rest_tests_override_path',
new Route(
'/api/testapicurrentdepartment',
[
'_controller' => RestApiController::class . '::itemAction',
'entity' => 'testapicurrentdepartments',
],
[],
[
'group' => 'rest_api',
'override_path' => '/api/testapicurrentdepartments/{id}',
]
)
);
$routes->append(
'oro_rest_tests_override_path_subresource',
new Route(
'/api/testapicurrentdepartment/{association}',
[
'_controller' => RestApiController::class . '::subresourceAction',
'entity' => 'testapicurrentdepartments',
],
[],
[
'group' => 'rest_api',
'override_path' => '/api/testapicurrentdepartments/{id}/{association}',
]
)
);
$routes->append(
'oro_rest_tests_override_path_relationship',
new Route(
'/api/testapicurrentdepartment/relationships/{association}',
[
'_controller' => RestApiController::class . '::relationshipAction',
'entity' => 'testapicurrentdepartments',
],
[],
[
'group' => 'rest_api',
'override_path' => '/api/testapicurrentdepartments/{id}/relationships/{association}',
]
)
);
$routes->append(
'oro_rest_tests_resource_without_identifier',
new Route(
'/api/testapiresourcewithoutidentifier',
[
'_controller' => RestApiController::class . '::itemWithoutIdAction',
'entity' => 'testapiresourcewithoutidentifier',
],
[],
[
'group' => 'rest_api',
]
)
);
}