minor fixes
This commit is contained in:
parent
afe6262904
commit
bd24a10409
|
|
@ -390,7 +390,6 @@ class LoginController extends BaseController
|
|||
|
||||
|
||||
$truth = app()->make(TruthSource::class);
|
||||
|
||||
$truth->setCompanyUser($cu->first());
|
||||
$truth->setUser(auth()->user());
|
||||
$truth->setCompany(auth()->user()->account->default_company);
|
||||
|
|
|
|||
|
|
@ -84,6 +84,13 @@ class ApplyPaymentAmount extends AbstractService
|
|||
->deletePdf()
|
||||
->save();
|
||||
|
||||
$this->invoice
|
||||
->client
|
||||
->service()
|
||||
->updateBalance($payment->amount * -1)
|
||||
->updatePaidToDate($payment->amount)
|
||||
->save();
|
||||
|
||||
if ($this->invoice->client->getSetting('client_manual_payment_notification'))
|
||||
$payment->service()->sendEmail();
|
||||
|
||||
|
|
@ -92,13 +99,6 @@ class ApplyPaymentAmount extends AbstractService
|
|||
$payment->ledger()
|
||||
->updatePaymentBalance($payment->amount * -1);
|
||||
|
||||
$this->invoice
|
||||
->client
|
||||
->service()
|
||||
->updateBalance($payment->amount * -1)
|
||||
->updatePaidToDate($payment->amount)
|
||||
->save();
|
||||
|
||||
$this->invoice->service()->workFlow()->save();
|
||||
|
||||
event('eloquent.created: App\Models\Payment', $payment);
|
||||
|
|
|
|||
Loading…
Reference in New Issue