rock_rms 8.19.0 → 8.21.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 88e6953049bcdd78d9a65c9b9ff5612ae8c6b1f22392bfccdd5a28f080aef527
4
- data.tar.gz: 5e7bd216d1cd7b2de30ac06f8c87ac4382add7aafb2f9d7ac3f72e1be4b3fd62
3
+ metadata.gz: e1e0edb506babdff02df7b17a55d345d166e14e7c82d74a3851f2f7ced4bdc1e
4
+ data.tar.gz: 1366b2457dc65eda9a4700676c6bddd92bd13c5ac00a5a0885434a29d42144a9
5
5
  SHA512:
6
- metadata.gz: d42556144b3a25552a5811832e17446e5a754d564092ec817ca0bca689b1d197a0d2743ad862091d943e5cf341b9ff2e2fb380b19a4be3da755c63e7f1fba6f3
7
- data.tar.gz: 6ee5eac066128c770c3e3446b163da99ffabde40feaae718ed04a9dae338c7e8e5876d8c402eb82954c7797b568527138640ad3d134bf6673d2fb7fd6c7c0737
6
+ metadata.gz: 4c42841eb19d491c68faeb41d6793550bf8db7c638187f55a6668b7337bddc110f815e4f03b4b9a8df2fbdc4a0d913e1a6b08dee9947c6bd9dc47e7b661a534c
7
+ data.tar.gz: dd5c399cee1798dfd60a32be25d995d9e4cd0bdc2a883004ac11ed03fb4c8a08f713df2908c6af16bf7b787e526b325a71cd972a4f82f060cae15301158daa8d
@@ -6,12 +6,19 @@ module RockRMS
6
6
  Response::PaymentDetail.format(res)
7
7
  end
8
8
 
9
- def create_payment_detail(payment_type:, foreign_key: nil, card_type: nil, last_4: nil)
9
+ def create_payment_detail(
10
+ payment_type:,
11
+ foreign_key: nil,
12
+ card_type: nil,
13
+ last_4: nil,
14
+ currency_type_value_id: nil
15
+ )
10
16
  options = {
11
- 'CurrencyTypeValueId' => cast_payment_type(payment_type),
17
+ 'CurrencyTypeValueId' => currency_type_value_id || cast_payment_type(payment_type),
12
18
  'CreditCardTypeValueId' => cast_card_type(card_type),
13
19
  'ForeignKey' => foreign_key
14
20
  }
21
+
15
22
  options['AccountNumberMasked'] = "************#{last_4}" if last_4
16
23
 
17
24
  post(payment_detail_path, options)
@@ -20,6 +20,7 @@ module RockRMS
20
20
 
21
21
  transaction_amount = old_transaction[:details].map{|d| d[:amount]}.reduce(0.0){|sum,x| sum + x }
22
22
 
23
+
23
24
  refund_amount = amount || transaction_amount
24
25
 
25
26
  params = {
@@ -34,7 +35,8 @@ module RockRMS
34
35
  'TransactionDateTime' => date,
35
36
  'TransactionDetails' => refunded_details(old_transaction[:details], transaction_amount, refund_amount),
36
37
  'TransactionTypeValueId' => old_transaction[:transaction_type_id],
37
- 'SourceTypeValueId' => old_transaction[:source_type_id]
38
+ 'SourceTypeValueId' => old_transaction[:source_type_id],
39
+ 'ScheduledTransactionId' => old_transaction[:recurring_donation_id]
38
40
  }
39
41
  }
40
42
  post(refund_path, params)
@@ -1,3 +1,3 @@
1
1
  module RockRMS
2
- VERSION = '8.19.0'.freeze
2
+ VERSION = '8.21.0'.freeze
3
3
  end
@@ -71,6 +71,7 @@ RSpec.describe RockRMS::Client::Refund, type: :model do
71
71
  ],
72
72
  'TransactionTypeValueId' => 53,
73
73
  'SourceTypeValueId' => 10,
74
+ 'ScheduledTransactionId' => 1,
74
75
  'TransactionCode' => nil
75
76
  }
76
77
  }
@@ -123,6 +124,7 @@ RSpec.describe RockRMS::Client::Refund, type: :model do
123
124
  "EntityId" => nil
124
125
  }
125
126
  ],
127
+ 'ScheduledTransactionId' => 1,
126
128
  'TransactionTypeValueId' => 53,
127
129
  'SourceTypeValueId' => 10,
128
130
  'TransactionCode' => nil
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rock_rms
3
3
  version: !ruby/object:Gem::Version
4
- version: 8.19.0
4
+ version: 8.21.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Taylor Brooks
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-03-13 00:00:00.000000000 Z
11
+ date: 2024-04-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday