From 4ef4b60b672cc781cb9772048cbd0d7513eab0a6 Mon Sep 17 00:00:00 2001 From: "jialong.yu" Date: Mon, 20 Dec 2021 10:08:11 +0800 Subject: [PATCH] =?UTF-8?q?=E8=80=83=E6=A0=B8=E3=80=81=E7=BB=83=E4=B9=A0?= =?UTF-8?q?=E8=BF=9B=E5=85=A5python=E4=BC=A0=E5=8F=82=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/ass/list/index.vue | 33 ++++++++++++++++------------- src/pages/station/preview/index.vue | 5 +++-- 2 files changed, 21 insertions(+), 17 deletions(-) diff --git a/src/pages/ass/list/index.vue b/src/pages/ass/list/index.vue index 487e786..11eaa8b 100644 --- a/src/pages/ass/list/index.vue +++ b/src/pages/ass/list/index.vue @@ -329,7 +329,6 @@ export default { this.listData[i].reportId = null } } - console.log(this.listData) this.totals = res.total; this.listData.forEach(i => { i.show = false; @@ -399,7 +398,7 @@ export default { this.curRow = row; if (row.isEnableCode == 0) { // 是否启用邀请码(0、未启用 1、启用) this.$post(`${this.api.enterExam}?assessmentId=${row.assessmentId}&classId=${row.classId}`).then(res => { - console.log(res) + console.log('entry', res) this.curRow.curriculumId = res.info.systemId this.projectId = res.projectId this.url = res.url @@ -425,7 +424,7 @@ export default { if (!this.invitationCode || String(this.invitationCode).length < 6 || isNaN(this.invitationCode)) return util.warningMsg("请输入6位纯数字邀请码"); this.$post(`${this.api.enterExam}?assessmentId=${this.item.assessmentId}&classId=${this.item.classId}&invitationCode=${this.invitationCode}`).then(res => { util.successMsg("验证成功!"); - console.log(res) + console.log('save', res) this.icVisible = false; this.projectId = res.projectId this.url = res.url @@ -441,18 +440,21 @@ export default { this.invitationCode = ""; }, goSubSystem() { - let host = this.host; - util.cookies.set("assessmentId", this.curRow.id); - util.cookies.set("studentId", this.studentId); - util.cookies.set("userId", this.userId); - util.cookies.set("projectId", this.projectId); - util.cookies.set("startTime", this.curRow.startTime); - util.cookies.set("stopTime", this.curRow.stopTime); - let curriculumId = this.curRow.curriculumId; - let token = util.local.get(Setting.tokenKey); - let href = ""; - let aaa = ''; - console.log(curriculumId) + let host = this.host + let token = util.local.get(Setting.tokenKey) + const classId = this.classId + const classItem = this.classList.find(e => e.id == classId) + util.cookies.set("token", token) + util.cookies.set("assessmentId", this.assessmentId) + util.cookies.set("classId", classId) + util.cookies.set("className", classItem ? encodeURI(classItem.className) : '') + util.cookies.set("projectId", this.projectId) + util.cookies.set("courseId", this.cid) + util.cookies.set("startTime", this.curRow.startTime) + util.cookies.set("stopTime", this.curRow.stopTime) + let curriculumId = this.curRow.curriculumId + let href = '' + let aaa = '' aaa = host.slice(0,host.length-6) if (curriculumId == 11){ //线上 @@ -460,6 +462,7 @@ export default { //测试与本地 href = `${aaa}/${this.url}/#/index/list?token=${token}&cid=${this.cid}&systemId=${this.systemId}&projectId=${this.projectId}&assessmentId=${this.assessmentId}&classId=${this.classId}&stopTime=${this.stopTime}`; }else{ + // href = 'http://192.168.31.125:8080/#/' href = `${aaa}/${this.url}/#/index/list?token=${token}&cid=${this.cid}&systemId=${this.systemId}&projectId=${this.projectId}&assessmentId=${this.assessmentId}&classId=${this.classId}&stopTime=${this.stopTime}`; } // switch (curriculumId) { diff --git a/src/pages/station/preview/index.vue b/src/pages/station/preview/index.vue index b12fffc..90072e1 100644 --- a/src/pages/station/preview/index.vue +++ b/src/pages/station/preview/index.vue @@ -293,8 +293,7 @@ export default { let userName = window.btoa(encodeURIComponent(this.userName)); if (id == 1) { - // href = `${host}pyTrials/#/`; - if(process.env.NODE_ENV === 'development') href = 'http://192.168.31.125:8080/#/' + href = `${host}pyTrials/#/`; } else if (id == 4) { href = `${host}pyFinance/#/`; } else if (id == 5) { @@ -326,6 +325,7 @@ export default { window.open(`https://danbao.czcyedu.com/#/loginFromYyyf?userId=${this.userId}&userName=${userName}&userType=${roleId}&reqType=1&reqId=eb7d8355119d449184c548b07dc01ed9&caseId=1198241070647873538&authorization=87DIVy348Oxzj3ha&classId=1876&courserId=faaedd82adb9444285a5785e4a3dd4f9`); } + // if(process.env.NODE_ENV === 'development') href = 'http://192.168.31.125:8080/#/' if (id != 21 && id != 22) { util.cookies.set("userId", this.userId); util.cookies.set("studentId", this.studentId); @@ -335,6 +335,7 @@ export default { util.cookies.set("stopTime", "", -1); util.cookies.set("token", token); util.cookies.set("courseId", this.courseId); + util.cookies.set("systemId", id); location.href = href; } }