Fix account thing overview.

This commit is contained in:
James Cole
2025-08-09 20:10:40 +02:00
parent be8ca5db50
commit 4196ce31f0
3 changed files with 6 additions and 7 deletions

View File

@@ -566,7 +566,7 @@ class AccountRepository implements AccountRepositoryInterface, UserGroupInterfac
'transaction_types.type',
'transaction_journals.transaction_currency_id',
'transactions.amount',
'transactions.native_amount',
'transactions.native_amount as pc_amount',
'transactions.foreign_amount',
])
->toArray()

View File

@@ -98,10 +98,10 @@ trait PeriodOverview
/** @var array $dates */
$dates = Navigation::blockPeriods($start, $end, $range);
$entries = [];
$spent = [];
$earned = [];
$transferredAway = [];
$transferredIn = [];
// $spent = [];
// $earned = [];
// $transferredAway = [];
// $transferredIn = [];
// run a custom query because doing this with the collector is MEGA slow.
$transactions = $this->accountRepository->periodCollection($account, $start, $end);
@@ -180,8 +180,8 @@ trait PeriodOverview
continue;
}
$filtered[] = $item;
}
$filtered[] = $item;
}
return [$filtered, $result];

View File

@@ -12,7 +12,6 @@
<td style="text-align: right;">{{ period.total_transactions }}</td>
</tr>
{% endif %}
{% for entry in period.spent %}
{% if entry.amount != 0 %}
<tr>