On Thu, May 27, 2010 at 2:49 PM, Chris Apolzon <[email protected]> wrote: > Not a horrible solution. My custom actions were really more like filters, > so I ended up amending the hobo index action to apply a filter from > params[:state] > > On Thu, May 27, 2010 at 1:34 PM, kevinpfromnm <[email protected]> > wrote: >> >> Given your troubles, you might want to remove the automatic hobo >> routes and manually specify them. A little ugly but will let you >> specify the order of routing exactly. >> >> On May 27, 10:05 am, Chris Apolzon <[email protected]> wrote: >> > So....I'm really having trouble with this. If I try flip-flopping the >> > route >> > declarations, I either get errors from dryml (<index-page/>) because the >> > path methods/variables are missing or the route is misinterpreted as a >> > show >> > route (with an id of 'received' -- my custom route). This has all led >> > me to >> > read the model_router.rb file in the Hobo gem. The comment regarding >> > ticket >> > #251 for disambiguating nil ids (and #252 which is marked wontfix). Is >> > this >> > likely related or am I barking up the wrong tree? >> > >> > On Wed, May 26, 2010 at 4:48 PM, Chris Apolzon <[email protected]> >> > wrote: >> > > Quick follow-up: Yes, this workaround does break all the existing >> > > chris# >> > > routes so I would love to hear how to declare the lifecycle routes >> > > manually. >> > >> > > On Wed, May 26, 2010 at 4:24 PM, Chris Apolzon <[email protected]> >> > > wrote: >> > >> > >> As it turns out, if you try to define some custom routes for a model >> > >> with a lifecycle: >> > >> > >> map.resources :manuscripts, :collection => { :chris1 => :get, >> > >> :chris2 => :get, >> > >> :chris3 => :get, >> > >> :chris4 => :get, >> > >> :chris5 => :get >> > >> }
Apologies for not getting back sooner. The easiest way to get actions like this added to the routes is to declare the actions with index_action in the controller: def chris1 ... end becomes: index_action :chris1 do ... end --Matt Jones -- You received this message because you are subscribed to the Google Groups "Hobo Users" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/hobousers?hl=en.
