Fixes for square token billing

This commit is contained in:
David Bomba 2021-11-27 11:46:28 +11:00
parent 8916c57777
commit 3a04c9097d

View File

@ -136,6 +136,7 @@ class SquarePaymentDriver extends BaseDriver
$amount_money->setCurrency($this->client->currency()->code); $amount_money->setCurrency($this->client->currency()->code);
$body = new \Square\Models\CreatePaymentRequest($cgt->token, \Illuminate\Support\Str::random(32), $amount_money); $body = new \Square\Models\CreatePaymentRequest($cgt->token, \Illuminate\Support\Str::random(32), $amount_money);
$body->setCustomerId($cgt->gateway_customer_reference);
/** @var ApiResponse */ /** @var ApiResponse */
$response = $this->square->getPaymentsApi()->createPayment($body); $response = $this->square->getPaymentsApi()->createPayment($body);