Class: Vpago::AcledaMobile::Base

Inherits:
Object
  • Object
show all
Includes:
PaymentAmountCalculator
Defined in:
lib/vpago/acleda_mobile/base.rb

Direct Known Subclasses

Checkout, TransactionStatus

Instance Method Summary collapse

Methods included from PaymentAmountCalculator

#amount, #amount_with_fee, #transaction_fee, #transaction_fee_fix, #transaction_fee_percentage

Constructor Details

#initialize(payment, options = {}) ⇒ Base

Returns a new instance of Base.



6
7
8
9
# File 'lib/vpago/acleda_mobile/base.rb', line 6

def initialize(payment, options = {})
  @options = options
  @payment = payment
end

Instance Method Details

#encryption_keyObject



15
16
17
# File 'lib/vpago/acleda_mobile/base.rb', line 15

def encryption_key
  @payment.payment_method.preferences[:data_encryption_key]
end

#partner_idObject



23
24
25
# File 'lib/vpago/acleda_mobile/base.rb', line 23

def partner_id
  @payment.payment_method.preferences[:partner_id]
end

#payment_numberObject



11
12
13
# File 'lib/vpago/acleda_mobile/base.rb', line 11

def payment_number
  @payment.number
end

#return_to_app_urlObject



19
20
21
# File 'lib/vpago/acleda_mobile/base.rb', line 19

def return_to_app_url
  @payment.payment_method.preferences[:app_url]
end