Commit bfb748bf490e13399f308d54addf33fe6c1b0046
1 parent
79e3161b
fix:修复列表过滤异常
Showing
1 changed file
with
8 additions
and
5 deletions
src/views/basic/askTestQuestion/index.vue
| ... | ... | @@ -30,7 +30,7 @@ |
| 30 | 30 | <el-date-picker value-format="yyyy-MM-dd" class="filter-datePicker" v-model="query.dateRange" |
| 31 | 31 | type="daterange" range-separator="-"> |
| 32 | 32 | </el-date-picker> |
| 33 | - <el-button type="primary" @click="_serach"> | |
| 33 | + <el-button type="primary" @click="_filter"> | |
| 34 | 34 | 筛选 |
| 35 | 35 | </el-button> |
| 36 | 36 | <el-radio-group v-model="query.dateStatus" class="default-date-radio-group"> |
| ... | ... | @@ -390,6 +390,10 @@ export default { |
| 390 | 390 | await this._loadQueryDatas(); |
| 391 | 391 | }, |
| 392 | 392 | methods: { |
| 393 | + async _filter() { | |
| 394 | + this.listPage.page = 1; | |
| 395 | + await this._serach(); | |
| 396 | + }, | |
| 393 | 397 | async downExcel() { |
| 394 | 398 | let url; |
| 395 | 399 | let that = this; |
| ... | ... | @@ -571,6 +575,7 @@ export default { |
| 571 | 575 | ? this.$request.pPaperList |
| 572 | 576 | : this.$request.fetchPaperList; |
| 573 | 577 | |
| 578 | + | |
| 574 | 579 | var queryParams = { |
| 575 | 580 | classId: "", |
| 576 | 581 | subjectName: "", |
| ... | ... | @@ -580,8 +585,7 @@ export default { |
| 580 | 585 | end: null, |
| 581 | 586 | type: this.dataType, //试卷类型 |
| 582 | 587 | share: this.tabType, //分享类型 |
| 583 | - }; | |
| 584 | - this.listPage.page = 1; | |
| 588 | + }; | |
| 585 | 589 | queryParams.classId = this.query.class; |
| 586 | 590 | queryParams.subjectName = this.query.subject; |
| 587 | 591 | queryParams.tagId = this.query.tagId; |
| ... | ... | @@ -605,8 +609,7 @@ export default { |
| 605 | 609 | this.queryLoading = false; |
| 606 | 610 | this.createdCount = data?.myCount || 0; |
| 607 | 611 | this.sharedCount = data?.gradeCount || 0; |
| 608 | - this.listPage.total = data.total; | |
| 609 | - console.log('page', this.listPage) | |
| 612 | + this.listPage.total = data.total; | |
| 610 | 613 | if (this.tabType == "0") { |
| 611 | 614 | this.defaultList = []; |
| 612 | 615 | if (data?.list) this.defaultList = [...data?.list]; | ... | ... |