Add locale to variables.

This commit is contained in:
James Cole 2020-07-27 20:06:18 +02:00
parent d49743031f
commit 1c07feb446
No known key found for this signature in database
GPG Key ID: B5669F9493CDE38D

View File

@ -136,7 +136,7 @@ class JavascriptController extends Controller
if(null !== $account) {
$currency = $repository->getAccountCurrency($account) ?? $currency;
}
$locale = app('steam')->getLocale();
$accounting = app('amount')->getJsConfig();
$accounting['frac_digits'] = $currency->decimal_places;
$pref = app('preferences')->get('language', config('firefly.default_language', 'en_US'));
@ -151,6 +151,7 @@ class JavascriptController extends Controller
'accountingLocaleInfo' => $accounting,
'language' => $lang,
'dateRangeTitle' => $dateRange['title'],
'locale' => $locale,
'dateRangeConfig' => $dateRange['configuration'],
'uid' => $uid,
];