Sha256: ef5eee36d5a056f89603869cc8f6a6f1ce46aefbf1e85245cc2bcf99a5495434
Contents?: true
Size: 593 Bytes
Versions: 2
Compression:
Stored size: 593 Bytes
Contents
module Phcpress class Articles::Post < ApplicationRecord # For Image Uploads mount_uploader :pstimage, Phcpress::PstimageUploader # Relationships has_many :connections, class_name: 'Phcpress::Modules::Connection', dependent: :destroy has_many :categories, class_name: 'Phcpress::Modules::Category', :through => :connections # Validation for Form Fields validates :psttitle, presence: true, length: { minimum: 3 } validates :psttext, presence: true, length: { minimum: 3 } validates :pststatus, presence: true end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
phcpress-8.0.0 | app/models/phcpress/articles/post.rb |
phcpress-8.0.0b | app/models/phcpress/articles/post.rb |