lib/hancock/gallery/admin/image.rb in hancock_cms_gallery-1.0.0 vs lib/hancock/gallery/admin/image.rb in hancock_cms_gallery-1.0.2

- old
+ new

@@ -14,10 +14,11 @@ nav_label, without_gallery, fields = fields[:nav_label], nav_label, fields end Proc.new { navigation_label(!nav_label.blank? ? nav_label : I18n.t('hancock.gallery')) + field :enabled, :toggle do searchable false end unless without_gallery field :gallery do @@ -27,10 +28,12 @@ field :name, :string do searchable true end field :image, :hancock_image - group :caching, &Hancock::Admin.caching_block + if Hancock::Gallery.config.cache_support + group :caching, &Hancock::Cache::Admin.caching_block + end nested_set({max_depth: 1, scopes: []}) Hancock::RailsAdminGroupPatch::hancock_cms_group(self, fields)