// 获取上一周的开始结束时间,周日到周六
function getLastWeekDays(){
let date = []
let start = moment().week(moment().week() - 1).startOf('week').format('YYYY-MM-DD')
let end = moment().week(moment().week() - 1).endOf('week').format('YYYY-MM-DD')
date.push(start)
date.push(end)
return date
}
网友评论