Element时间转换时间戳

大得369 2022-06-23 15:44:37 阅读数:11

转换Element时间
 if(this.modalList.date != null){
var d = this.modalList.date[0];//开始时间
var e = this.modalList.date[1];//结束时间
this.modalList.sdate = new Date(d).getTime()/1000;
this.modalList.enddate = new Date(e).getTime()/1000;
}else{
this.modalList.sdate = "";
this.modalList.enddate = "";
}

版权声明:本文为[大得369]所创,转载请带上原文链接,感谢。 https://blog.csdn.net/qq_34631220/article/details/125418232