From 03bce0467bc146f478c8d5955c3e751e4dcfdb10 Mon Sep 17 00:00:00 2001 From: 梁保满 Date: Thu, 23 Feb 2023 15:52:19 +0800 Subject: [PATCH] 个人版调整 --- src/api/apis/apis.js | 342 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++------ src/api/urls/apis.js | 97 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++- src/router/index.js | 51 ++++++++++++++++++++++++--------------------------- src/views/index/mainIndex.vue | 8 +------- src/views/layout/header/header.vue | 8 +------- src/views/personal/ask/analysis.vue | 8 ++++---- src/views/personal/ask/index.vue | 12 ++++++------ src/views/personal/dataSync/index.vue | 4 ++-- src/views/personal/examinationPaper/add.vue | 16 ++++++++-------- src/views/personal/examinationPaper/detail.vue | 190 ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- src/views/personal/examinationPaper/edit.vue | 12 ++++++------ src/views/personal/examinationPaper/index.vue | 10 +++++----- src/views/personal/examinationPaper/recycle.vue | 12 ++++++------ src/views/personal/portrait/detail.vue | 2 +- src/views/personal/portrait/index.vue | 4 ++-- src/views/personal/setUp/student.vue | 2 +- src/views/personal/test/analysis.vue | 12 ++++++------ src/views/personal/test/index.vue | 12 ++++++------ src/views/standard/analysis/index.vue | 4 +--- src/views/standard/ask/index.vue | 4 +--- src/views/standard/device/index.vue | 8 +------- src/views/standard/examinationPaper/add.vue | 2 +- src/views/standard/setUp/account.vue | 8 +------- src/views/standard/setUp/student.vue | 8 +------- src/views/standard/test/index.vue | 4 +--- 25 files changed, 518 insertions(+), 322 deletions(-) delete mode 100644 src/views/personal/examinationPaper/detail.vue diff --git a/src/api/apis/apis.js b/src/api/apis/apis.js index 687ec23..b1023c8 100644 --- a/src/api/apis/apis.js +++ b/src/api/apis/apis.js @@ -42,8 +42,10 @@ export default { data, }); }, - //班主任-查询管理的班级 - cTClassList(data) { + + + //班主任-查询管理的班级 + cTClassList(data) { return service({ url: setUpUrls.cTClassList, method: "POST", @@ -110,8 +112,8 @@ export default { }); }, - //任课老师-查询管理的班级 - tClassList(data) { + //任课老师-查询管理的班级 + tClassList(data) { return service({ url: setUpUrls.tClassList, method: "POST", @@ -277,8 +279,8 @@ export default { url: setUpUrls.exportData, method: "POST", responseType: 'arraybuffer', - headers:{ - 'Content-Type':'application/octet-stream' + headers: { + 'Content-Type': 'application/octet-stream' } }); }, @@ -790,4 +792,332 @@ export default { method: "POST", }); }, + + /** 个人版 */ + // 修改个人信息 + modifyInfo(data) { + return service({ + url: setUpUrls.modifyInfo, + method: "POST", + data + }); + }, + // 查询班级列表 + pClassList(data) { + return service({ + url: setUpUrls.pClassList, + method: "POST", + data + }); + }, + // 查询科目列表 + pSubjectList(data) { + return service({ + url: setUpUrls.pSubjectList, + method: "POST", + data + }); + }, + // 查询学生列表 + pStudentList(data) { + return service({ + url: setUpUrls.pStudentList, + method: "POST", + data + }); + }, + // 新增或修改班级 + pSaveClass(data) { + return service({ + url: setUpUrls.pSaveClass, + method: "POST", + data + }); + }, + // 增加学生 + pAddStudent(data) { + return service({ + url: setUpUrls.pAddStudent, + method: "POST", + data + }); + }, + // 删除学生 + pDelStudent(data) { + return service({ + url: setUpUrls.pDelStudent, + method: "POST", + data + }); + }, + // 查询答题卡类型列表 + pPaperTagList(data) { + return service({ + url: setUpUrls.pPaperTagList, + method: "POST", + data + }); + }, + // 查询答题卡列表 + pPaperList(data) { + return service({ + url: setUpUrls.pPaperList, + method: "POST", + data + }); + }, + // 查询答题卡详情 + pPaperDetail(data) { + return service({ + url: setUpUrls.pPaperDetail, + method: "POST", + data + }); + }, + // 增加答题卡 + pAddPaper(data) { + return service({ + url: setUpUrls.pAddPaper, + method: "POST", + data + }); + }, + // 修改答题卡 + pModifyPaper(data) { + return service({ + url: setUpUrls.pModifyPaper, + method: "POST", + data + }); + }, + // 删除答题卡 + pDelPaper(data) { + return service({ + url: setUpUrls.pDelPaper, + method: "POST", + data + }); + }, + // 增加答题卡类型 + pAddPaperType(data) { + return service({ + url: setUpUrls.pAddPaperType, + method: "POST", + data + }); + }, + // 修改答题卡类型 + pModifyPaperType(data) { + return service({ + url: setUpUrls.pModifyPaperType, + method: "POST", + data + }); + }, + // 删除答题卡类型 + pDelPaperType(data) { + return service({ + url: setUpUrls.pDelPaperType, + method: "POST", + data + }); + }, + // 分页查询课时报表列表 + pPersonal(data) { + return service({ + url: setUpUrls.pPersonal, + method: "POST", + data + }); + }, + // 查询阶段问答报表 + pPhaseAnswerReport(data) { + return service({ + url: setUpUrls.pPhaseAnswerReport, + method: "POST", + data + }); + }, + // 查询阶段互动报表 + pPhaseInteractiveReport(data) { + return service({ + url: setUpUrls.pPhaseInteractiveReport, + method: "POST", + data + }); + }, + // 查询课时题目列表 + pPeriodQuestionList(data) { + return service({ + url: setUpUrls.pPeriodQuestionList, + method: "POST", + data + }); + }, + // 设置课时报表答案 + pSetPeriodAnswer(data) { + return service({ + url: setUpUrls.pSetPeriodAnswer, + method: "POST", + data + }); + }, + // 查询课时报表详情 + pPeriodDetail(data) { + return service({ + url: setUpUrls.pPeriodDetail, + method: "POST", + data + }); + }, + // 分页查询课时题目统计列表 + pPeriodQuestionReport(data) { + return service({ + url: setUpUrls.pPeriodQuestionReport, + method: "POST", + data + }); + }, + // 查询课时学生答题明细 + pPeriodStudentReport(data) { + return service({ + url: setUpUrls.pPeriodStudentReport, + method: "POST", + data + }); + }, + // 导出阶段报表 + pExportPhaseReport(data) { + return service({ + url: setUpUrls.pExportPhaseReport, + method: "POST", + data, + responseType: 'arraybuffer', + }); + }, + // 分页查询即时测报表 + pExamReportList(data) { + return service({ + url: setUpUrls.pExamReportList, + method: "POST", + data + }); + }, + // 查询阶段测练报表 + pPhaseExamReport(data) { + return service({ + url: setUpUrls.pPhaseExamReport, + method: "POST", + data + }); + }, + // 查询即时测报表题目列表 + pExamQuestionList(data) { + return service({ + url: setUpUrls.pExamQuestionList, + method: "POST", + data + }); + }, + // 设置即时测报表答案 + pSetExamAnswer(data) { + return service({ + url: setUpUrls.pSetExamAnswer, + method: "POST", + data + }); + }, + // 查询即时测报表详情 + pExamDetail(data) { + return service({ + url: setUpUrls.pExamDetail, + method: "POST", + data + }); + }, + // 下载导入主观题分模板 + pSubjectiveScoreTemplate(data) { + return service({ + url: setUpUrls.pSubjectiveScoreTemplate, + method: "POST", + data, + responseType: 'arraybuffer', + }); + }, + // 导入主观题得分 + pImportSubjectiveScore(data) { + return service({ + url: setUpUrls.pImportSubjectiveScore, + method: "POST", + data + }); + }, + // 分页查询即时测题目统计 + pExamQuestionReport(data) { + return service({ + url: setUpUrls.pExamQuestionReport, + method: "POST", + data + }); + }, + // 查询即时测学生统计 + pExamStudentReport(data) { + return service({ + url: setUpUrls.pExamStudentReport, + method: "POST", + data + }); + }, + // 重新判分 + pReScore(data) { + return service({ + url: setUpUrls.pReScore, + method: "POST", + data + }); + }, + // 导出单课时报表 + pExportPeriodReport(data) { + return service({ + url: setUpUrls.pExportPeriodReport, + method: "POST", + data, + responseType: 'arraybuffer', + }); + }, + // 导出阶段测练报表 + pExportPhaseExamReport(data) { + return service({ + url: setUpUrls.pExportPhaseExamReport, + method: "POST", + data, + responseType: 'arraybuffer', + }); + }, + // 导出单卷测练报表 + pExportExamReport(data) { + return service({ + url: setUpUrls.pExportExamReport, + method: "POST", + data, + responseType: 'arraybuffer', + }); + }, + // 数据导出 + pExportData(data) { + return service({ + url: setUpUrls.pExportData, + method: "POST", + data, + responseType: 'arraybuffer', + }); + }, + // 数据导入 + pImportData(data) { + return service({ + url: setUpUrls.pImportData, + method: "POST", + data + }); + }, }; diff --git a/src/api/urls/apis.js b/src/api/urls/apis.js index 29eb06a..fe30a69 100644 --- a/src/api/urls/apis.js +++ b/src/api/urls/apis.js @@ -202,5 +202,100 @@ export default { // 个人版首页统计数据 - personalIndex:"/api_html/personal/classList" + personalIndex:"/api_html/personal/index", + // 修改个人信息 + modifyInfo:"/api_html/personal/modifyInfo", + // 查询班级列表 + pClassList:"/api_html/personal/classList", + // 查询科目列表 + pSubjectList:"/api_html/personal/subjectList", + // 查询学生列表 + pStudentList:"/api_html/personal/studentList", + // 新增或修改班级 + pSaveClass:"/api_html/personal/saveClass", + // 增加学生 + pAddStudent:"/api_html/personal/addStudent", + // 删除学生 + pDelStudent:"/api_html/personal/delStudent", + // 查询答题卡类型列表 + pPaperTagList:"/api_html/personal/paperTagList", + // 查询答题卡列表 + pPaperList:"/api_html/personal/paperList", + // 查询答题卡详情 + pPaperDetail:"/api_html/personal/paperDetail", + // 增加答题卡 + pAddPaper:"/api_html/personal/addPaper", + // 修改答题卡 + pModifyPaper:"/api_html/personal/modifyPaper", + // 删除答题卡 + pDelPaper:"/api_html/personal/delPaper", + // 增加答题卡类型 + pAddPaperType:"/api_html/personal/addPaperType", + // 修改答题卡类型 + pModifyPaperType:"/api_html/personal/modifyPaperType", + // 删除答题卡类型 + pDelPaperType:"/api_html/personal/delPaperType", + // 分页查询课时报表列表 + pPeriodReportList:"/api_html/personal/periodReportList", + // 查询阶段问答报表 + pPhaseAnswerReport:"/api_html/personal/phaseAnswerReport", + // 查询阶段互动报表 + pPhaseInteractiveReport:"/api_html/personal/phaseInteractiveReport", + // 查询课时题目列表 + pPeriodQuestionList:"/api_html/personal/periodQuestionList", + // 设置课时报表答案 + pSetPeriodAnswer:"/api_html/personal/setPeriodAnswer", + // 查询课时报表详情 + pPeriodDetail:"/api_html/personal/periodDetail", + // 分页查询课时题目统计列表 + pPeriodQuestionReport:"/api_html/personal/periodQuestionReport", + // 查询课时学生答题明细 + pPeriodStudentReport:"/api_html/personal/periodStudentReport", + // 导出阶段报表 + pExportPhaseReport:"/api_html/personal/exportPhaseReport", + // 分页查询即时测报表 + pExamReportList:"/api_html/personal/examReportList", + // 查询阶段测练报表 + pPhaseExamReport:"/api_html/personal/phaseExamReport", + // 查询即时测报表题目列表 + pExamQuestionList:"/api_html/personal/examQuestionList", + // 设置即时测报表答案 + pSetExamAnswer:"/api_html/personal/setExamAnswer", + // 查询即时测报表详情 + pExamDetail:"/api_html/personal/examDetail", + // 下载导入主观题分模板 + pSubjectiveScoreTemplate:"/api_html/personal/subjectiveScoreTemplate", + // 导入主观题得分 + pImportSubjectiveScore:"/api_html/personal/importSubjectiveScore", + // 分页查询即时测题目统计 + pExamQuestionReport:"/api_html/personal/examQuestionReport", + // 查询即时测学生统计 + pExamStudentReport:"/api_html/personal/examStudentReport", + // 重新判分 + pReScore:"/api_html/personal/reScore", + // 导出单课时报表 + pExportPeriodReport:"/api_html/personal/exportPeriodReport", + // 导出阶段测练报表 + pExportPhaseExamReport:"/api_html/personal/exportPhaseExamReport", + // 导出单卷测练报表 + pExportExamReport:"/api_html/personal/exportExamReport", + // 数据导出 + pExportData:"/api_html/personal/exportData", + // 数据导入 + pImportData:"/api_html/personal/importData", + + + /** 平台管理 */ + //账户管理 + tenantPage:"/api_html/system/tenantPage", + //修改账号 + updateTenant:"/api_html/system/updateTenant", + //新增租户账号 + addTenant:"/api_html/system/addTenant", + // 授课端版本管理 + versionPage:"/api_html/system/versionPage", + // 新增授课端版本 + addVersion:"/api_html/system/addVersion", + // 文件上传 + uploadApp:"/file/uploadApp", } diff --git a/src/router/index.js b/src/router/index.js index 45872fa..a3a55e7 100755 --- a/src/router/index.js +++ b/src/router/index.js @@ -375,6 +375,22 @@ let addrouters = [ //测试用,后续后端获取 const addroutersPersonal = [ { + path: "/setUpStudent", + iconCls: "fa fa-mortar-board", + name: '班级名单', + component: Layout, + alone: true, + children: [ + { + path: "/setUpStudent", + iconCls: "a fa-mortar-board", + name: '', + component: PersonalSetUpStudent, + children: [] + }, + ] + }, + { path: "/examinationPaper", iconCls: "fa fa-file-text", // 图标样式class name: "备题组卷", @@ -499,19 +515,19 @@ const addroutersPersonal = [ ] }, { - path: "/setUpStudent", - iconCls: "fa fa-mortar-board", - name: '班级名单', + path: "/dataSync", + iconCls: "fa fa-random", // 图标样式class + name: "数据同步", component: Layout, alone: true, children: [ { - path: "/setUpStudent", - iconCls: "a fa-mortar-board", - name: '', - component: PersonalSetUpStudent, + path: "/dataSync", + iconCls: "fa fa-random", // 图标样式class + name: "", + component: PersonalDataSync, children: [] - }, + } ] }, { @@ -530,25 +546,6 @@ const addroutersPersonal = [ } ] }, - { - path: "/dataSync", - iconCls: "fa fa-random", // 图标样式class - name: "数据同步", - component: Layout, - alone: true, - children: [ - { - path: "/dataSync", - iconCls: "fa fa-random", // 图标样式class - name: "", - component: PersonalDataSync, - children: [] - } - ] - }, - - - ] const addRoutersAdmin = [ diff --git a/src/views/index/mainIndex.vue b/src/views/index/mainIndex.vue index b1b45b1..11c7ab9 100644 --- a/src/views/index/mainIndex.vue +++ b/src/views/index/mainIndex.vue @@ -278,13 +278,7 @@ export default { }); }, _Init(val) { - let type = ""; - this.$store.getters.info.permissions.map((item) => { - if (item.roleName == val) { - type = item.role; - } - }); - this.type = type ? type : this.$store.getters.info.permissions[0].role; + this.type = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; this.type = 'ROLE_PINGTAI' this.navList = this.$store.getters.addRouters.map((item) => { return { diff --git a/src/views/layout/header/header.vue b/src/views/layout/header/header.vue index 8148a35..470c9b0 100644 --- a/src/views/layout/header/header.vue +++ b/src/views/layout/header/header.vue @@ -105,13 +105,7 @@ export default { }, created() { this.code = localStorage.getItem("csCode") || ""; - let role = ""; - this.$store.getters.info.permissions.map((item) => { - if (item.roleName == this.$store.getters.info.showRoleName) { - role = item.role; - } - }); - this.role = role ? role : this.$store.getters.info.permissions[0].role; + this.role = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; this.isCollapse = this.$store.getters.isCollapse; }, methods: { diff --git a/src/views/personal/ask/analysis.vue b/src/views/personal/ask/analysis.vue index 0e1c13d..e2c0112 100644 --- a/src/views/personal/ask/analysis.vue +++ b/src/views/personal/ask/analysis.vue @@ -420,7 +420,7 @@ export default { this._QueryData(); }, async periodDetail() { - let { data, info, status } = await this.$request.periodDetail({ + let { data, info, status } = await this.$request.pPeriodDetail({ periodId: this.id, }); if (status == 0) { @@ -438,8 +438,8 @@ export default { async _QueryData() { const queryData = this.type == 1 - ? this.$request.periodQuestionReport - : this.$request.periodStudentReport; + ? this.$request.pPeriodQuestionReport + : this.$request.pPeriodStudentReport; let query = {}; if (this.type == 2) { query.type = 1; @@ -494,7 +494,7 @@ export default { async exportData() { if (this.exportLoading == true) return; this.exportLoading = true; - const data = await this.$request.exportPeriodReport({ + const data = await this.$request.pExportPeriodReport({ periodId: this.id, }); this.exportLoading = false; diff --git a/src/views/personal/ask/index.vue b/src/views/personal/ask/index.vue index 63f47c5..44f2cfc 100644 --- a/src/views/personal/ask/index.vue +++ b/src/views/personal/ask/index.vue @@ -517,7 +517,7 @@ export default { this._QueryData(); }, async _QueryClassList() { - const { data, status, info } = await this.$request.tClassList(); + const { data, status, info } = await this.$request.pClassList(); if (status === 0) { this.classList = data.list.map((item) => { return { @@ -531,7 +531,7 @@ export default { } }, async _QuerySubjectList() { - const { data, status, info } = await this.$request.tSubjectList({ + const { data, status, info } = await this.$request.pSubjectList({ classId: this.query.classId, }); if (status === 0) { @@ -588,7 +588,7 @@ export default { this.$message.warning("请选择科目"); return; } - const { data, status, info } = await this.$request.periodReportList({ + const { data, status, info } = await this.$request.pPeriodReportList({ ...query, page: this.page, size: this.size, @@ -624,7 +624,7 @@ export default { this.$message.warning("请选择科目"); return; } - const { data, status, info } = await this.$request.phaseAnswerReport({ + const { data, status, info } = await this.$request.pPhaseAnswerReport({ ...query, }); this.loading = false; @@ -683,7 +683,7 @@ export default { this.$message.warning("请选择科目"); return; } - const { data, status, info } = await this.$request.phaseInteractiveReport( + const { data, status, info } = await this.$request.pPhaseInteractiveReport( { ...query, } @@ -743,7 +743,7 @@ export default { return; } this.exportLoading = true; - const data = await this.$request.exportPhaseAnswerReport({ ...query }); + const data = await this.$request.pExportPhaseReport({ ...query }); this.exportLoading = false; if (data) { let blob = new Blob([data], { diff --git a/src/views/personal/dataSync/index.vue b/src/views/personal/dataSync/index.vue index 12a50b9..24cc1f0 100644 --- a/src/views/personal/dataSync/index.vue +++ b/src/views/personal/dataSync/index.vue @@ -62,7 +62,7 @@ export default { data() { return { downLoading: false, - url: "/api_html/teaching/importData", + url: "/api_html/personal/importData", file: {}, dialogVisible: false, tipData: { @@ -76,7 +76,7 @@ export default { async downloadFile() { if (this.downLoading) return; this.downLoading = true; - const data = await this.$request.exportData(); + const data = await this.$request.pExportData(); this.downLoading = false; console.log(data); if (data) { diff --git a/src/views/personal/examinationPaper/add.vue b/src/views/personal/examinationPaper/add.vue index 7725b82..496cb9c 100644 --- a/src/views/personal/examinationPaper/add.vue +++ b/src/views/personal/examinationPaper/add.vue @@ -1592,7 +1592,7 @@ export default { return; } //修改测验类型 - const { data, status, info } = await this.$request.editPaperType({ + const { data, status, info } = await this.$request.pModifyPaperType({ tagId: obj.id, tag: obj.typeName, }); @@ -1606,7 +1606,7 @@ export default { }, async removeTypeName(obj) { //删除测验类型 - const { data, status, info } = await this.$request.delPaperType({ + const { data, status, info } = await this.$request.pDelPaper({ tagId: obj.id, }); if (status == 0) { @@ -1634,7 +1634,7 @@ export default { return; } //添加测验类型 - const { data, status, info } = await this.$request.addPaperType({ + const { data, status, info } = await this.$request.pAddPaperType({ tag: this.answerTypeName, }); if (status == 0) { @@ -1655,7 +1655,7 @@ export default { for (let i = 0; i < formDatas.questionList.length; i++) { delete formDatas.questionList[i].show; } - const { data, status, info } = await this.$request.addPaper({ + const { data, status, info } = await this.$request.pAddPaper({ ...formDatas, }); this.saveLoading = false; @@ -1669,7 +1669,7 @@ export default { }, async _TypeList() { //测验类型查询 - const { data, status, info } = await this.$request.fetchTypeNames({ + const { data, status, info } = await this.$request.pPaperTagList({ type: 1, }); if (status == 0) { @@ -1690,7 +1690,7 @@ export default { async _QuerySubjectList() { //查询科目列表 - const { data, status, info } = await this.$request.fetchSubjectList(); + const { data, status, info } = await this.$request.pSubjectList(); if (status === 0) { this.subjectList = data.subjectNames?.map((item) => { @@ -1709,8 +1709,8 @@ export default { } }, async _QueryDetail() { - //查询年级列表 - const { data, status, info } = await this.$request.fetchPaperDetail({ + //查询答题卡详情 + const { data, status, info } = await this.$request.pPaperDetail({ paperId: this.$route.query.paperId, }); if (status == 0) { diff --git a/src/views/personal/examinationPaper/detail.vue b/src/views/personal/examinationPaper/detail.vue deleted file mode 100644 index 4611414..0000000 --- a/src/views/personal/examinationPaper/detail.vue +++ /dev/null @@ -1,190 +0,0 @@ - - - - - \ No newline at end of file diff --git a/src/views/personal/examinationPaper/edit.vue b/src/views/personal/examinationPaper/edit.vue index aaa7c89..d7a48b6 100644 --- a/src/views/personal/examinationPaper/edit.vue +++ b/src/views/personal/examinationPaper/edit.vue @@ -758,19 +758,19 @@ export default { //更新答题卡 let modifyPaper, params; if (this.type == 1) { - modifyPaper = this.$request.modifyPaper; + modifyPaper = this.$request.pModifyPaper; params = { paperId: this.$route.query.paperId, questionList: questionList, }; } else if (this.type == 2) { - modifyPaper = this.$request.setExamAnswer; + modifyPaper = this.$request.pSetExamAnswer; params = { examId: this.$route.query.paperId, questionList: questionList, }; } else { - modifyPaper = this.$request.setPeriodAnswer; + modifyPaper = this.$request.pSetPeriodAnswer; params = { periodId: this.$route.query.paperId, questionList: questionList, @@ -787,10 +787,10 @@ export default { //查询详情 let detail = this.type == 1 - ? this.$request.fetchPaperDetail + ? this.$request.pPaperDetail : this.type == 2 - ? this.$request.examQuestionList - : this.$request.periodQuestionList; + ? this.$request.pExamQuestionList + : this.$request.pPeriodQuestionList; let params = this.type == 1 ? { paperId: this.$route.query.paperId } diff --git a/src/views/personal/examinationPaper/index.vue b/src/views/personal/examinationPaper/index.vue index 14804d6..26711df 100644 --- a/src/views/personal/examinationPaper/index.vue +++ b/src/views/personal/examinationPaper/index.vue @@ -217,7 +217,7 @@ export default { }, async recovery(item) { //归档 - const { data, status, info } = await this.$request.modifyPaper({ + const { data, status, info } = await this.$request.pModifyPaper({ paperId: item.id, status: 2, }); @@ -236,7 +236,7 @@ export default { }, // 查找答题卡类型 async _QueryTypeList() { - const { data, status, info } = await this.$request.fetchTypeNames({ + const { data, status, info } = await this.$request.pPaperTagList({ classId: this.query.classId, type: 0, }); @@ -259,7 +259,7 @@ export default { // 查找班级 async _QueryClassList() { this.loading = true; - const { data, status, info } = await this.$request.fetchClassList(); + const { data, status, info } = await this.$request.pClassList(); console.log(status); if (status === 0) { if (!!data.list) { @@ -278,7 +278,7 @@ export default { }, // 查找科目 async _QuerySubjectList() { - const { data, status, info } = await this.$request.fetchSubjectList({ + const { data, status, info } = await this.$request.pSubjectList({ classId: this.query.classId, }); if (status === 0) { @@ -320,7 +320,7 @@ export default { return; } this.loading = true; - const { data, status, info } = await this.$request.fetchPaperList({ + const { data, status, info } = await this.$request.pPaperList({ ...query, status: 1, page: this.page, diff --git a/src/views/personal/examinationPaper/recycle.vue b/src/views/personal/examinationPaper/recycle.vue index 110986a..f8f63f4 100644 --- a/src/views/personal/examinationPaper/recycle.vue +++ b/src/views/personal/examinationPaper/recycle.vue @@ -200,7 +200,7 @@ export default { methods: { async modify(obj) { //恢复答题卡 - const { data, status, info } = await this.$request.modifyPaper({ + const { data, status, info } = await this.$request.pModifyPaper({ paperId: obj.id, status: 1, }); @@ -213,7 +213,7 @@ export default { }, async remove(obj) { //删除答题卡 - const { data, status, info } = await this.$request.delPaper({ + const { data, status, info } = await this.$request.pDelPaper({ paperId: obj.id, }); if (status == 0) { @@ -250,7 +250,7 @@ export default { query[key] = null; } } - const { data, status, info } = await this.$request.fetchPaperList({ + const { data, status, info } = await this.$request.pPaperList({ ...query, status:2, page:this.page, @@ -266,7 +266,7 @@ export default { }, // 查找班级 async _QueryClassList() { - const { data, status, info } = await this.$request.fetchClassList(); + const { data, status, info } = await this.$request.pClassList(); console.log(status); if (status === 0) { if (!!data.list) { @@ -284,7 +284,7 @@ export default { }, // 查找科目 async _QuerySubjectList() { - const { data, status, info } = await this.$request.fetchSubjectList({ + const { data, status, info } = await this.$request.pSubjectList({ classId: this.query.classId, }); if (status === 0) { @@ -301,7 +301,7 @@ export default { }, // 查找答题卡类型 async _QueryTypeList() { - const { data, status, info } = await this.$request.fetchTypeNames({ + const { data, status, info } = await this.$request.pPaperTagList({ classId: this.query.classId, tyle:0 }); diff --git a/src/views/personal/portrait/detail.vue b/src/views/personal/portrait/detail.vue index 5a9e839..fa96804 100644 --- a/src/views/personal/portrait/detail.vue +++ b/src/views/personal/portrait/detail.vue @@ -307,7 +307,7 @@ export default { } }, async _QuerySubjectList() { - const { data, status, info } = await this.$request.tSubjectList({ + const { data, status, info } = await this.$request.pSubjectList({ classId: this.classId, }); if (status === 0) { diff --git a/src/views/personal/portrait/index.vue b/src/views/personal/portrait/index.vue index b0cc45d..71fecef 100644 --- a/src/views/personal/portrait/index.vue +++ b/src/views/personal/portrait/index.vue @@ -224,7 +224,7 @@ export default { } }, async _QueryClassList() { - const { data, status, info } = await this.$request.tClassList(); + const { data, status, info } = await this.$request.pClassList(); if (status === 0) { this.classList = data.list.map((item) => { return { @@ -246,7 +246,7 @@ export default { } } return; - const { data, status, info } = await this.$request.studentList({ + const { data, status, info } = await this.$request.pStudentList({ ...query, page: this.page, size: this.size, diff --git a/src/views/personal/setUp/student.vue b/src/views/personal/setUp/student.vue index 5d6d9a4..d886bb7 100644 --- a/src/views/personal/setUp/student.vue +++ b/src/views/personal/setUp/student.vue @@ -322,7 +322,7 @@ export default { this.loadingDown = false; if (status == 0) { getBlob(data.downloadUrl).then((res) => { - downloadFile("学生答题器绑定模板", res); + downloadFile("学生模板", res); }); } else { this.$message.error(info); diff --git a/src/views/personal/test/analysis.vue b/src/views/personal/test/analysis.vue index 10221d7..3ed4742 100644 --- a/src/views/personal/test/analysis.vue +++ b/src/views/personal/test/analysis.vue @@ -535,7 +535,7 @@ export default { this.examQuestionReport(); }, async downExcel() { - let data = await this.$request.subjectiveScoreTemplate({ + let data = await this.$request.pSubjectiveScoreTemplate({ examId: this.id, }); if (data && !data.code) { @@ -555,7 +555,7 @@ export default { async examDetail() { //详情 this.loading = true; - let { data, info, status } = await this.$request.examDetail({ + let { data, info, status } = await this.$request.pExamDetail({ examId: this.id, }); this.loading = false; @@ -571,7 +571,7 @@ export default { async _ReScore() { //重新记分 this.loading = true; - let { data, info, status } = await this.$request.reScore({ + let { data, info, status } = await this.$request.pReScore({ examId: this.id, }); this.loading = false; @@ -587,7 +587,7 @@ export default { async examStudentReport() { //成绩排名-小题分-作答明细 this.loading = true; - let { data, info, status } = await this.$request.examStudentReport({ + let { data, info, status } = await this.$request.pExamStudentReport({ examId: this.id, }); this.loading = false; @@ -626,7 +626,7 @@ export default { async examQuestionReport() { //试题分析 this.loading = true; - let { data, info, status } = await this.$request.examQuestionReport({ + let { data, info, status } = await this.$request.pExamQuestionReport({ examId: this.id, page: this.page, // size: this.size, @@ -690,7 +690,7 @@ export default { async exportData() { if (this.exportLoading == true) return; this.exportLoading = true; - const data = await this.$request.exportExamReport({ + const data = await this.$request.pExportExamReport({ examId: this.id, }); this.exportLoading = false; diff --git a/src/views/personal/test/index.vue b/src/views/personal/test/index.vue index a0d8741..4916a6c 100644 --- a/src/views/personal/test/index.vue +++ b/src/views/personal/test/index.vue @@ -625,7 +625,7 @@ export default { }, async downExcel() { this.loadingDown = true; - let data = await this.$request.subjectiveScoreTemplate({ + let data = await this.$request.pSubjectiveScoreTemplate({ examId: this.examId, }); this.loadingDown = false; @@ -644,7 +644,7 @@ export default { await this._QueryData(); }, async _QueryClassList() { - const { data, status, info } = await this.$request.tClassList(); + const { data, status, info } = await this.$request.pClassList(); if (status === 0) { this.classList = data.list.map((item) => { return { @@ -658,7 +658,7 @@ export default { } }, async _QuerySubjectList() { - const { data, status, info } = await this.$request.tSubjectList({ + const { data, status, info } = await this.$request.pSubjectList({ classId: this.query.classId, }); if (status === 0) { @@ -711,7 +711,7 @@ export default { this.$message.warning("请选择科目"); return; } - const { data, status, info } = await this.$request.examReportList({ + const { data, status, info } = await this.$request.pExamReportList({ ...query, page: this.page, size: this.size, @@ -748,7 +748,7 @@ export default { query["subjectName"] = "政治"; delete query["subjectNames"]; // end - const { data, status, info } = await this.$request.phaseExamReport({ + const { data, status, info } = await this.$request.pPhaseExamReport({ ...query, }); this.loading = false; @@ -799,7 +799,7 @@ export default { this.$message.warning("请选择科目"); return; } - const data = await this.$request.exportPhaseExamReport({ ...query }); + const data = await this.$request.pExportPhaseExamReport({ ...query }); this.exportLoading = false; if (data) { let blob = new Blob([data], { diff --git a/src/views/standard/analysis/index.vue b/src/views/standard/analysis/index.vue index 6e5ee6f..203e6f4 100644 --- a/src/views/standard/analysis/index.vue +++ b/src/views/standard/analysis/index.vue @@ -172,9 +172,7 @@ export default { }; }, created() { - this.role = this.$store.getters.info.permissions.find( - (item) => item.roleName == this.$store.getters.info.showRoleName - )?.role; + this.role = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; this._QueryGradeList(); this.setDate(1); let startDay = this.query?.startDay; diff --git a/src/views/standard/ask/index.vue b/src/views/standard/ask/index.vue index 2033c73..58da1d1 100644 --- a/src/views/standard/ask/index.vue +++ b/src/views/standard/ask/index.vue @@ -506,9 +506,7 @@ export default { }; }, async created() { - this.role = this.$store.getters.info.permissions.find( - (item) => item.roleName == this.$store.getters.info.showRoleName - )?.role; + this.role = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; this.query.subjectNames = this.role == "ROLE_BANZHUREN" ? [] : ""; await this._QueryClassList(); await this._QuerySubjectList(); diff --git a/src/views/standard/device/index.vue b/src/views/standard/device/index.vue index 3520469..cffca08 100644 --- a/src/views/standard/device/index.vue +++ b/src/views/standard/device/index.vue @@ -585,13 +585,7 @@ export default { }, created() { this.code = localStorage.getItem("csCode") || ""; - let role = ""; - this.$store.getters.info.permissions.map((item) => { - if (item.roleName == this.$store.getters.info.showRoleName) { - role = item.role; - } - }); - this.role = role ? role : this.$store.getters.info.permissions[0].role; + this.role = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; if (this.role == "ROLE_JITUAN") { (this.props.lazy = true), (this.props.lazyLoad = function (node, resolve) { diff --git a/src/views/standard/examinationPaper/add.vue b/src/views/standard/examinationPaper/add.vue index 32c4e41..12f431a 100644 --- a/src/views/standard/examinationPaper/add.vue +++ b/src/views/standard/examinationPaper/add.vue @@ -1699,7 +1699,7 @@ export default { } }, async _QueryDetail() { - //查询年级列表 + //查询答题卡详情 const { data, status, info } = await this.$request.fetchPaperDetail({ paperId: this.$route.query.paperId, }); diff --git a/src/views/standard/setUp/account.vue b/src/views/standard/setUp/account.vue index 0c4b820..8b2e20c 100644 --- a/src/views/standard/setUp/account.vue +++ b/src/views/standard/setUp/account.vue @@ -429,13 +429,7 @@ export default { }, created() { this.code = localStorage.getItem("csCode") || ""; - let role = ""; - this.$store.getters.info.permissions.map((item) => { - if (item.roleName == this.$store.getters.info.showRoleName) { - role = item.role; - } - }); - this.role = role ? role : this.$store.getters.info.permissions[0].role; + this.role = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; if (this.role == "ROLE_JITUAN") { this._TenantRoleList(); this._RegionList(); diff --git a/src/views/standard/setUp/student.vue b/src/views/standard/setUp/student.vue index 6fa8051..650c373 100644 --- a/src/views/standard/setUp/student.vue +++ b/src/views/standard/setUp/student.vue @@ -288,13 +288,7 @@ export default { }, async created() { this.code = localStorage.getItem("csCode") || ""; - let role = ""; - this.$store.getters.info.permissions.map((item) => { - if (item.roleName == this.$store.getters.info.showRoleName) { - role = item.role; - } - }); - this.role = role ? role : this.$store.getters.info.permissions[0].role; + this.role = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; await this._QueryDataGrade(); await this._QueryClass(); this._QueryData(3); diff --git a/src/views/standard/test/index.vue b/src/views/standard/test/index.vue index adcdb1e..9fc5668 100644 --- a/src/views/standard/test/index.vue +++ b/src/views/standard/test/index.vue @@ -506,9 +506,7 @@ export default { }; }, async created() { - this.role = this.$store.getters.info.permissions.find( - (item) => item.roleName == this.$store.getters.info.showRoleName - )?.role; + this.role = this.$store.getters.info.showRole || this.$store.getters.info.permissions[0].role; await this._QueryClassList(); await this._QuerySubjectList(); await this.setDate(1); -- libgit2 0.21.4