Skip to content

Instantly share code, notes, and snippets.

@kuon
Created September 30, 2012 10:01
Show Gist options
  • Select an option

  • Save kuon/3806377 to your computer and use it in GitHub Desktop.

Select an option

Save kuon/3806377 to your computer and use it in GitHub Desktop.
Adding nested routes on the same controller
resources :users do
put 'parents/:parent_id', :action => 'add_parent', :as => 'parents'
delete 'parents/:parent_id', :action => 'remove_parent'
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment