Fix getFormattedDate()

This commit is contained in:
Yang Luo 2023-05-23 15:09:53 +08:00
parent 9c4f0f042e
commit 2389d47c34

View File

@ -24,6 +24,7 @@ import {authConfig} from "./auth/Auth";
import {Helmet} from "react-helmet";
import * as Conf from "./Conf";
import * as phoneNumber from "libphonenumber-js";
import moment from "moment";
const {Option} = Select;
@ -592,9 +593,8 @@ export function getFormattedDate(date) {
return null;
}
date = date.replace("T", " ");
date = date.replace("+08:00", " ");
return date;
const m = moment(date).local();
return m.format("YYYY-MM-DD HH:mm:ss");
}
export function getFormattedDateShort(date) {