mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Fixes for pay trace integration
This commit is contained in:
parent
043f0816f1
commit
86ca60afa7
@ -94,7 +94,7 @@ class CreditCard
|
|||||||
'customer_id' => Str::random(32),
|
'customer_id' => Str::random(32),
|
||||||
'hpf_token' => $data['HPF_Token'],
|
'hpf_token' => $data['HPF_Token'],
|
||||||
'enc_key' => $data['enc_key'],
|
'enc_key' => $data['enc_key'],
|
||||||
'integrator_id' => '959195xd1CuC',
|
'integrator_id' => $this->company_gateway->getConfigField('integratorId'),
|
||||||
'billing_address' => $this->buildBillingAddress(),
|
'billing_address' => $this->buildBillingAddress(),
|
||||||
];
|
];
|
||||||
|
|
||||||
@ -123,7 +123,7 @@ class CreditCard
|
|||||||
private function getCustomerProfile($customer_id)
|
private function getCustomerProfile($customer_id)
|
||||||
{
|
{
|
||||||
$profile = $this->paytrace_driver->gatewayRequest('/v1/customer/export', [
|
$profile = $this->paytrace_driver->gatewayRequest('/v1/customer/export', [
|
||||||
'integrator_id' => '959195xd1CuC',
|
'integrator_id' => $this->company_gateway->getConfigField('integratorId'),
|
||||||
'customer_id' => $customer_id,
|
'customer_id' => $customer_id,
|
||||||
// 'include_bin' => true,
|
// 'include_bin' => true,
|
||||||
]);
|
]);
|
||||||
@ -171,7 +171,7 @@ class CreditCard
|
|||||||
$data = [
|
$data = [
|
||||||
'hpf_token' => $response_array['HPF_Token'],
|
'hpf_token' => $response_array['HPF_Token'],
|
||||||
'enc_key' => $response_array['enc_key'],
|
'enc_key' => $response_array['enc_key'],
|
||||||
'integrator_id' => '959195xd1CuC',
|
'integrator_id' => $this->company_gateway->getConfigField('integratorId'),
|
||||||
'billing_address' => $this->buildBillingAddress(),
|
'billing_address' => $this->buildBillingAddress(),
|
||||||
'amount' => $request->input('amount_with_fee'),
|
'amount' => $request->input('amount_with_fee'),
|
||||||
'invoice_id' => $this->harvestInvoiceId(),
|
'invoice_id' => $this->harvestInvoiceId(),
|
||||||
@ -191,7 +191,7 @@ class CreditCard
|
|||||||
|
|
||||||
$data = [
|
$data = [
|
||||||
'customer_id' => $request->token,
|
'customer_id' => $request->token,
|
||||||
'integrator_id' => '959195xd1CuC',
|
'integrator_id' => $this->company_gateway->getConfigField('integratorId'),
|
||||||
'amount' => $request->input('amount_with_fee'),
|
'amount' => $request->input('amount_with_fee'),
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -133,7 +133,7 @@ class PaytracePaymentDriver extends BaseDriver
|
|||||||
|
|
||||||
$data = [
|
$data = [
|
||||||
'customer_id' => $cgt->token,
|
'customer_id' => $cgt->token,
|
||||||
'integrator_id' => '959195xd1CuC',
|
'integrator_id' => $this->company_gateway->getConfigField('integratorId'),
|
||||||
'amount' => $amount,
|
'amount' => $amount,
|
||||||
];
|
];
|
||||||
|
|
||||||
@ -183,10 +183,8 @@ class PaytracePaymentDriver extends BaseDriver
|
|||||||
$url = 'https://api.paytrace.com/oauth/token';
|
$url = 'https://api.paytrace.com/oauth/token';
|
||||||
$data = [
|
$data = [
|
||||||
'grant_type' => 'password',
|
'grant_type' => 'password',
|
||||||
'username' => config('ninja.testvars.paytrace.username'),
|
'username' => $this->company_gateway->getConfigField('username'),
|
||||||
'password' => config('ninja.testvars.paytrace.password'),
|
'password' => $this->company_gateway->getConfigField('password')
|
||||||
//'username' => $this->company_gateway->getConfigField('username'),
|
|
||||||
//'password' => $this->company_gateway->getConfigField('password')
|
|
||||||
];
|
];
|
||||||
|
|
||||||
$response = CurlUtils::post($url, $data, $headers = false);
|
$response = CurlUtils::post($url, $data, $headers = false);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user