1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-12 14:12:44 +01:00

Template action fixes

This commit is contained in:
David Bomba 2023-10-08 16:06:37 +11:00
parent c6d6150a32
commit 59a2163a33

View File

@ -470,6 +470,7 @@ class TemplateService
'refunded' => Number::formatMoney($credit->pivot->refunded, $payment->client),
'net' => Number::formatMoney($credit->pivot->amount - $credit->pivot->refunded, $payment->client),
'is_credit' => true,
'date' => $this->translateDate($credit->date, $payment->client->date_format(), $payment->client->locale()),
'created_at' => $this->translateDate($credit->pivot->created_at, $payment->client->date_format(), $payment->client->locale()),
'updated_at' => $this->translateDate($credit->pivot->updated_at, $payment->client->date_format(), $payment->client->locale()),
'timestamp' => $credit->pivot->created_at->timestamp,
@ -486,6 +487,7 @@ class TemplateService
'refunded' => Number::formatMoney($invoice->pivot->refunded, $payment->client),
'net' => Number::formatMoney($invoice->pivot->amount - $invoice->pivot->refunded, $payment->client),
'is_credit' => false,
'date' => $this->translateDate($invoice->date, $payment->client->date_format(), $payment->client->locale()),
'created_at' => $this->translateDate($invoice->pivot->created_at, $payment->client->date_format(), $payment->client->locale()),
'updated_at' => $this->translateDate($invoice->pivot->updated_at, $payment->client->date_format(), $payment->client->locale()),
'timestamp' => $invoice->pivot->created_at->timestamp,