Sha256: 5b8f729a0f21b387170fcccc5bfbbd203fc1c5ebf6298a00ca73c25f9b3fabb2

Contents?: true

Size: 481 Bytes

Versions: 12

Compression:

Stored size: 481 Bytes

Contents

# frozen_string_literal: true

class Occams::Cms::Categorization < ActiveRecord::Base
  self.table_name = 'occams_cms_categorizations'

  # -- Relationships -----------------------------------------------------------
  belongs_to :category
  belongs_to :categorized,
             polymorphic: true

  # -- Validations -------------------------------------------------------------
  validates :category_id,
            uniqueness: { scope: %i[categorized_type categorized_id] }
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
occams-1.1.0 app/models/occams/cms/categorization.rb
occams-1.0.8 app/models/occams/cms/categorization.rb
occams-1.0.7.3 app/models/occams/cms/categorization.rb
occams-1.0.7.2 app/models/occams/cms/categorization.rb
occams-1.0.7.1 app/models/occams/cms/categorization.rb
occams-1.0.7 app/models/occams/cms/categorization.rb
occams-1.0.6.1 app/models/occams/cms/categorization.rb
occams-1.0.6 app/models/occams/cms/categorization.rb
occams-1.0.5 app/models/occams/cms/categorization.rb
occams-1.0.4 app/models/occams/cms/categorization.rb
occams-1.0.3 app/models/occams/cms/categorization.rb
occams-1.0.2 app/models/occams/cms/categorization.rb