Authored by OF1706

search page empty

... ... @@ -43,7 +43,7 @@
</filter-item>
<filter-item>
<Button type="primary" @click="list">筛选</Button>
<Button type="primary" @click="filterSearch">筛选</Button>
<Button @click="clearFilters">清空条件</Button>
</filter-item>
</layout-filter>
... ... @@ -125,7 +125,7 @@
answerEndTime = fts.answerEndTime.model;
let page = this.pageData.current;
let pageSize = this.pageData.pageSize;
let size = this.pageData.size;
if (this.filters.productSKN.model) {
if (this.isNumber(this.filters.productSKN.model)) {
... ... @@ -135,7 +135,7 @@
}
}
params.pageSize = this.pageData.pageSize;
params.size = this.pageData.size;
params.page = this.pageData.current;
return Promise.resolve({
... ... @@ -153,7 +153,7 @@
answerStartTime,
answerEndTime,
page,
pageSize
size
});
},
list() {
... ... @@ -192,6 +192,10 @@
this.$Message.error(err);
});
},
filterSearch() {
this.pageData.current = 1;
this.list();
},
isNumber(numStr) {
const isNumber = /^[0-9]+$/;
... ...
... ... @@ -31,7 +31,7 @@
</Date-picker>
</filter-item>
<filter-item>
<Button type="primary" @click="list">筛选</Button>
<Button type="primary" @click="filterSearch">筛选</Button>
<Button @click="clearFilters">清空条件</Button>
</filter-item>
</layout-filter>
... ... @@ -93,7 +93,7 @@
endTime = fts.endTime.model;
let page = this.pageData.current;
let pageSize = this.pageData.pageSize;
let size = this.pageData.size;
if (this.filters.erpSkuId.model) {
if (this.isNumber(this.filters.erpSkuId.model)) {
... ... @@ -111,7 +111,7 @@
}
}
params.pageSize = this.pageData.pageSize;
params.size = this.pageData.size;
params.page = this.pageData.current;
return Promise.resolve({
... ... @@ -124,7 +124,7 @@
beginTime,
endTime,
page,
pageSize
size
});
},
list() {
... ... @@ -161,6 +161,10 @@
this.$Message.error(err);
});
},
filterSearch() {
this.pageData.current = 1;
this.list();
},
isNumber(numStr) {
const isNumber = /^[0-9]+$/;
... ...