scope equivalent in rails 2.3.x?
Posted
by
Jacob Relkin
on Stack Overflow
See other posts from Stack Overflow
or by Jacob Relkin
Published on 2010-11-22T19:45:34Z
Indexed on
2011/01/02
4:54 UTC
Read the original article
Hit count: 163
ruby-on-rails
Is there a way to generate a group of routes under an admin
scope without having to create a new physical directory (like namespace
requires you to).
I know that in Rails 3 there is a scope
method on the route mapper, and this appears to do what I want, but apparently it doesn't exist in Rails 2.3.x
My goal is to have a route like this: "/admin/products"
map to "app/controllers/products_controller
, not "app/controllers/admin/products_controller"
.
Is there any way to accomplish this in Rails 2.3.x?
© Stack Overflow or respective owner