Sha256: 455eb4ed363b60698849a3b53029801d63f2c54d29995b4956c1b17466ec2b0c

Contents?: true

Size: 383 Bytes

Versions: 12

Compression:

Stored size: 383 Bytes

Contents

module Phcpress
  class Modules::Category < ApplicationRecord

    # Relationships
    has_many :connections, class_name: 'Phcpress::Modules::Connection', dependent: :destroy
    has_many :posts, class_name: 'Phcpress::Modules::Category', :through => :connections

    # Validation for Form Fields
    validates :catname,
      presence: true,
      length: { minimum: 3 }

  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
phcpress-7.1.2 app/models/phcpress/modules/category.rb
phcpress-7.1.1 app/models/phcpress/modules/category.rb
phcpress-7.1.0 app/models/phcpress/modules/category.rb
phcpress-7.0.0 app/models/phcpress/modules/category.rb
phcpress-6.7.3 app/models/phcpress/modules/category.rb
phcpress-6.7.2 app/models/phcpress/modules/category.rb
phcpress-6.7.1 app/models/phcpress/modules/category.rb
phcpress-6.7.0 app/models/phcpress/modules/category.rb
phcpress-6.6.6 app/models/phcpress/modules/category.rb
phcpress-6.6.5 app/models/phcpress/modules/category.rb
phcpress-6.6.4 app/models/phcpress/modules/category.rb
phcpress-6.6.3 app/models/phcpress/modules/category.rb