Sha256: 6063c6254b97810a03919bf2e33a2c4041636beb1ecaebb5f7e985dcf3f0cec3
Contents?: true
Size: 380 Bytes
Versions: 1
Compression:
Stored size: 380 Bytes
Contents
class EntityItem < ApplicationRecord belongs_to :entity, polymorphic: true belongs_to :taxon_item belongs_to :item belongs_to :list after_initialize if: :new_record? do |o| self.list_id = self.taxon_item.list_id self.item_id = self.taxon_item.item_id end def taxon_item _taxon_item = super _taxon_item.value = self.value _taxon_item end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rails_detail-0.0.1 | app/models/rails_detail/entity_item.rb |