class Image < ActiveRecord::Base belongs_to :item, :polymorphic => true # belongs_to :auction_item # belongs_to :item # acts_as_list :scope => :auction_item_id # acts_as_list :scope => :item_id # has_attachment :content_type => :image, # :size => 1.kilobyte..10.megabytes, # :thumbnails => { :thumb => [100, 100] }, # :storage => :s3 # validates_as_attachment # file_column :image, :magick => { # :versions => { :thumb => {:crop => "1:1", :size => "150x150!", :name => "thumb"}, # :normal => {:size => "400x300>"} # } # } end