Witam
W routes.rb mam:
ActionController::Routing::Routes.draw do |map|
map.resources :employees
map.resources :departments, :has_many => :employees
map.root :controller => “welcome”
map.connect ‘:controller/:action/:id’
map.connect ‘:controller/:action/:id.:format’
end
natomiast po rake routes widze ze:
department_employees GET uzywa contorllera : employees i action index, a chcialbym aby action bylo department_employees?
Jak to osiągnąć?
Dodawałem na końcu map.resources :departments, :has_many => :employees
:action => ‘department_employees’ ale bez efektu.
Pozdrawiam
Sebastian