Class: ActiveMerchant::Billing::SageVirtualCheckGateway

Inherits:
Gateway
  • Object
show all
Includes:
SageCore
Defined in:
lib/active_merchant/billing/gateways/sage/sage_virtual_check.rb

Overview

:nodoc:

Constant Summary

Constant Summary

Constants included from SageCore

ActiveMerchant::Billing::SageCore::TRANSACTIONS

Constants inherited from Gateway

Gateway::CREDIT_DEPRECATION_MESSAGE, Gateway::CURRENCIES_WITHOUT_FRACTIONS, Gateway::DEBIT_CARDS

Instance Attribute Summary

Attributes inherited from Gateway

#options

Instance Method Summary (collapse)

Methods included from SageCore

included, #initialize

Methods inherited from Gateway

#card_brand, card_brand, inherited, #initialize, supports?, #test?

Methods included from CreditCardFormatting

#format

Instance Method Details

- (Object) credit(money, credit_card, options = {})



24
25
26
27
# File 'lib/active_merchant/billing/gateways/sage/sage_virtual_check.rb', line 24

def credit(money, credit_card, options = {})
  deprecated CREDIT_DEPRECATION_MESSAGE
  refund(money, source, options)
end

- (Object) purchase(money, credit_card, options = {})



10
11
12
13
14
15
16
# File 'lib/active_merchant/billing/gateways/sage/sage_virtual_check.rb', line 10

def purchase(money, credit_card, options = {})
  post = {}
  add_check(post, credit_card)
  add_check_customer_data(post, options)
  add_transaction_data(post, money, options)
  commit(:purchase, post)
end

- (Object) refund(money, credit_card, options = {})



29
30
31
32
33
34
35
# File 'lib/active_merchant/billing/gateways/sage/sage_virtual_check.rb', line 29

def refund(money, credit_card, options = {})
  post = {}
  add_check(post, credit_card)
  add_check_customer_data(post, options)
  add_transaction_data(post, money, options)
  commit(:credit, post)
end

- (Object) void(reference, options = {})



18
19
20
21
22
# File 'lib/active_merchant/billing/gateways/sage/sage_virtual_check.rb', line 18

def void(reference, options = {})
  post = {}
  add_reference(post, reference)
  commit(:void, post)
end