class ActiveAdmin::Views::Pages::Show
Public Instance Methods
attributes_table(*args, &block)
click to toggle source
# File lib/active_admin/views/pages/show.rb, line 27 def attributes_table(*args, &block) panel(I18n.t('active_admin.details', :model => active_admin_config.resource_label)) do attributes_table_for resource, *args, &block end end
config()
click to toggle source
Calls superclass method
# File lib/active_admin/views/pages/show.rb, line 6 def config active_admin_config.get_page_presenter(:show) || super end
main_content()
click to toggle source
# File lib/active_admin/views/pages/show.rb, line 18 def main_content if config.block # Eval the show config from the controller instance_exec resource, &config.block else default_main_content end end
title()
click to toggle source
# File lib/active_admin/views/pages/show.rb, line 10 def title if config[:title] render_or_call_method_or_proc_on(resource, config[:title]) else default_title end end
Protected Instance Methods
default_title()
click to toggle source
# File lib/active_admin/views/pages/show.rb, line 35 def default_title title = display_name(resource) if title.nil? || title.empty? || title == resource.to_s title = "#{active_admin_config.resource_label} ##{resource.id}" end title end