Module: Spree::SpreeChannable::ShipmentDecorator
- Defined in:
- app/models/spree/shipment_decorator.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.prepended(base) ⇒ Object
5 6 7 |
# File 'app/models/spree/shipment_decorator.rb', line 5 def self.prepended(base) base.state_machine.after_transition to: :shipped, do: :send_shipment_update end |
Instance Method Details
#channable_shipment ⇒ Object
16 17 18 19 20 21 22 |
# File 'app/models/spree/shipment_decorator.rb', line 16 def channable_shipment { tracking_code: tracking, tracking_url: tracking_url, transporter: shipping_method.channable_transporter_code }.to_json end |