Fixes for mollie payment driver

This commit is contained in:
David Bomba 2022-01-06 21:06:46 +11:00
parent f5f2395d7e
commit 89ce2b443e
2 changed files with 3 additions and 2 deletions

View File

@ -256,13 +256,13 @@ class BaseDriver extends AbstractPaymentDriver
$this->payment_hash->payment_id = $payment->id; $this->payment_hash->payment_id = $payment->id;
$this->payment_hash->save(); $this->payment_hash->save();
$this->attachInvoices($payment, $this->payment_hash);
if($this->payment_hash->credits_total() > 0) if($this->payment_hash->credits_total() > 0)
$payment = $payment->service()->applyCredits($this->payment_hash)->save(); $payment = $payment->service()->applyCredits($this->payment_hash)->save();
$payment->service()->updateInvoicePayment($this->payment_hash); $payment->service()->updateInvoicePayment($this->payment_hash);
$this->attachInvoices($payment, $this->payment_hash);
event('eloquent.created: App\Models\Payment', $payment); event('eloquent.created: App\Models\Payment', $payment);
if ($this->client->getSetting('client_online_payment_notification') && in_array($status, [Payment::STATUS_COMPLETED, Payment::STATUS_PENDING])) if ($this->client->getSetting('client_online_payment_notification') && in_array($status, [Payment::STATUS_COMPLETED, Payment::STATUS_PENDING]))

View File

@ -49,6 +49,7 @@ class TriggeredActions extends AbstractService
} }
if ($this->request->has('send_email') && $this->request->input('send_email') == 'true') { if ($this->request->has('send_email') && $this->request->input('send_email') == 'true') {
$this->invoice->service()->touchPdf()->save();
$this->sendEmail(); $this->sendEmail();
} }