Sha256: ace19364491af38ec5ba0769d36a417559d945ad9a397d1f7ea9161746fb5256
Contents?: true
Size: 471 Bytes
Versions: 1
Compression:
Stored size: 471 Bytes
Contents
module Piggybak module ActsAsSellableWithSimpleVariants extend ActiveSupport::Concern module ClassMethods def acts_as_sellable_with_simple_variants has_many :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::ActsAsSellableWithSimpleVariants
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
piggybak_simple_variants-0.1.2 | lib/acts_as_sellable_with_simple_variants.rb |