2017-01-30 20:40:43 +01:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Ninja\PaymentDrivers;
|
2016-06-20 16:14:43 +02:00
|
|
|
|
|
|
|
class AuthorizeNetAIMPaymentDriver extends BasePaymentDriver
|
|
|
|
{
|
|
|
|
protected $transactionReferenceParam = 'refId';
|
2017-10-04 12:00:03 +02:00
|
|
|
|
|
|
|
protected function paymentDetails($paymentMethod = false)
|
|
|
|
{
|
|
|
|
$data = parent::paymentDetails();
|
|
|
|
$data['solutionId'] = $this->accountGateway->getConfigField('testMode') ? 'AAA100303' : 'AAA172036';
|
2017-10-18 15:35:00 +02:00
|
|
|
$data['invoiceNumber'] = $this->invoice()->invoice_number;
|
2017-10-04 12:00:03 +02:00
|
|
|
|
|
|
|
return $data;
|
|
|
|
}
|
2018-03-20 19:32:50 +01:00
|
|
|
|
|
|
|
public function createPayment($ref = false, $paymentMethod = null)
|
|
|
|
{
|
|
|
|
$ref = $this->purchaseResponse['transactionResponse']['transId'] ?: $this->purchaseResponse['refId'];
|
|
|
|
|
|
|
|
parent::createPayment($ref, $paymentMethod);
|
|
|
|
}
|
2016-06-20 16:14:43 +02:00
|
|
|
}
|