Sha256: fd4214b91f9f0d9b5e127672361b575cb6e5cbbb4ea0f4a873485c12b31e1023

Contents?: true

Size: 576 Bytes

Versions: 5

Compression:

Stored size: 576 Bytes

Contents

module Enjoy::Catalog
  module Models
    module Mongoid
      module ItemImage
        extend ActiveSupport::Concern
        # include Enjoy::MongoidPaperclip

        included do
          embedded_in :item, class_name: "Enjoy::Catalog::Item"
        end


        include ::Mongoid::EmbeddedFindable
        module ClassMethods
          def find(id)
            find_through(Enjoy::Catalog::Item, 'item_images', id)
          end
        end

        def image_styles
          Enjoy::Catalog.configuration.item_images_image_styles
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
enjoy_cms_catalog-0.3.2 lib/enjoy/catalog/models/mongoid/item_image.rb
enjoy_cms_catalog-0.3.1 lib/enjoy/catalog/models/mongoid/item_image.rb
enjoy_cms_catalog-0.3.0 lib/enjoy/catalog/models/mongoid/item_image.rb
enjoy_cms_catalog-0.2.0.1 lib/enjoy/catalog/models/mongoid/item_image.rb
enjoy_cms_catalog-0.2.0 lib/enjoy/catalog/models/mongoid/item_image.rb