Class: SagePay::Server::Release

Inherits:
Command
  • Object
show all
Defined in:
lib/sage_pay/server/release.rb

Instance Attribute Summary collapse

Attributes inherited from Command

#mode, #vendor, #vendor_tx_code

Instance Method Summary collapse

Methods inherited from Command

decimal_accessor, #initialize, #response_from_response_body, #run!, #url

Constructor Details

This class inherits a constructor from SagePay::Server::Command

Instance Attribute Details

#security_keyObject

Returns the value of attribute security_key.



6
7
8
# File 'lib/sage_pay/server/release.rb', line 6

def security_key
  @security_key
end

#tx_auth_noObject

Returns the value of attribute tx_auth_no.



6
7
8
# File 'lib/sage_pay/server/release.rb', line 6

def tx_auth_no
  @tx_auth_no
end

#vps_tx_idObject

Returns the value of attribute vps_tx_id.



6
7
8
# File 'lib/sage_pay/server/release.rb', line 6

def vps_tx_id
  @vps_tx_id
end

Instance Method Details

#live_serviceObject



27
28
29
# File 'lib/sage_pay/server/release.rb', line 27

def live_service
  "release"
end

#post_paramsObject



18
19
20
21
22
23
24
25
# File 'lib/sage_pay/server/release.rb', line 18

def post_params
  super.merge({
    "VPSTxId" => vps_tx_id,
    "SecurityKey" => security_key,
    "TxAuthNo" => tx_auth_no,
    "ReleaseAmount" => ("%.2f" % release_amount)
  })
end

#simulator_serviceObject



31
32
33
# File 'lib/sage_pay/server/release.rb', line 31

def simulator_service
  "VendorReleaseTx"
end