Class: SolidusFriendlyPromotions::MigrationSupport::OrderPromotionSyncer

Inherits:
Object
  • Object
show all
Defined in:
app/models/solidus_friendly_promotions/migration_support/order_promotion_syncer.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(order:) ⇒ OrderPromotionSyncer

Returns a new instance of OrderPromotionSyncer.



8
9
10
# File 'app/models/solidus_friendly_promotions/migration_support/order_promotion_syncer.rb', line 8

def initialize(order:)
  @order = order
end

Instance Attribute Details

#orderObject (readonly)

Returns the value of attribute order.



6
7
8
# File 'app/models/solidus_friendly_promotions/migration_support/order_promotion_syncer.rb', line 6

def order
  @order
end

Instance Method Details

#callObject



12
13
14
15
# File 'app/models/solidus_friendly_promotions/migration_support/order_promotion_syncer.rb', line 12

def call
  sync_spree_order_promotions_to_friendly_order_promotions
  sync_friendly_order_promotions_to_spree_order_promotions
end