Hi
In my routes I have a
match ":controller/help", :action=>''help''
(Rake routes shows:
/:controller/help(.:format) :controller#help)
This will add a help action on every controller, including namespaced
controllers.
As Rails 4 will not be supporting ''match'' anymore I''m
converting these
routes to get, put, etc. No sweat, except for this route:
get '':controller/help'' (Rake routes shows: GET
/:controller/help(.:format)
:controller#help)
This route does not work on namespaced controllers, like:
namespace :admin do
myController
end
I tried declaring:
namespace :admin do
get '':controller/help''
myController
end
But rake routes is telling me: :controller segment is not allowed within a
namespace block
Is there another solution to this?
--
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to
rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit
https://groups.google.com/d/msg/rubyonrails-talk/-/t8X1Ni1gTw8J.
For more options, visit https://groups.google.com/groups/opt_out.
I think you need get '':controller/help'' and get '':namespace/:controller/help'' -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/groups/opt_out.
Worth trying! But unfortunately not working neither. But thanks! Op 28 feb 2013, om 12:10 heeft Pardeep Dhingra het volgende geschreven:> I think you need > > get '':controller/help'' > and > > get '':namespace/:controller/help'' > > -- > Posted via http://www.ruby-forum.com/. > > -- > You received this message because you are subscribed to a topic in the Google Groups "Ruby on Rails: Talk" group. > To unsubscribe from this topic, visit https://groups.google.com/d/topic/rubyonrails-talk/XSEIpeRHC68/unsubscribe?hl=en-US. > To unsubscribe from this group and all its topics, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > For more options, visit https://groups.google.com/groups/opt_out. > >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/groups/opt_out.