Deleting company fixed transaction object issue..
This commit is contained in:
parent
20508319be
commit
c68d8b2615
@ -33,6 +33,10 @@ class Transaction extends Observer
|
||||
{
|
||||
$invoice = $transaction->invoice;
|
||||
|
||||
if (empty($invoice)) {
|
||||
return;
|
||||
}
|
||||
|
||||
$invoice->transactions_count = $invoice->transactions->count();
|
||||
event(new TransactionsCounted($invoice));
|
||||
|
||||
@ -49,6 +53,10 @@ class Transaction extends Observer
|
||||
{
|
||||
$bill = $transaction->bill;
|
||||
|
||||
if (empty($bill)) {
|
||||
return;
|
||||
}
|
||||
|
||||
$bill->transactions_count = $bill->transactions->count();
|
||||
event(new TransactionsCounted($bill));
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user