mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-11-18 15:39:50 +00:00
Add imports for facades
This commit is contained in:
@@ -32,6 +32,7 @@ use FireflyIII\Models\Transaction;
|
||||
use FireflyIII\Models\TransactionJournal;
|
||||
use FireflyIII\Repositories\Account\AccountRepositoryInterface;
|
||||
use FireflyIII\User;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
|
||||
/**
|
||||
* Class SetSourceToCashAccount
|
||||
@@ -108,7 +109,7 @@ class SetSourceToCashAccount implements ActionInterface
|
||||
event(new TriggeredAuditLog($this->action->rule, $object, 'set_source', null, $cashAccount->name));
|
||||
|
||||
// update destination transaction with new destination account:
|
||||
\DB::table('transactions')
|
||||
DB::table('transactions')
|
||||
->where('transaction_journal_id', '=', $object->id)
|
||||
->where('amount', '<', 0)
|
||||
->update(['account_id' => $cashAccount->id])
|
||||
|
||||
Reference in New Issue
Block a user