我已经在我的“核心”引擎上安装了设备。注销链接为:core.destroy_user_session_path
我刚刚安装了active_admin。除注销链接外,大部分工作正常。在配置文件中,我发现了以下内容:
# == Logging Out
#
# Active Admin displays a logout link on each screen. These
# settings configure the location and method used for the link.
#
# This setting changes the path where the link points to. If it's
# a string, the strings is used as the path. If it's a Symbol, we
# will call the method to return the path.
#
# Default:
config.logout_link_path = "core.destroy_user_session_path".to_sym
# config.logout_link_path = "/core/users/sign_out" --> this works!
# This setting changes the http method used when rendering the
# link. For example :get, :delete, :put, etc..
#
# Default:
config.logout_link_method = :delete
我得到的错误信息是:
NoMethodError - undefined method `core.destroy_user_session_path' for #<ActiveAdmin::Views::TabbedNavigation:0x007f936dc8a8e0>:
arbre (1.0.1) lib/arbre/element.rb:177:in `method_missing'
/Users/krg07/.bundler/ruby/2.0.0/active_admin-a9949c152420/lib/active_admin/view_helpers/method_or_proc_helper.rb:56:in `call_method_or_proc_on'
有什么想法吗?我感觉它在“admin”命名空间中调用方法,因此无法找到该方法。如果是这种情况,我该如何解决这个问题?
谢谢!