diff --git a/app/Jobs/Quote/EmailQuote.php b/app/Jobs/Quote/EmailQuote.php index 58a1193e2ffd..407157a4ad40 100644 --- a/app/Jobs/Quote/EmailQuote.php +++ b/app/Jobs/Quote/EmailQuote.php @@ -60,7 +60,7 @@ class EmailQuote implements ShouldQueue return $this->logMailError(Mail::failures()); } - $this->quote_invitation->quote->markSent()->save(); + $this->quote_invitation->quote->service()->markSent()->save(); } diff --git a/app/Services/Quote/SendEmail.php b/app/Services/Quote/SendEmail.php index 744413136842..75203fb6bbef 100644 --- a/app/Services/Quote/SendEmail.php +++ b/app/Services/Quote/SendEmail.php @@ -39,7 +39,7 @@ class SendEmail * @param string $this->reminder_template The template name ie reminder1 * @return array */ - public function run(): array + public function run() { if (!$this->reminder_template) { $this->reminder_template = $this->quote->calculateTemplate(); @@ -52,5 +52,7 @@ class SendEmail EmailQuote::dispatchNow($email_builder, $invitation); } }); + + $this->quote->service()->markSent(); } } diff --git a/app/Transformers/InvoiceHistoryTransformer.php b/app/Transformers/InvoiceHistoryTransformer.php index d9f2fa019804..44d2d3574d91 100644 --- a/app/Transformers/InvoiceHistoryTransformer.php +++ b/app/Transformers/InvoiceHistoryTransformer.php @@ -35,6 +35,7 @@ class InvoiceHistoryTransformer extends EntityTransformer 'activity_id' => $this->encodePrimaryKey($backup->activity_id), 'json_backup' => (string) $backup->json_backup ?: '', 'html_backup' => (string) $backup->html_backup ?: '', + 'amount' => (float) $backup->amount, 'created_at' => (int)$backup->created_at, 'updated_at' => (int)$backup->updated_at, ];