Finding the calling controller/action in Rails
Like request.referer, I want to know from which controller/action the user is coming from. Is there a method do to this? All I开发者_开发问答 could think of is to use a flash, any better method?
Rails.application.routes.recognize_path(request.referer)[:action]
精彩评论