This project is archived and is in readonly mode.
When routing creates a singular resource, it doesn't add itself to name_prefix
Reported by Eugene Pimenov | January 30th, 2010 @ 08:17 AM
Routing code:
resource :subscription do
get :renew
resources :cards
end
Generates these routes (irrelevant parts skipped):
GET /subscription/renew(.:format) {:action=>"renew", :controller=>"subscriptions"}
GET /subscription/cards(.:format) {:action=>"index", :controller=>"cards"}
cards POST /subscription/cards(.:format) {:action=>"create", :controller=>"cards"}
new_card GET /subscription/cards/new(.:format) {:action=>"new", :controller=>"cards"}
edit_card GET /subscription/cards/:id/edit(.:format) {:action=>"edit", :controller=>"cards"}
As you can see, there's no method for renew and cards methods aren't name prefixed.
Comments and changes to this ticket
-
José Valim April 30th, 2010 @ 03:16 PM
- State changed from new to duplicate
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>