lib/active_merchant/billing/gateways/netbanx.rb in activemerchant-1.90.0 vs lib/active_merchant/billing/gateways/netbanx.rb in activemerchant-1.91.0
- old
+ new
@@ -53,9 +53,13 @@
def refund(money, authorization, options={})
post = {}
add_invoice(post, money, options)
+ # Setting merchantRefNumber to a unique id for each refund
+ # This is to support multiple partial refunds for the same order
+ post[:merchantRefNum] = SecureRandom.uuid
+
commit(:post, "settlements/#{authorization}/refunds", post)
end
def void(authorization, options={})
post = {}