Read about our upcoming Code of Conduct on this issue

appearance.rb 416 Bytes
Newer Older
1
class Appearance < ActiveRecord::Base
2
3
4
5
  include CacheMarkdownField

  cache_markdown_field :description

6
7
8
9
10
11
12
13
  validates :title,       presence: true
  validates :description, presence: true
  validates :logo,        file_size: { maximum: 1.megabyte }
  validates :header_logo, file_size: { maximum: 1.megabyte }

  mount_uploader :logo,         AttachmentUploader
  mount_uploader :header_logo,  AttachmentUploader
end