From 3eedde2f4a5a4f5b331bceb8bf0b8f6d911c0f70 Mon Sep 17 00:00:00 2001 From: "luoJunYong.123" Date: Wed, 29 Dec 2021 11:13:48 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=B9=E9=87=8F=E5=88=A0=E9=99=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/achievement/list/index.vue | 3 +++ src/pages/assessment/list/index.vue | 5 +++++ src/pages/course/list/courseManagement/index.vue | 3 +++ src/pages/evaluation/list/index.vue | 3 +++ src/pages/information/contentManage/contentList.vue | 3 +++ src/pages/student/list/index.vue | 3 +++ src/pages/system/list/role.vue | 3 +++ 7 files changed, 23 insertions(+) diff --git a/src/pages/achievement/list/index.vue b/src/pages/achievement/list/index.vue index 82580d3..6934b73 100644 --- a/src/pages/achievement/list/index.vue +++ b/src/pages/achievement/list/index.vue @@ -290,6 +290,9 @@ export default { this.getData(); }).catch(res => { }); + if(this.multipleSelection.length === this.listData.length && this.pageNum>1) { + this.handleCurrentChange(this.pageNum - 1) + } }).catch(() => { }); } else { diff --git a/src/pages/assessment/list/index.vue b/src/pages/assessment/list/index.vue index eea10df..65d17ba 100644 --- a/src/pages/assessment/list/index.vue +++ b/src/pages/assessment/list/index.vue @@ -392,6 +392,7 @@ export default { this.$confirm("确定要删除吗?", "提示", { type: "warning" }).then(() => { + this.$post(this.api.deleteAssessment, ids).then(res => { this.multipleSelection = []; this.$refs.table.clearSelection(); @@ -400,6 +401,10 @@ export default { this.getData(); }).catch(res => { }); + if(this.multipleSelection.length === this.listData.length && this.pageNum>1) { + console.log(this.pageNum - 1) + this.handleCurrentChange(this.pageNum - 1) + } }).catch(() => { }); } else { diff --git a/src/pages/course/list/courseManagement/index.vue b/src/pages/course/list/courseManagement/index.vue index 65b854d..93b7157 100644 --- a/src/pages/course/list/courseManagement/index.vue +++ b/src/pages/course/list/courseManagement/index.vue @@ -184,6 +184,9 @@ export default { this.initData(); }).catch(res => { }); + if(this.multipleSelection.length === this.courseData.length && this.current>1) { + this.handleCurrentChange(this.current - 1) + } }).catch(() => { }); } else { diff --git a/src/pages/evaluation/list/index.vue b/src/pages/evaluation/list/index.vue index 425636b..200c38c 100644 --- a/src/pages/evaluation/list/index.vue +++ b/src/pages/evaluation/list/index.vue @@ -429,6 +429,9 @@ export default { }).catch(err => { console.log(err); }); + if(this.multipleSelection.length === this.listData.length && this.page>1) { + this.handleCurrentChange(this.page - 1) + } }).catch(() => { }); } else { diff --git a/src/pages/information/contentManage/contentList.vue b/src/pages/information/contentManage/contentList.vue index bfd0abb..be3f220 100644 --- a/src/pages/information/contentManage/contentList.vue +++ b/src/pages/information/contentManage/contentList.vue @@ -154,6 +154,9 @@ export default { this.getData(); }).catch(res => { }); + if(this.multipleSelection.length === this.listData.length && this.pageNo>1) { + this.handleCurrentChange(this.pageNo - 1) + } }) .catch(() => { }); diff --git a/src/pages/student/list/index.vue b/src/pages/student/list/index.vue index 4ecccf1..2d4352c 100644 --- a/src/pages/student/list/index.vue +++ b/src/pages/student/list/index.vue @@ -659,6 +659,9 @@ export default { } }).catch(res => { }); + if(this.multipleSelection.length === this.listData.length && this.page>1) { + this.handleCurrentChange(this.page - 1) + } }).catch(() => { }); } else { diff --git a/src/pages/system/list/role.vue b/src/pages/system/list/role.vue index 68267a7..f3901a2 100644 --- a/src/pages/system/list/role.vue +++ b/src/pages/system/list/role.vue @@ -146,6 +146,9 @@ export default { util.successMsg("删除成功"); this.getData(); }).catch(res => {}); + if(this.multipleSelection.length === this.listData.length && this.page>1) { + this.handleCurrentChange(this.page - 1) + } }).catch(() => {}); } else { util.errorMsg("请先选择数据!");