> I would like to use a pretty path like new_article in order to route
> easily on a specific ressource.
> In my case, I had added this new action in my articles controller:
>
...
> In my routes.rb file, I just have this:
> map.resources :articles
>

easy one. you must define all non CRUD actions.
actions that work on articles in general (like index, require no
article id):

map.resources :articles, :collection => [:lock]

actions that work on single articles (require article id like show or
edit)
map.resources :articles, :member => [:lock]

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to