Sha256: 7ae4dc2f5ed8f4f19afd3bef008ccd6bd6c74c3a3dfeae837983538e1093c5d7

Contents?: true

Size: 699 Bytes

Versions: 5

Compression:

Stored size: 699 Bytes

Contents

module Spree
  class Prototype < Spree::Base
    include Spree::Metadata
    if defined?(Spree::Webhooks::HasWebhooks)
      include Spree::Webhooks::HasWebhooks
    end

    has_many :property_prototypes, class_name: 'Spree::PropertyPrototype'
    has_many :properties, through: :property_prototypes, class_name: 'Spree::Property'

    has_many :option_type_prototypes, class_name: 'Spree::OptionTypePrototype'
    has_many :option_types, through: :option_type_prototypes, class_name: 'Spree::OptionType'

    has_many :prototype_taxons, class_name: 'Spree::PrototypeTaxon'
    has_many :taxons, through: :prototype_taxons, class_name: 'Spree::Taxon'

    validates :name, presence: true
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
spree_core-4.10.1 app/models/spree/prototype.rb
spree_core-4.10.0 app/models/spree/prototype.rb
spree_core-4.9.0 app/models/spree/prototype.rb
spree_core-4.8.3 app/models/spree/prototype.rb
spree_core-4.8.2 app/models/spree/prototype.rb