Sha256: f766d89b5adee009aea5b50cd364719860da5b7f78a779e8f1b7affc15f22a6d
Contents?: true
Size: 605 Bytes
Versions: 6
Compression:
Stored size: 605 Bytes
Contents
module Phcpresspro class Articles::Post < ApplicationRecord # For Image Uploads mount_uploader :pstimage, Phcpresspro::PstimageUploader # Relationships has_many :connections, class_name: 'Phcpresspro::Modules::Connection', dependent: :destroy has_many :categories, class_name: 'Phcpresspro::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
6 entries across 6 versions & 1 rubygems