提交 cd1b6405 authored 作者: lihuihui's avatar lihuihui

修改时间

上级 56cc4d1d
...@@ -104,7 +104,7 @@ export default { ...@@ -104,7 +104,7 @@ export default {
getRecordsScore() { getRecordsScore() {
const param = { const param = {
sso_id: this.data.sso_id, sso_id: this.data.sso_id,
start_time: this.getNowTime(1), start_time: this.getNowTime(-7),
end_time: this.getNowTime() end_time: this.getNowTime()
} }
api api
...@@ -294,7 +294,7 @@ export default { ...@@ -294,7 +294,7 @@ export default {
}, },
getNowTime(n) { getNowTime(n) {
let dateTime = '' let dateTime = ''
const date = n > 1 ? new Date(n * 1000) : new Date() const date = n === -7 ? new Date(new Date() - 7 * 24 * 3600 * 1000) : new Date()
const yy = date.getFullYear() const yy = date.getFullYear()
const mm = date.getMonth() + (n === 1 ? 0 : 1) const mm = date.getMonth() + (n === 1 ? 0 : 1)
const dd = date.getDate() const dd = date.getDate()
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论