Sha256: a69dfaac2e26c1a1e4a95b3a5dd0ae74c467d126de2bbcef1cc8145730621382
Contents?: true
Size: 366 Bytes
Versions: 58
Compression:
Stored size: 366 Bytes
Contents
module Tenon class ItemAsset < ActiveRecord::Base # Validations validates_presence_of :asset # Relationships belongs_to :asset belongs_to :item, polymorphic: true accepts_nested_attributes_for :asset after_save :reprocess_asset def reprocess_asset asset.reload.attachment.reprocess! if asset_id_changed? end end end
Version data entries
58 entries across 58 versions & 1 rubygems