Class: ActiveAdmin::BaseController
- Inherits:
-
InheritedResources::Base
- Object
- InheritedResources::Base
- ActiveAdmin::BaseController
- Includes:
- Menu
- Defined in:
- lib/active_admin/base_controller.rb,
lib/active_admin/base_controller/menu.rb
Overview
BaseController for ActiveAdmin. It implements ActiveAdmin controllers core features.
Direct Known Subclasses
Defined Under Namespace
Modules: Menu
Class Attribute Summary collapse
-
.active_admin_config ⇒ Object
Reference to the Resource object which initialized this controller.
Instance Method Summary collapse
-
#only_render_implemented_actions ⇒ Object
By default Rails will render un-implemented actions when the view exists.
Methods included from Menu
#current_menu, #set_current_tab
Class Attribute Details
.active_admin_config ⇒ Object
Reference to the Resource object which initialized this controller
21 22 23 |
# File 'lib/active_admin/base_controller.rb', line 21 def active_admin_config @active_admin_config end |
Instance Method Details
#only_render_implemented_actions ⇒ Object
By default Rails will render un-implemented actions when the view exists. Becuase Active Admin allows you to not render any of the actions by using the #actions method, we need to check if they are implemented.
27 28 29 |
# File 'lib/active_admin/base_controller.rb', line 27 def only_render_implemented_actions raise AbstractController::ActionNotFound unless action_methods.include?(params[:action]) end |