mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-08 23:54:29 -04:00
checkout.com wip refunds
This commit is contained in:
parent
f6f999b801
commit
6ffb2d7286
@ -273,4 +273,16 @@ class CheckoutComPaymentDriver extends BasePaymentDriver
|
||||
$company_gateway_token->save();
|
||||
}
|
||||
}
|
||||
|
||||
public function refund(Payment $payment, $amount)
|
||||
{
|
||||
$payment = new \Checkout\Models\Payments\Refund($payment->transaction_reference);
|
||||
$payment->amount = $amount;
|
||||
|
||||
try {
|
||||
$refund = $this->gateway->payments()->refund($payment);
|
||||
} catch (CheckoutHttpException $e) {
|
||||
// ..
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user