module OffsitePayments::Integrations::Ecpay

Constants

PAYMENT_ALIPAY
PAYMENT_ATM
PAYMENT_BARCODE
PAYMENT_CREDIT_CARD
PAYMENT_CVS
PAYMENT_TYPE
SUBPAYMENT_ATM_BOT
SUBPAYMENT_ATM_CHINATRUST
SUBPAYMENT_ATM_ESUN
SUBPAYMENT_ATM_FIRST
SUBPAYMENT_ATM_FUBON
SUBPAYMENT_ATM_HUANAN
SUBPAYMENT_ATM_TAISHIN
SUBPAYMENT_CVS_CVS
SUBPAYMENT_CVS_FAMILY
SUBPAYMENT_CVS_HILIFE
SUBPAYMENT_CVS_IBON
SUBPAYMENT_CVS_OK

Public Class Methods

notification(post) click to toggle source
# File lib/offsite_payments/integrations/ecpay.rb, line 47
def self.notification(post)
  Notification.new(post)
end
service_url() click to toggle source
# File lib/offsite_payments/integrations/ecpay.rb, line 35
def self.service_url
  mode = ActiveMerchant::Billing::Base.mode
  case mode
    when :production
      'https://payment.ecpay.com.tw/Cashier/AioCheckOut/V5'
    when :development, :test
      'https://payment-stage.ecpay.com.tw/Cashier/AioCheckOut/V5'
    else
      raise StandardError, "Integration mode set to an invalid value: #{mode}"
  end
end
setup() { |self| ... } click to toggle source
# File lib/offsite_payments/integrations/ecpay.rb, line 51
def self.setup
  yield(self)
end