mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-26 13:36:15 +00:00
[chore] Move to native from default. [skip ci]
This commit is contained in:
@@ -61,7 +61,7 @@ class PiggyBankEventTransformer extends AbstractTransformer
|
||||
$this->piggyRepos->setUser($account->user);
|
||||
|
||||
// get associated currency or fall back to the default:
|
||||
$currency = $this->repository->getAccountCurrency($account) ?? app('amount')->getDefaultCurrencyByUserGroup($account->user->userGroup);
|
||||
$currency = $this->repository->getAccountCurrency($account) ?? app('amount')->getNativeCurrencyByUserGroup($account->user->userGroup);
|
||||
|
||||
// get associated journal and transaction, if any:
|
||||
$journalId = $event->transaction_journal_id;
|
||||
|
||||
@@ -106,7 +106,7 @@ class UserGroupTransformer extends AbstractTransformer
|
||||
*/
|
||||
public function transform(UserGroup $userGroup): array
|
||||
{
|
||||
$currency = Amount::getDefaultCurrencyByUserGroup($userGroup);
|
||||
$currency = Amount::getNativeCurrencyByUserGroup($userGroup);
|
||||
|
||||
return [
|
||||
'id' => $userGroup->id,
|
||||
|
||||
@@ -137,7 +137,7 @@ class PiggyBankTransformer extends AbstractTransformer
|
||||
}
|
||||
|
||||
Log::debug(sprintf('Created new ExchangeRateConverter in %s', __METHOD__));
|
||||
$this->default = app('amount')->getDefaultCurrencyByUserGroup(auth()->user()->userGroup);
|
||||
$this->default = app('amount')->getNativeCurrencyByUserGroup(auth()->user()->userGroup);
|
||||
$this->converter = new ExchangeRateConverter();
|
||||
|
||||
return $objects;
|
||||
|
||||
Reference in New Issue
Block a user