ruby on rails - Nested Resource Routing -
resources :patients collection 'new_import' post 'import' end
how can have following urls?
/patients/import (get) -->action: new_import /patients/import (post) --> action: import
right urls are:
/patients/new_import (get) -->action: new_import /patients/import (post) --> action: import
i must able without doing:
match 'patients/import' => 'patients#new_import', :via => :get match 'patients/import' => 'patients#import', :via => :post
resources :patients collection 'import' => :new_import post 'import' => :import end end
Comments
Post a Comment