Sha256: 71cde4b1bb41f0ebbd58917aaed2dd7b6e5d6a963c9345aed79f155b882240a3
Contents?: true
Size: 322 Bytes
Versions: 4
Compression:
Stored size: 322 Bytes
Contents
module Theblog class Post < ContentNode belongs_to :category, class_name: 'Theblog::Category', foreign_key: :parent_node_id validates_presence_of :title, :slug, :body validates_uniqueness_of :slug, scope: :type has_many :comments, class_name: 'Theblog::Comment', foreign_key: :parent_node_id end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
theblog-0.0.2.3 | app/models/theblog/post.rb |
theblog-0.0.2.2 | app/models/theblog/post.rb |
theblog-0.0.2.1 | app/models/theblog/post.rb |
theblog-0.0.2 | app/models/theblog/post.rb |