Authlogic管理员子网站

时间:2010-05-01 12:10:21

标签: ruby-on-rails authlogic admin

在此tutorial之后出现以下错误:

 NameError in Admin/dashboardsController#show

uninitialized constant Admin::DashboardsController



 NameError in Admin sessionController#new

uninitialized constant Admin::AdminHelper

不确定如何纠正这个问题!

1 个答案:

答案 0 :(得分:1)

确保您有正确的

  1. Admin :: WhateverController 位于 RAILS_ROOT / app / controllers / admin / 目录下。
  2. Admin :: WhateverHelper 位于 RAILS_ROOT / app / helpers / admin / 目录
  3. Admin :: WhateverController 应命名为 dashboards_controller.rb
  4. Admin :: WhateverHelper 应命名为 dashboards_helper.rb