mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Fix #2783
This commit is contained in:
@@ -174,9 +174,9 @@ class ReportController extends Controller
|
|||||||
$data[$currencyId] = $data[$currencyId] ?? [
|
$data[$currencyId] = $data[$currencyId] ?? [
|
||||||
'currency_id' => $currencyId,
|
'currency_id' => $currencyId,
|
||||||
'currency_symbol' => $journal['currency_symbol'],
|
'currency_symbol' => $journal['currency_symbol'],
|
||||||
'currency_code' => $journal['currency_symbol'],
|
'currency_code' => $journal['currency_code'],
|
||||||
'currency_name' => $journal['currency_name'],
|
'currency_name' => $journal['currency_name'],
|
||||||
'currency_decimal_places' => $journal['currency_decimal_places'],
|
'currency_decimal_places' => (int)$journal['currency_decimal_places'],
|
||||||
];
|
];
|
||||||
$data[$currencyId][$period] = $data[$currencyId][$period] ?? [
|
$data[$currencyId][$period] = $data[$currencyId][$period] ?? [
|
||||||
'period' => $period,
|
'period' => $period,
|
||||||
@@ -218,7 +218,6 @@ class ReportController extends Controller
|
|||||||
// loop all possible periods between $start and $end
|
// loop all possible periods between $start and $end
|
||||||
$currentStart = clone $start;
|
$currentStart = clone $start;
|
||||||
while ($currentStart <= $end) {
|
while ($currentStart <= $end) {
|
||||||
$currentEnd = app('navigation')->endOfPeriod($currentStart, $preferredRange);
|
|
||||||
$key = $currentStart->format($format);
|
$key = $currentStart->format($format);
|
||||||
$title = $currentStart->formatLocalized($titleFormat);
|
$title = $currentStart->formatLocalized($titleFormat);
|
||||||
$income['entries'][$title] = round($currency[$key]['earned'] ?? '0', $currency['currency_decimal_places']);
|
$income['entries'][$title] = round($currency[$key]['earned'] ?? '0', $currency['currency_decimal_places']);
|
||||||
|
|||||||
Reference in New Issue
Block a user