From 0694358cf3b9199df4b9db187be1cd16687a343b Mon Sep 17 00:00:00 2001 From: yujialong <479214531@qq.com> Date: Thu, 20 May 2021 17:55:01 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E5=96=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/testPaperDetail/index.vue | 6 +- src/libs/util.js | 6 +- src/pages/achievement/list/examResults.vue | 8 +- .../achievement/list/practiceResults.vue | 24 +++-- src/pages/achievement/list/wrongBook.vue | 22 +++- src/pages/assessment/list/index.vue | 31 ++++-- src/pages/assessment/list/studentTree.vue | 20 ++-- src/pages/assessment/monitor/index.vue | 14 ++- src/pages/assessment/review/index.vue | 18 ++-- src/pages/assessment/scoreQuery/index.vue | 14 +-- src/pages/index/list/index.vue | 27 ++--- src/pages/practice/list/index.vue | 28 +++-- src/pages/practice/list/studentTree.vue | 22 ++-- src/pages/practice/result/index.vue | 6 +- src/pages/practice/review/index.vue | 12 ++- src/pages/practice/scoreQuery/index.vue | 27 ++--- src/pages/quesBank/list/globalQuesBank.vue | 42 ++++++-- src/pages/quesBank/list/myQuesBank.vue | 31 +++++- src/pages/quesBank/list/quesBankType.vue | 10 +- src/pages/quesBank/list/quesDialog.vue | 3 +- src/pages/student/list/student.vue | 29 +++-- src/pages/system/list/role.vue | 32 ++++-- src/pages/system/list/staff.vue | 71 ++++++------ src/pages/testPaper/add/index.vue | 65 ++++++----- src/pages/testPaper/list/allTestPaper.vue | 56 +++++++--- src/pages/testPaper/list/myTestPaper.vue | 101 ++++++++++++------ src/plugins/auth/index.js | 2 +- src/setting.js | 2 +- src/store/modules/testpaper.js | 4 +- 29 files changed, 483 insertions(+), 250 deletions(-) diff --git a/src/components/testPaperDetail/index.vue b/src/components/testPaperDetail/index.vue index 9fca11f..721d136 100644 --- a/src/components/testPaperDetail/index.vue +++ b/src/components/testPaperDetail/index.vue @@ -7,7 +7,7 @@
总分: - 100分 + {{score === undefined ? 100 : score}}分
考试时长: @@ -23,7 +23,7 @@
-
+
序号:{{index+1}}
@@ -101,7 +101,7 @@ export default { 'userId' ]), ...mapState('testpaper', [ - 'id','paperName','totalDuration' + 'id','paperName','totalDuration','score' ]) }, mounted() { diff --git a/src/libs/util.js b/src/libs/util.js index 8e0538e..ec9d3bf 100644 --- a/src/libs/util.js +++ b/src/libs/util.js @@ -106,15 +106,15 @@ const util = { }, // 成功提示 successMsg(message) { - Message.success({message,showClose: true,offset: (document.documentElement.clientHeight - 40) / 2,duration: 1500}) + Message.success({message,showClose: true,offset: (document.documentElement.clientHeight - 40) / 2,duration: 3000}) }, // 警告提示 warningMsg(message) { - Message.warning({message,showClose: true,offset: (document.documentElement.clientHeight - 40) / 2,duration: 1500}) + Message.warning({message,showClose: true,offset: (document.documentElement.clientHeight - 40) / 2,duration: 3000}) }, // 错误提示 errorMsg(message) { - Message.error({message,showClose: true,offset: (document.documentElement.clientHeight - 40) / 2,duration: 1500}) + Message.error({message,showClose: true,offset: (document.documentElement.clientHeight - 40) / 2,duration: 3000}) }, // 给超过给定长度的字符串加省略号 ellipsisStr(str) { diff --git a/src/pages/achievement/list/examResults.vue b/src/pages/achievement/list/examResults.vue index d9488e1..9f4c6bd 100644 --- a/src/pages/achievement/list/examResults.vue +++ b/src/pages/achievement/list/examResults.vue @@ -10,7 +10,7 @@
  • - +
  • @@ -89,7 +89,7 @@ export default { keyword: function(val) { clearTimeout(this.searchTimer) this.searchTimer = setTimeout(() => { - this.getData() + this.initData() },500) } }, @@ -112,6 +112,10 @@ export default { }) .catch(err => {}) }, + initData(){ + this.page = 1 + this.getData() + }, getClass() { this.$post(this.api.getMyClass,{ userId: this.userId diff --git a/src/pages/achievement/list/practiceResults.vue b/src/pages/achievement/list/practiceResults.vue index 53dcdf9..6f44508 100644 --- a/src/pages/achievement/list/practiceResults.vue +++ b/src/pages/achievement/list/practiceResults.vue @@ -10,7 +10,7 @@
  • - +
  • @@ -58,11 +58,11 @@
    -
    + @@ -122,6 +122,7 @@ export default { pageAch: 1, pageSizeAch: 10, totalAch: 0, + curUserId: '' }; }, computed: { @@ -136,13 +137,13 @@ export default { keyword: function(val) { clearTimeout(this.searchTimer) this.searchTimer = setTimeout(() => { - this.getData() + this.initData() },500) }, keywordAch: function(val) { clearTimeout(this.searchTimer) this.searchTimer = setTimeout(() => { - this.getData() + this.initAchData() },500) } }, @@ -157,6 +158,10 @@ export default { this.total = res.data.list.totalCount }).catch(err => {}) }, + initData(){ + this.page = 1 + this.getData() + }, getClass() { this.$post(`${this.api.getMineClass}?userId=${this.userId}`) .then(res => { @@ -179,16 +184,21 @@ export default { this.getData() }, showDetail(row){ + this.curUserId = row.userId this.getDetail(row) this.detailVisible = true }, getDetail(row){ - this.$post(`${this.api.AchievementDetail}?userId=${row.userId}&practiseId=${this.practiseId}&pageNum=${this.page}&pageSize=${this.pageSize}`) + this.$post(`${this.api.AchievementDetail}?userId=${this.curUserId}&practiseId=${this.practiseId}&pageNum=${this.pageAch}&pageSize=${this.pageSizeAch}`) .then(res => { this.achiList = res.data.list.list this.totalAch = res.data.list.totalCount }).catch(err => {}) }, + initAchData(){ + this.pageAch = 1 + this.getDetail() + }, handleSelectionChange(val) { this.multipleSelection = val }, diff --git a/src/pages/achievement/list/wrongBook.vue b/src/pages/achievement/list/wrongBook.vue index 181ee3a..d75224e 100644 --- a/src/pages/achievement/list/wrongBook.vue +++ b/src/pages/achievement/list/wrongBook.vue @@ -10,13 +10,13 @@
  • - +
  • - +
  • @@ -40,7 +40,11 @@
    - + + + - +
    @@ -155,7 +155,7 @@ export default { keyword: function(val) { clearTimeout(this.searchTimer) this.searchTimer = setTimeout(() => { - this.getData() + this.initData() },500) } }, @@ -164,8 +164,7 @@ export default { 'setReviewInfo' ]), getData() { - this.$post(`${this.api.reviewList}?pageNum=${this.page}&pageSize=${10000}&userId=${this.userId}&assessmentId=${this.id}&keyword=${this.keyword}&state=${this.state}`) - .then(res => { + this.$post(`${this.api.reviewList}?pageNum=${this.page}&pageSize=${10000}&userId=${this.userId}&assessmentId=${this.id}&keyword=${this.keyword}&state=${this.state}`).then(res => { let list = res.data.list.list let result = [] list.map(n => { @@ -176,8 +175,11 @@ export default { this.listDataAll = result this.total = result.length this.handlePage() - }) - .catch(err => {}) + }).catch(err => {}) + }, + initData(){ + this.page = 1 + this.getData() }, handlePage(){ let list = this.listDataAll diff --git a/src/pages/assessment/scoreQuery/index.vue b/src/pages/assessment/scoreQuery/index.vue index 2edd281..4ee8067 100644 --- a/src/pages/assessment/scoreQuery/index.vue +++ b/src/pages/assessment/scoreQuery/index.vue @@ -10,13 +10,13 @@
    • - +
    • - +
    • @@ -106,7 +106,7 @@ export default { keyword: function(val) { clearTimeout(this.searchTimer) this.searchTimer = setTimeout(() => { - this.getData() + this.initData() },500) } }, @@ -129,6 +129,10 @@ export default { }) .catch(err => {}) }, + initData(){ + this.page = 1 + this.getData() + }, getClass() { let classId = this.classIdAss.split(',') let className = this.classNameAss.split(',') @@ -196,7 +200,5 @@ export default { \ No newline at end of file diff --git a/src/pages/index/list/index.vue b/src/pages/index/list/index.vue index 39834d6..dd66d9e 100644 --- a/src/pages/index/list/index.vue +++ b/src/pages/index/list/index.vue @@ -6,16 +6,15 @@ 我的考试计划
    +
    +
      +
    • + + +
    • +
    +