- {{ item.className }} -
- -@@ -272,6 +272,7 @@ export default { query: { schoolName: "", loginName: "", + }, tableData: [], total: 0, diff --git a/src/views/examinationPaper/index.vue b/src/views/examinationPaper/index.vue index 4fda0a0..8202620 100644 --- a/src/views/examinationPaper/index.vue +++ b/src/views/examinationPaper/index.vue @@ -323,6 +323,7 @@ export default { }, // 查找答题卡类型 async _QueryTypeList() { + if (!this.query.classId) return; let fetchTypeNames = this.role == "ROLE_PERSONAL" ? this.$request.pPaperTagList @@ -375,6 +376,7 @@ export default { }, // 查找科目 async _QuerySubjectList() { + if (!this.query.classId) return; let fetchSubjectList = this.role == "ROLE_PERSONAL" ? this.$request.pSubjectList @@ -397,6 +399,7 @@ export default { } }, async _QueryData(type) { + if (!this.query.classId) return; this.loading = true; //获取答题卡列表 let query = {}; diff --git a/src/views/personal/ask/index.vue b/src/views/personal/ask/index.vue index 7473f13..4d41b66 100644 --- a/src/views/personal/ask/index.vue +++ b/src/views/personal/ask/index.vue @@ -538,6 +538,7 @@ export default { } }, async _QuerySubjectList() { + if (!this.query.classId) return; const { data, status, info } = await this.$request.pSubjectList({ classId: this.query.classId, }); @@ -560,6 +561,7 @@ export default { } }, async _QueryData() { + if (!this.query.classId) return; if (this.tabIndex == 1) { this.periodReportList(); } else if (this.tabIndex == 2) { diff --git a/src/views/personal/setUp/student.vue b/src/views/personal/setUp/student.vue index 6ccdc85..db53a92 100644 --- a/src/views/personal/setUp/student.vue +++ b/src/views/personal/setUp/student.vue @@ -287,7 +287,7 @@ export default { setClass(obj) { this.formClass.classId = obj.id; this.formClass.className = obj.className; - this.formClass.subjectNames = obj.subjectNames; + this.formClass.subjectNames = obj.subjectNames||[]; this.diaClass = true; }, addSubjectName() { diff --git a/src/views/personal/test/index.vue b/src/views/personal/test/index.vue index f0f2c3e..f6638fc 100644 --- a/src/views/personal/test/index.vue +++ b/src/views/personal/test/index.vue @@ -660,6 +660,7 @@ export default { } }, async _QuerySubjectList() { + if (!this.query.classId) return; const { data, status, info } = await this.$request.pSubjectList({ classId: this.query.classId, }); @@ -682,6 +683,7 @@ export default { } }, async _QueryData() { + if (!this.query.classId) return; this.tableData = []; if (this.tabIndex == 1) { this.examReportList(); diff --git a/src/views/standard/device/index.vue b/src/views/standard/device/index.vue index 1bbf281..a5438ff 100644 --- a/src/views/standard/device/index.vue +++ b/src/views/standard/device/index.vue @@ -252,11 +252,6 @@