日期格化式函数 zhang小生 2020-01-03 129 阅读1分钟 getTime(date) { let year = date.getFullYear(); let month =('00' +( date.getMonth() + 1)).slice(-2); let day = ('00' +date.getDate()).slice(-2) return year + "-" + month + "-" + day; },