Sha256: ffd54a4a8b31628c2efe547294b57ded27d0b6464a110449d36416f95ec4578d
Contents?: true
Size: 1.09 KB
Versions: 24
Compression:
Stored size: 1.09 KB
Contents
class Ish::ImageAsset require 'aws-sdk' include Mongoid::Document include Mongoid::Timestamps include Mongoid::Paperclip belongs_to :location, class_name: 'Gameui::Map', inverse_of: :image, optional: true belongs_to :marker_image, class_name: 'Gameui::Map', inverse_of: :image, optional: true belongs_to :marker_title_image, class_name: 'Gameui::Map', inverse_of: :title_image, optional: true has_mongoid_attached_file :image, :styles => { :thumb => "100x100#", }, :storage => :s3, :s3_credentials => ::S3_CREDENTIALS, :path => "image_assets/:style/:id/:filename", :s3_protocol => 'https', :validate_media_type => false, s3_region: ::S3_CREDENTIALS[:region] validates_attachment_content_type :image, :content_type => ["image/jpg", "image/jpeg", "image/png", "image/gif", 'application/octet-stream' ] end
Version data entries
24 entries across 24 versions & 1 rubygems