1;概览 默认时间
This commit is contained in:
parent
22276e2249
commit
1b8deaa3aa
|
@ -206,7 +206,7 @@ export default {
|
|||
// 是否显示弹出层
|
||||
open: false,
|
||||
open1: false,
|
||||
timeRange1: [new Date(new Date()-(24*60*60*1000)),new Date(new Date()-(24*60*60*1000))],
|
||||
timeRange1: undefined,
|
||||
queryParams1: {
|
||||
storeId: undefined,
|
||||
storeName: undefined,
|
||||
|
@ -241,12 +241,21 @@ export default {
|
|||
};
|
||||
},
|
||||
created() {
|
||||
this.timeRange1 = [this.formatDate(new Date(new Date()-(24*60*60*1000))),this.formatDate(new Date(new Date()-(24*60*60*1000)))]
|
||||
this.getList();
|
||||
},
|
||||
methods: {
|
||||
formatDate(date) {
|
||||
const year = date.getFullYear();
|
||||
const month = (date.getMonth() + 1).toString().padStart(2, '0');
|
||||
const day = date.getDate().toString().padStart(2, '0');
|
||||
return `${year}-${month}-${day}`;
|
||||
},
|
||||
/** 查询店铺单日历史信息列表 */
|
||||
getList() {
|
||||
this.loading = true;
|
||||
this.queryParams.expStartTime = this.timeRange1[0];
|
||||
this.queryParams.expEndTime = this.timeRange1[1];
|
||||
listInfo1(this.queryParams).then(response => {
|
||||
this.infoList = response.rows;
|
||||
this.total = response.total;
|
||||
|
@ -316,7 +325,7 @@ export default {
|
|||
},
|
||||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.timeRange1 = [new Date(new Date()-(24*60*60*1000)),new Date(new Date()-(24*60*60*1000))];
|
||||
this.timeRange1 = [this.formatDate(new Date(new Date()-(24*60*60*1000))),this.formatDate(new Date(new Date()-(24*60*60*1000)))];
|
||||
this.queryParams.account=undefined;
|
||||
this.resetForm("queryForm");
|
||||
this.handleQuery();
|
||||
|
|
Loading…
Reference in New Issue