module OffsitePayments::Integrations::Spgateway

Constants

CHECK_CODE_FIELDS
CHECK_VALUE_FIELDS
CONFIG
RESPOND_TYPE
VERSION

Public Class Methods

notification(post) click to toggle source
# File lib/offsite_payments/integrations/spgateway.rb, line 42
def self.notification(post)
  Notification.new(post)
end
service_url() click to toggle source
# File lib/offsite_payments/integrations/spgateway.rb, line 28
def self.service_url
  mode = ActiveMerchant::Billing::Base.mode
  case mode
    when :production
      'https://core.spgateway.com/MPG/mpg_gateway'
    when :development
      'https://ccore.spgateway.com/MPG/mpg_gateway'
    when :test
      'https://ccore.spgateway.com/MPG/mpg_gateway'
    else
      raise StandardError, "Integration mode set to an invalid value: #{mode}"
  end
end
setup() { |self| ... } click to toggle source
# File lib/offsite_payments/integrations/spgateway.rb, line 46
def self.setup
  yield(self)
end