Commit 0b45c468 authored by Facius's avatar Facius

fix: 学练记录页面时间段选择计算错误

parent 9887aaaf
{ // launch.json 配置了启动调试时相关设置,configurations下节点名称可为 app-plus/h5/mp-weixin/mp-baidu/mp-alipay/mp-qq/mp-toutiao/mp-360/
// launchtype项可配置值为local或remote, local代表前端连本地云函数,remote代表前端连云端云函数
"version": "0.0",
"configurations": [{
"type": "uniCloud",
"default": {
"launchtype": "local"
}
}
]
}
......@@ -380,14 +380,15 @@ export default {
this.queryExamRecord()
},
nearlySevenDays() {
return this.nearlyDays(5)
return this.nearlyDays(6)
},
nearlyThirtyDays() {
return this.nearlyDays(28)
return this.nearlyDays(29)
},
nearlyDays(day) {
var end = new Date().getTime()
var start = new Date().setDate(new Date().getDay() - day)
let date = new Date()
var end = date.getTime()
var start = date.setDate(date.getDate() - day)
var params = {
startDate: this.$u.timeFormat(start, 'yyyy-mm-dd'),
endDate: this.$u.timeFormat(end, 'yyyy-mm-dd'),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment