| | |
| | | function getSpecifyDayDate (day) { |
| | | const timeCount = new Date().getTime() - day * 24 * 60 * 60 * 1000 |
| | | const date = new Date(timeCount) |
| | | return `${date.getFullYear()}-${date.getMonth() + 1}-${date.getDate()} 00:00:00` |
| | | var month = "" |
| | | if (date.getMonth()+1<10){ |
| | | month = "0"+(date.getMonth()+1) |
| | | }else { |
| | | month = date.getMonth() + 1 |
| | | } |
| | | return `${date.getFullYear()}-${month}-${date.getDate()} 00:00:00` |
| | | } |
| | | |
| | | /** |
| | |
| | | const date = new Date() |
| | | const year = date.getFullYear() |
| | | const month = date.getMonth() + 1 |
| | | const strDate = date.getDate() - 1 |
| | | const strDate = date.getDate() |
| | | return `${year}-${month}-${strDate} 23:59:59` |
| | | } |
| | | |