mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-11-07 10:28:22 +00:00
Add support for British English and allow the user to set a locale.
This commit is contained in:
@@ -111,6 +111,7 @@ class BillController extends Controller
|
||||
if ($cache->has()) {
|
||||
return response()->json($cache->get()); // @codeCoverageIgnore
|
||||
}
|
||||
$locale = app('steam')->getLocale();
|
||||
|
||||
/** @var GroupCollectorInterface $collector */
|
||||
$collector = app(GroupCollectorInterface::class);
|
||||
@@ -131,7 +132,7 @@ class BillController extends Controller
|
||||
];
|
||||
|
||||
foreach ($journals as $journal) {
|
||||
$date = $journal['date']->formatLocalized((string) trans('config.month_and_day'));
|
||||
$date = $journal['date']->formatLocalized((string) trans('config.month_and_day', [], $locale));
|
||||
$chartData[0]['entries'][$date] = $bill->amount_min; // minimum amount of bill
|
||||
$chartData[1]['entries'][$date] = $bill->amount_max; // maximum amount of bill
|
||||
|
||||
|
||||
Reference in New Issue
Block a user