Sha256: 833b49968cd095411296e37cd187fbfa04d8b7f172f55510d303c27506f20c61
Contents?: true
Size: 464 Bytes
Versions: 4
Compression:
Stored size: 464 Bytes
Contents
module SpreeItIsAPresent module Spree module OrderDecorator extend ActiveSupport::Concern prepended do has_one :present_note, class_name: 'Spree::PresentNote', dependent: :destroy accepts_nested_attributes_for :present_note, reject_if: :all_blank end def present_note_with_default present_note || build_present_note end end end end Spree::Order.prepend SpreeItIsAPresent::Spree::OrderDecorator
Version data entries
4 entries across 4 versions & 1 rubygems