Class: Ogone::Ecommerce

Inherits:
Base
  • Object
show all
Defined in:
lib/ogone/ecommerce.rb

Constant Summary collapse

MANDATORY_PARAMETERS =
%w[PSPID ORDERID AMOUNT CURRENCY LANGUAGE].freeze
OUTBOUND_SIGNATURE_PARAMETERS =
%i[
  AAVADDRESS
  AAVCHECK
  AAVZIP
  ACCEPTANCE
  ALIAS
  AMOUNT
  BIN
  BRAND
  CARDNO
  CCCTY
  CN
  COMPLUS
  CREATION_STATUS
  CURRENCY
  CVCCHECK
  DCC_COMMPERCENTAGE
  DCC_CONVAMOUNT
  DCC_CONVCCY
  DCC_EXCHRATE
  DCC_EXCHRATESOURCE
  DCC_EXCHRATETS
  DCC_INDICATOR
  DCC_MARGINPERCENTAGE
  DCC_VALIDHOURS
  DIGESTCARDNO
  ECI
  ED
  ENCCARDNO
  FXAMOUNT
  FXCURRENCY
  IP
  IPCTY
  NBREMAILUSAGE
  NBRIPUSAGE
  NBRIPUSAGE_ALLTX
  NBRUSAGE
  NCERROR
  ORDERID
  PAYID
  PM
  SCO_CATEGORY
  SCORING
  STATUS
  SUBBRAND
  SUBSCRIPTION_ID
  TRXDATE
  VC
].freeze

Constants inherited from Base

Base::SIGNING_ALGORITHMS, Base::VALID_ENVIRONMENTS

Instance Attribute Summary

Attributes inherited from Base

#sha_in, #sha_out

Instance Method Summary collapse

Methods inherited from Base

#add_parameters, #add_single_return_url, #check_shasign_out!, #environment=, #fields_for_payment, #initialize, #sha_algo=, #upcase_keys

Constructor Details

This class inherits a constructor from Ogone::Base

Instance Method Details

#form_actionObject



62
63
64
65
66
67
# File 'lib/ogone/ecommerce.rb', line 62

def form_action
  unless VALID_ENVIRONMENTS.include? @environment.to_s
    raise ConfigurationError, "Unsupported Ogone environment: '#{@environment}'."
  end
  "https://secure.ogone.com/ncol/#{@environment}/orderstandard_utf8.asp"
end

#pspid=(pspid) ⇒ Object



57
58
59
60
# File 'lib/ogone/ecommerce.rb', line 57

def pspid=(pspid)
  super(pspid)
  @parameters[:PSPID] = pspid
end