mirror of
https://gitee.com/java110/WechatOwnerService.git
synced 2026-02-23 21:36:38 +08:00
优化代码
This commit is contained in:
parent
d77aa2c1f4
commit
3cb4592eb3
@ -70,7 +70,8 @@ export function getDate(strDate) {
|
||||
var a = st.split(" "); //这个根据你的字符串决定,如果中间为T则改T
|
||||
var b = a[0].split("-");
|
||||
var c = a[1].split(":");
|
||||
var date = new Date(b[0], b[1], b[2], c[0], c[1], c[2]);
|
||||
let month = parseInt(b[1])-1;
|
||||
var date = new Date(b[0], month, b[2], c[0], c[1], c[2]);
|
||||
return date;
|
||||
};
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user