mirror of
https://github.com/wger-project/flutter.git
synced 2026-02-18 00:17:48 +01:00
Correctly format the date according to the current locale
This commit is contained in:
@@ -87,7 +87,9 @@ class _MeasurementChartWidgetFlState extends State<MeasurementChartWidgetFl> {
|
||||
showTitles: true,
|
||||
getTitlesWidget: (value, meta) {
|
||||
final DateTime date = DateTime.fromMillisecondsSinceEpoch(value.toInt() * 1000 * 60);
|
||||
return Text(DateFormat.yMd().format(date));
|
||||
return Text(
|
||||
DateFormat.yMd(Localizations.localeOf(context).languageCode).format(date),
|
||||
);
|
||||
},
|
||||
interval: interval,
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user