Sha256: fb82315876c85828daa9186678e24c4fd03ccfd4b2bdc79f553f00d64747d1ef
Contents?: true
Size: 813 Bytes
Versions: 58
Compression:
Stored size: 813 Bytes
Contents
module ActiveAdmin class Resource module PagePresenters # A hash of page configurations for the controller indexed by action name def page_presenters @page_presenters ||= {} end # Sets a page config for a given action # # @param [String, Symbol] action The action to store this configuration for # @param [PagePresenter] page_presenter The instance of PagePresenter to store def set_page_presenter(action, page_presenter) page_presenters[action.to_sym] = page_presenter end # Returns a stored page config # # @param [Symbol, String] action The action to get the config for # @returns [PagePresenter, nil] def get_page_presenter(action) page_presenters[action.to_sym] end end end end
Version data entries
58 entries across 58 versions & 3 rubygems