Question: map.resources

Looking at various examples on how to define additional actions in
map.resources.
What I don’t see is do you add them all together or seperate lines.
Like:

map.resources :positions, :member => {:description => :get}
So if I wanted to add :collection => {:search => :get}, do I make a
comma
and add it in after the description => get or make a new line:

mp.resources :positions, :collection => {:search => :get} ?

Good question huh ?
TIA
Stuart


On 10/3/06, Dark A. [email protected] wrote:

Looking at various examples on how to define additional actions in
map.resources.
What I don’t see is do you add them all together or seperate lines. Like:

map.resources :positions, :member => {:description => :get}
So if I wanted to add :collection => {:search => :get}, do I make a comma
and add it in after the description => get or make a new line:

mp.resources :positions, :collection => {:search => :get} ?

These are options to a single method call declaring a resource, so
include
them in that call.
map.resources :positions, :member => {…}, :collection => {…}, :new
=>
{…}, …

jeremy

On 10/3/06, Jeremy K. [email protected] wrote:

comma and add it in after the description => get or make a new line:

Okay , thanks that helps to know. Now if someone call tell me how to
add
what I guess are non-rest actions to my controller ?

Stuart


This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs