From dbe9ceab516529f5610cb44ca23fde634442af03 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Tue, 28 Dec 2021 20:29:42 +1100 Subject: [PATCH] minor fixes --- app/Import/Transformers/Zoho/InvoiceTransformer.php | 2 +- app/PaymentDrivers/WePayPaymentDriver.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Import/Transformers/Zoho/InvoiceTransformer.php b/app/Import/Transformers/Zoho/InvoiceTransformer.php index 49a416bd422c..0c9ad7a82e1c 100644 --- a/app/Import/Transformers/Zoho/InvoiceTransformer.php +++ b/app/Import/Transformers/Zoho/InvoiceTransformer.php @@ -57,7 +57,7 @@ class InvoiceTransformer extends BaseTransformer { $line_items[] = [ 'product_key' => $this->getString( $record, 'Item Name' ), 'notes' => $this->getString( $record, 'Item Description' ), - 'cost' => $this->getFloat( $record, 'Item Price' ), + 'cost' => round($this->getFloat( $record, 'Item Price' ),2), 'quantity' => $this->getFloat( $record, 'Quantity' ), 'discount' => $this->getString( $record, 'Discount Amount' ), 'is_amount_discount' => true, diff --git a/app/PaymentDrivers/WePayPaymentDriver.php b/app/PaymentDrivers/WePayPaymentDriver.php index a0009fb6cd4b..748299e49e16 100644 --- a/app/PaymentDrivers/WePayPaymentDriver.php +++ b/app/PaymentDrivers/WePayPaymentDriver.php @@ -116,7 +116,7 @@ class WePayPaymentDriver extends BaseDriver $data['gateway'] = $this->wepay; $client = $data['client']; - $contact = $client->primary_contact()->first() ? $client->primary_contact()->first() : $lient->contacts->first(); + $contact = $client->primary_contact()->first() ? $client->primary_contact()->first() : $client->contacts->first(); $data['contact'] = $contact; return $this->payment_method->authorizeView($data);