mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-09-19 02:45:58 +00:00
This commit is contained in:
@@ -74,7 +74,16 @@ class General extends AbstractExtension
|
|||||||
|
|
||||||
$strings = [];
|
$strings = [];
|
||||||
foreach ($info as $currencyId => $balance) {
|
foreach ($info as $currencyId => $balance) {
|
||||||
$strings[] = app('amount')->formatByCurrencyId($currencyId, $balance, false);
|
if(0 === $currencyId) {
|
||||||
|
// not good code but OK
|
||||||
|
/** @var AccountRepositoryInterface $accountRepos */
|
||||||
|
$accountRepos = app(AccountRepositoryInterface::class);
|
||||||
|
$currency = $accountRepos->getAccountCurrency($account) ?? app('amount')->getDefaultCurrency();
|
||||||
|
$strings[] = app('amount')->formatAnything($currency, $balance, false);
|
||||||
|
}
|
||||||
|
if(0 !== $currencyId) {
|
||||||
|
$strings[] = app('amount')->formatByCurrencyId($currencyId, $balance, false);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return implode(', ', $strings);
|
return implode(', ', $strings);
|
||||||
|
Reference in New Issue
Block a user