diff --git a/app/DataMapper/Analytics/TrialFinished.php b/app/DataMapper/Analytics/TrialFinished.php new file mode 100644 index 0000000000..423b52a1f0 --- /dev/null +++ b/app/DataMapper/Analytics/TrialFinished.php @@ -0,0 +1,51 @@ +hasMany(Task::class); } - public function expenses() + public function expense() { - return $this->hasMany(Expense::class); + return $this->hasOne(Expense::class); } /** * Service entry points. diff --git a/app/PaymentDrivers/Eway/CreditCard.php b/app/PaymentDrivers/Eway/CreditCard.php index afed807687..ab85688fe5 100644 --- a/app/PaymentDrivers/Eway/CreditCard.php +++ b/app/PaymentDrivers/Eway/CreditCard.php @@ -160,7 +160,6 @@ class CreditCard 'TotalAmount' => $this->convertAmountForEway(), 'CurrencyCode' => $this->eway_driver->client->currency()->code, 'InvoiceNumber' => $invoice_numbers, - 'InvoiceDescription' => $description, 'InvoiceReference' => $description, ], 'TransactionType' => \Eway\Rapid\Enum\TransactionType::PURCHASE, diff --git a/resources/views/portal/ninja2020/components/entity-documents.blade.php b/resources/views/portal/ninja2020/components/entity-documents.blade.php index 16ee960efc..0273f15889 100644 --- a/resources/views/portal/ninja2020/components/entity-documents.blade.php +++ b/resources/views/portal/ninja2020/components/entity-documents.blade.php @@ -1,4 +1,4 @@ -@if ($entity->documents->count() > 0 || $entity->company->documents->count() > 0) +@if ($entity->documents->count() > 0 || $entity->company->documents->count() > 0 || ($entity->expense->exists() && $entity->expense->invoice_documents))