lib/administrate/page/show.rb in administrate-0.19.0 vs lib/administrate/page/show.rb in administrate-0.20.0

- old
+ new

@@ -13,11 +13,19 @@ def page_title dashboard.display_resource(resource) end def attributes - dashboard.show_page_attributes.map do |attr_name| - attribute_field(dashboard, resource, attr_name, :show) + attributes = dashboard.show_page_attributes + + if attributes.is_a? Array + attributes = { "" => attributes } + end + + attributes.transform_values do |attrs| + attrs.map do |attr_name| + attribute_field(dashboard, resource, attr_name, :show) + end end end end end end