TF-802 Show message when enable/disable vacation responder
This commit is contained in:
@@ -18,7 +18,7 @@ extension PresentationEmailExtension on PresentationEmail {
|
||||
String getReceivedAt(String newLocale, {String? pattern}) {
|
||||
final emailTime = receivedAt;
|
||||
if (emailTime != null) {
|
||||
return emailTime.formatDate(
|
||||
return emailTime.formatDateToLocal(
|
||||
pattern: pattern ?? emailTime.value.toLocal().toPattern(),
|
||||
locale: newLocale);
|
||||
}
|
||||
|
||||
@@ -3,11 +3,19 @@ import 'package:jmap_dart_client/jmap/core/utc_date.dart';
|
||||
|
||||
extension UTCDateExtension on UTCDate? {
|
||||
|
||||
String formatDate({String pattern = 'yMMMd', String locale = 'en_US'}) {
|
||||
String formatDateToLocal({String pattern = 'yMMMd', String locale = 'en_US'}) {
|
||||
if (this != null) {
|
||||
return DateFormat(pattern, locale).format(this!.value.toLocal());
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
|
||||
String formatDate({String pattern = 'yMMMd', String locale = 'en_US'}) {
|
||||
if (this != null) {
|
||||
return DateFormat(pattern, locale).format(this!.value);
|
||||
} else {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user