Sha256: 239910afbb3c0c93add1ac7cca22b683a46e76d28b9761a8ad62609074132aad
Contents?: true
Size: 500 Bytes
Versions: 6
Compression:
Stored size: 500 Bytes
Contents
require 'paperclip' class WikiPageAttachment < ActiveRecord::Base acts_as_wiki_page_attachment do has_attached_file :wiki_page_attachment, :styles => { :medium => "300x300>", :thumb => "100x100>" } validates_attachment_presence :wiki_page_attachment, :message => " is missing." validates_attachment_content_type :wiki_page_attachment, :content_type => ['image/jpeg','image/jpg','image/png','image/x-png','image/gif','image/pjpeg'], :message => ' must be a JPEG, PNG or GIF.' end end
Version data entries
6 entries across 6 versions & 2 rubygems