Sha256: a7d3e29c3474409188ff2ce961ea83e2329f4782646fbca2ca554e127d175933

Contents?: true

Size: 437 Bytes

Versions: 4

Compression:

Stored size: 437 Bytes

Contents

module Workarea
  module Listrak
    class OrderExporter
      include Sidekiq::Worker
      include Sidekiq::CallbacksWorker

      sidekiq_options(
        enqueue_on: {
          Workarea::Order => :place
        }
      )

      def perform(order_id)
        order = Workarea::Order.find order_id

        order_form = Listrak::Models::OrderForm.new order

        Listrak.data.orders.import [order_form]
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
workarea-listrak-5.0.4 app/workers/workarea/listrak/order_exporter.rb
workarea-listrak-5.0.3 app/workers/workarea/listrak/order_exporter.rb
workarea-listrak-5.0.2 app/workers/workarea/listrak/order_exporter.rb
workarea-listrak-5.0.1 app/workers/workarea/listrak/order_exporter.rb