Sha256: e526626c20d7b5876bfeb3153c1dbf1ff310f8dae7d021d600493b0c05d3a7e2
Contents?: true
Size: 414 Bytes
Versions: 37
Compression:
Stored size: 414 Bytes
Contents
module Piggybak module ActsAsSellable extend ActiveSupport::Concern module ClassMethods def acts_as_sellable has_one :piggybak_sellable, :as => "item", :class_name => "::Piggybak::Sellable", :inverse_of => :item accepts_nested_attributes_for :piggybak_sellable, :allow_destroy => true end end end end ::ActiveRecord::Base.send :include, Piggybak::ActsAsSellable
Version data entries
37 entries across 37 versions & 1 rubygems