ROR will attempt to find routes from the top of the file first and then move on to the rest of the file. It would seem that you have listed projects twice:
map.resources :projects, :departments, :users, :admins, :imports, :notes
#Below is route in question
map.resources :projects, :collection => { :view_all => :get }
The first one (without the :collection) would be used.
#Below is route in question
map.resources :projects, :collection => { :view_all => :get }
Routes have preference based on their order of appearance. The first time you create routes for :projects, there's a show route like /projects/:id and that matches before the second one.
Since I've been learning rails, I thought that routes are the linking of
the "Controller" Object to their "Action" method.
When you set up RESTful routing, you need to add custom or named routes
after the default 7.
To set up custom or named routes, you use "map.connect" "path/to/view",
:controller => 'controller', :aciton => 'action'
Since I've been learning rails, I thought that routes are the
linking of the "Controller" Object to their "Action" method.
When you set up RESTful routing, you need to add custom or named
routes after the default 7.
To set up custom or named routes, you use "map.connect" "path/to/
view",
:controller => 'controller', :aciton => 'action'
Is this correct or am I lost?
Not lost, just not yet there. As you've no doubt seen from other
responses, you had :projects in BOTH places. Personally, I never
define more than one resource route at a time.