Hi All! I have a router rules which looks like
$router = new \Phalcon\Mvc\Router(); //note that 'false' is ommitted to support default behavior
$router->add(
'/admin/settings/rename/{type}/{id}',
array(
'controller' => 'api',
'action' => 'rename'
)
);
So according to the sample above, I want all requests like '/admin/settings/rename/mytype/1' will be redirected to '/api/rename' with params 'type' and 'id', respectively. But it calls admin controller with settings action every time. 'AdminController' and 'ApiController' exists. I want only selected routes to redirect to 'ApiController' while others should go default way. How to override this concrete route and redirect it? I don't want to create 'renameAction' inside of 'AdminController' and forward request to 'ApiController'. Is it possible to override it using Router?