ActiveAdmin错误 - “admin / admin_users”的未定义方法`action_methods':字符串

时间:2011-11-06 03:01:35

标签: ruby-on-rails ruby-on-rails-3 activeadmin

导航到admin_users的ActiveAdmin资源时出现以下错误:

undefined method `action_methods' for "admin/admin_users":String

前几行痕迹:

activeadmin (0.3.2) lib/active_admin/resource/action_items.rb:51:in `block in add_default_action_items'
activeadmin (0.3.2) lib/active_admin/views/action_items.rb:9:in `instance_eval'
activeadmin (0.3.2) lib/active_admin/views/action_items.rb:9:in `block (2 levels) in build'
activeadmin (0.3.2) lib/active_admin/arbre/builder.rb:68:in `block in build_tag'
activeadmin (0.3.2) lib/active_admin/arbre/builder.rb:96:in `with_current_dom_context'
activeadmin (0.3.2) lib/active_admin/arbre/builder.rb:67:in `build_tag'
activeadmin (0.3.2) lib/active_admin/arbre/builder.rb:77:in `insert_tag'
activeadmin (0.3.2) lib/active_admin/arbre/html/element.rb:17:in `span'

我基本上只是遵循了http://railscasts.com/episodes/284-active-admin?view=asciicast

中列出的步骤

1 个答案:

答案 0 :(得分:4)

发现问题。在application_controller.rb中有一个名为@controller的实例变量。获得的经验......从不对变量使用保留关键字。