Mel*_*emi 3 authentication ruby-on-rails restful-authentication
通过clarkware的iphone-rails-tutorial工作,并尝试构建和运行包含的最终rails代码,但每当我尝试访问localhost时,我在服务器的控制台中都会收到此错误:3000 /
ActionController::RoutingError (uninitialized constant ApplicationController::Authentication):
app/controllers/application_controller.rb:5:in `<class:ApplicationController>'
app/controllers/application_controller.rb:1:in `<top (required)>'
app/controllers/goals_controller.rb:2:in `<top (required)>'
Rendered /Users/joeuser/.rvm/gems/ruby-1.9.2-p0@rails3/gems/actionpack-3.0.0/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (1.6ms)
Run Code Online (Sandbox Code Playgroud)
以前包含的示例代码的"里程碑"运行得很好.只有最后一个抛出错误......
这是什么意思?我没有想到的猜测是,有一种类型的认证宝石缺失,但我无法弄清楚哪一个.除了默认的rails&sqlite3-ruby之外,Gemfile中没有列出任何内容......并且文档中没有提及任何身份验证框架.
任何人都明白这个错误或熟悉教程,知道发生了什么?
我似乎无法找到与本教程相关的论坛,所以我想我会在这里查询.如果你知道一个,请指导我参加活动论坛.
Luk*_*ick 10
我已经看到这种情况发生在我创建了一个带有其中一个rails beta的应用程序,在我的情况下是beta3,然后将其更新为发布版本.为了使它工作,你可以尝试添加:
config.autoload_paths += %W(#{config.root}/lib)
Run Code Online (Sandbox Code Playgroud)
到你的config/application.rb.
因人而异
| 归档时间: |
|
| 查看次数: |
6005 次 |
| 最近记录: |