8

我想添加“is_admin?” 过滤到 ActiveAdmin 初始化程序。我应该在哪个文件中定义“is_admin”?方法?

  # == Controller Filters
  #
  # You can add before, after and around filters to all of your
  # Active Admin resources from here. 
  #
  config.before_filter :is_admin?
4

1 回答 1

15

在你的 app/controllers/application_controller.rb

于 2011-09-20T13:33:51.443 回答