Sha256: f45948904bbc006edcdc9170a3a3d50caaa995d3b058b48f5a6e468c527dee2a
Contents?: true
Size: 616 Bytes
Versions: 10
Compression:
Stored size: 616 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
10 entries across 10 versions & 1 rubygems