Fix filters and other methods that used deprecated methods.

This commit is contained in:
James Cole
2016-05-20 08:09:53 +02:00
parent dda3082c7e
commit 70d936bb8f
10 changed files with 81 additions and 18 deletions

View File

@@ -172,7 +172,7 @@ class TransactionJournalSupport extends Model
if ($cache->has()) {
return $cache->get();
}
$transactions = $journal->transactions()->where('amount', '>', 0)->with('account')->get();
$transactions = $journal->transactions()->where('amount', '>', 0)->orderBy('transactions.account_id')->with('account')->get();
$list = new Collection;
/** @var Transaction $t */
foreach ($transactions as $t) {
@@ -316,7 +316,7 @@ class TransactionJournalSupport extends Model
if ($cache->has()) {
return $cache->get();
}
$transactions = $journal->transactions()->where('amount', '<', 0)->with('account')->get();
$transactions = $journal->transactions()->where('amount', '<', 0)->orderBy('transactions.account_id')->with('account')->get();
$list = new Collection;
/** @var Transaction $t */
foreach ($transactions as $t) {