Currently I have a REST route working for an Event controller (/event). I would like to handle Event SignUps in an EventSignUp controller, and map this controller to a /event/signups route.
The Zend Framework documentation states that the URL /event/signup/:id should map to an Event_SignupController. But this does not work for me.
I set up the default REST route for all controllers in my Bootstrap class:
$front = Zend_Controller_Front::getInstance();
$router = $front->getRouter();
// Specifying all controllers as RESTful:
$restRoute = new Zend_Rest_Route($front);
$router->addRoute('default', $restRoute);
Am I missing something or is the documentation just wrong? If the documentation is wrong, what approach should I take to achieve my desired goal?
As a side note, a lot of existing controllers rely on the default REST route, so it would be nice if there is a solution that does not require to implement new routes for all existing controllers.
Edit: The documentation states that /product/ratings will be translated to the Product_RatingsController, which means the RatingsController in the Products module. Because all my controllers are placed in the default module, my desired behavior is not supported by the Rest Route.
So this changes my question, is it possible to achieve my desired behavior without affecting the existing controllers dependency on the default Rest route? If so, how? And if not, what would be the best approach for me to take?