Sha256: 1a34479471ab8071bb9fced7f6e27f7e415babcbc4afe472c22a4869ec300e2e

Contents?: true

Size: 543 Bytes

Versions: 58

Compression:

Stored size: 543 Bytes

Contents

class Caboose::Post < ActiveRecord::Base
  self.table_name = "posts"
  
  has_many :post_category_memberships
  has_many :post_categories, :through => :post_category_memberships
  belongs_to :site
  
  attr_accessible :id,
    :site_id,
    :category_id, 
    :title, 
    :body, 
    :published,
    :created_at
  has_attached_file :image, 
    :path => 'posts/:id_:style.:extension', 
    :styles => {
      :tiny  => '75x75>',
      :thumb => '150x150>',
      :large => '400x400>'
    }
  do_not_validate_attachment_file_type :image

end

Version data entries

58 entries across 58 versions & 1 rubygems

Version Path
caboose-cms-0.4.131 app/models/caboose/post.rb
caboose-cms-0.4.130 app/models/caboose/post.rb
caboose-cms-0.4.129 app/models/caboose/post.rb
caboose-cms-0.4.128 app/models/caboose/post.rb
caboose-cms-0.4.127 app/models/caboose/post.rb
caboose-cms-0.4.126 app/models/caboose/post.rb
caboose-cms-0.4.125 app/models/caboose/post.rb
caboose-cms-0.4.124 app/models/caboose/post.rb
caboose-cms-0.4.123 app/models/caboose/post.rb
caboose-cms-0.4.122 app/models/caboose/post.rb
caboose-cms-0.4.121 app/models/caboose/post.rb
caboose-cms-0.4.120 app/models/caboose/post.rb
caboose-cms-0.4.119 app/models/caboose/post.rb
caboose-cms-0.4.118 app/models/caboose/post.rb
caboose-cms-0.4.117 app/models/caboose/post.rb
caboose-cms-0.4.116 app/models/caboose/post.rb
caboose-cms-0.4.115 app/models/caboose/post.rb
caboose-cms-0.4.114 app/models/caboose/post.rb