Sha256: 8914a2f4a6b424a0c0724cb5c99f31c4b12eb91ed1b67d5cc9da89671602f05d
Contents?: true
Size: 486 Bytes
Versions: 5
Compression:
Stored size: 486 Bytes
Contents
class Mercury::Image < ActiveRecord::Base self.table_name = :mercury_images has_attached_file :image, :styles => { :medium => "300x300>", :thumb => "100x100>" }, :path => ":rails_root/public/system/:attachment/:id/:style/:filename", :url => "/system/:attachment/:id/:style/:filename" delegate :url, :to => :image def serializable_hash(options = nil) options ||= {} options[:methods] ||= [] options[:methods] << :url super(options) end end
Version data entries
5 entries across 5 versions & 1 rubygems