Skip to content

Commit 1fe7753

Browse files
committed
Merge pull request #4 from the-swede/master
Update config.rb
2 parents ea0c437 + e6de3e6 commit 1fe7753

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

lib/payson_api/config.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ module PaysonAPI
1414
LOCALES = %w[SV EN FI]
1515
CURRENCIES = %w[SEK EUR]
1616
FEES_PAYERS = %w[EACHRECEIVER SENDER PRIMARYRECEIVER SECONDARYONLY]
17-
FUNDING_CONSTRAINTS = %w[CREDITCARD BANK INVOICE]
17+
FUNDING_CONSTRAINTS = %w[CREDITCARD BANK INVOICE SMS]
1818
GUARANTEE_OFFERINGS = %w[OPTIONAL REQUIRED NO]
1919
PAYMENT_STATUSES = %w[CREATED PENDING PROCESSING COMPLETED CREDITED
2020
INCOMPLETE ERROR EXPIRED REVERSALERROR ABORTED]

lib/payson_api/request/payment.rb

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,16 @@ module Request
33
class Payment
44
attr_accessor :return_url, :cancel_url, :ipn_url, :memo, :sender, :receivers,
55
:locale, :currency, :tracking_id, :invoice_fee, :order_items, :fundings,
6-
:fees_payer, :guarantee_offered
6+
:fees_payer, :guarantee_offered, :custom
77

8-
def initialize(return_url, cancel_url, ipn_url, memo, sender, receivers)
8+
def initialize(return_url, cancel_url, ipn_url, memo, sender, receivers, custom)
99
@return_url = return_url
1010
@cancel_url = cancel_url
1111
@ipn_url = ipn_url
1212
@memo = memo
1313
@sender = sender
1414
@receivers = receivers
15+
@custom = custom
1516
end
1617

1718
def to_hash
@@ -33,6 +34,7 @@ def to_hash
3334
hash['ipnNotificationUrl'] = @ipn_url if @ipn_url
3435
hash['invoiceFee'] = @invoice_fee if @invoice_fee
3536
hash['trackingId'] = @tracking_id if @tracking_id
37+
hash['custom'] = @custom if @custom
3638
end
3739
end
3840

0 commit comments

Comments
 (0)