map.resource :basket, :collection => { :checkout => :post }
The above does not work for the resource, as you would expect, since the basket is a resource (i.e. a singular), not a resource, so there is no concept of a collection, everything should be tied to current_user. In this case, the user has_one Basket.
However, I would like to specify a custom route without resorting to adding another line to the routes, for example:
map.checkout 'basket/checkout', :controller => 'baskets', :action => 'checkout'
Is it possible?
Of course, my other option is to add a check controller.
source
share