timestampToZh_yyyy_MM_dd_HH_mm function

String timestampToZh_yyyy_MM_dd_HH_mm(
  1. int timestamp, {
  2. bool isUtc = false,
})

时间戳转yyyy年MM月dd日 HH时mm分

Implementation

// ignore: non_constant_identifier_names
String timestampToZh_yyyy_MM_dd_HH_mm(int timestamp, {bool isUtc = false}) {
  DateTime dateTime = timestampToDateTime(timestamp, isUtc: isUtc);
  return '${dateTime.year}年${twoDigits(dateTime.month)}月${twoDigits(dateTime.day)}日 ${twoDigits(dateTime.hour)}时${twoDigits(dateTime.minute)}分';
}