Module: ActiveAdmin::Resource::PagePresenters
- Included in:
- Page, ActiveAdmin::Resource
- Defined in:
- lib/active_admin/resource/page_presenters.rb
Instance Method Summary collapse
-
#get_page_presenter(action) ⇒ Object
Returns a stored page config.
-
#page_presenters ⇒ Object
A hash of page configurations for the controller indexed by action name.
-
#set_page_presenter(action, page_presenter) ⇒ Object
Sets a page config for a given action.
Instance Method Details
#get_page_presenter(action) ⇒ Object
Returns a stored page config
22 23 24 |
# File 'lib/active_admin/resource/page_presenters.rb', line 22 def get_page_presenter(action) page_presenters[action.to_sym] end |
#page_presenters ⇒ Object
A hash of page configurations for the controller indexed by action name
6 7 8 |
# File 'lib/active_admin/resource/page_presenters.rb', line 6 def page_presenters @page_presenters ||= {} end |
#set_page_presenter(action, page_presenter) ⇒ Object
Sets a page config for a given action
14 15 16 |
# File 'lib/active_admin/resource/page_presenters.rb', line 14 def set_page_presenter(action, page_presenter) page_presenters[action.to_sym] = page_presenter end |