Sha256: 4abb077c6ec7609ca9a3c3aeff5ee7e9081a87a4cc325d3fe34ff911e234253f

Contents?: true

Size: 1.01 KB

Versions: 3

Compression:

Stored size: 1.01 KB

Contents

Workarea.configure do |config|
  config.orderbot = ActiveSupport::Configurable::Configuration.new
  config.orderbot.api_timeout = 30
  config.orderbot.open_timeout = 30


  config.orderbot.transaction_id = {
    'ActiveMerchant::Billing::BogusGateway' => -> (transaction) { transaction.response.authorization },
    'ActiveMerchant::Billing::StripeGateway' => -> (transaction) { transaction.params['id'] },
    'ActiveMerchant::Billing::BraintreeBlueGateway' => -> (transaction) { transaction.response.params["braintree_transaction"]["order_id"] },
    'ActiveMerchant::Billing::MonerisGateway' => -> (transaction) { transaction.response.params["trans_id"] },
    'ActiveMerchant::Billing::AuthorizeNetCimGateway' => -> (transaction) { transaction.response.params["direct_response"]["transaction_id"] },
    'ActiveMerchant::Billing::CyberSourceGateway' => -> (transaction) { transaction.response.params["reasonCode"] },
    'ActiveMerchant::Billing::CheckoutV2Gateway' => -> (transaction) { transaction.response.params["id"]   }
  }
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
workarea-orderbot-1.0.2 config/initializers/workarea.rb
workarea-orderbot-1.0.1 config/initializers/workarea.rb
workarea-orderbot-1.0.0 config/initializers/workarea.rb