新手问题 为什么 controllers 下找不到这个文件?

kitt · April 08, 2013 · Last by raven replied at April 08, 2013 · 2401 hits

登录是用插件 Devise 做的,rake routes 下有这么一条路由 user_session POST /users/login(.:format) {:action=>"create",:controller=>"devise/sessions"}

这是后台信息 Started POST "/users/login" for 127.0.0.1 at 2013-04-08 10:51:56 +0800 Processing by Devise::SessionsController#create as HTML Parameters: {"utf8"=>"✓", "authenticity_token"=>"kxYtv8ApAjMF5VihexwYF+GbTD//2xe3OzGRzlyaWpg=", "user"=>{"login"=>"sdf", "password"=>"[FILTERED]"}}

可是在 controllers 下没有 devise 这个文件夹,也没有 sessions 这个文件。grep 整个 app 目录,也没找到 Devise::SessionsController 字符串。 这个 controller 到底在什么地方呢额

这个在 devise 的 gem 里面。

bundle open devise then you can find the file. :p

You need to Sign in before reply, if you don't have an account, please Sign up first.