From 365ec55cb52250c98e50c26b85323adb77ef2310 Mon Sep 17 00:00:00 2001 From: yujialong <479214531@qq.com> Date: Wed, 13 Oct 2021 17:02:43 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=B5=8B=E8=AF=95=E6=9C=8D?= =?UTF-8?q?=EF=BC=8C=E5=AE=8C=E5=96=84=E5=8A=9F=E8=83=BD=EF=BC=8C=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/index.js | 16 ++-- src/pages/assessment/add/index.vue | 6 +- src/pages/assessment/list/index.vue | 11 ++- src/pages/course/courseManagement/preview.vue | 4 +- src/pages/match/index.vue | 13 ++-- src/pages/project/add/index.vue | 76 ++++++++----------- src/pages/project/list/index.vue | 20 +++-- src/setting.js | 58 +++++--------- 8 files changed, 90 insertions(+), 114 deletions(-) diff --git a/src/api/index.js b/src/api/index.js index 925f7b7..fe970e3 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -1,16 +1,9 @@ import Setting from "@/setting"; -// let host = Setting.apiBaseURL -// let host = "http://192.168.31.151:9000/"; // 榕 -// let host = 'http://192.168.31.125:9000/'; // 坤 - -let host = "http://39.108.250.202:9000/"; // 测试服 - - +let host = Setting.apiBaseURL let uploadURL = Setting.upload.apiURL; let host1 = "http://39.108.250.202:8080/"; // 川大 export default { - // fileupload: `${uploadURL}oss/manage/fileupload`, queryToken: `${host}liuwanr/userInfo/queryToken`, logins: `${host}users/users/user/login`, //登录 @@ -75,6 +68,7 @@ export default { deleteReportById: `${host}occupationlab/achievement/deleteReportById`, // 批量删除成绩管理中的项目/批量删除成绩管理中的考核 // 项目管理 + getSystemIdBySchool: `${host}occupationlab/projectManage/getSystemIdBySchool`, // 获取学校下拥有的系统 avgValues: `${host}occupationlab/projectManage/avgValues`, // 平均分分配值 deleteProjectManage: `${host}occupationlab/projectManage/deleteProjectManage`, // 新增项目管理 getProjectBySystemId: `${host}occupationlab/projectManage/getProjectBySystemId`, // 根据系统id获取全部项目(项目中没有用上这个接口) @@ -160,9 +154,9 @@ export default { getSubsection: `${host}occupationlab/management/edu/courseSubsection/getSubsection`, // 根据小节id获取预览文件地址 // 阿里云文件/视频管理 - fileDeletion: `${host}nakadai/nakadai/oss/fileDeletion`, // 删除OSS文件 - fileupload: `${host}nakadai/nakadai/oss/fileUpload`, // 文件上传 - getPlayAuth: `${host}nakadai/nakadai/oss/getPlayAuth`, // 获取播放凭证 + fileDeletion: `${uploadURL}oss/manage/fileDeletion`, // 删除OSS文件 + fileupload: `${uploadURL}oss/manage/fileUpload`, // 文件上传 + getPlayAuth: `${uploadURL}oss/manage/getPlayAuth`, // 获取播放凭证 diff --git a/src/pages/assessment/add/index.vue b/src/pages/assessment/add/index.vue index 3e22d0f..2a14f72 100644 --- a/src/pages/assessment/add/index.vue +++ b/src/pages/assessment/add/index.vue @@ -373,9 +373,13 @@ export default { return resolve([]); } }, - getschoolCourse() { + getschoolCourse() { // 获取课程 this.$get(this.api.schoolCourse).then(res => { this.curriculumList = res.data; + if (this.curriculumList.length) { + this.form.curriculumId = this.curriculumList[0].cid; + this.getProjectData(); + } }).catch(err => { console.log(err); }); diff --git a/src/pages/assessment/list/index.vue b/src/pages/assessment/list/index.vue index 974c8dc..c7c785e 100644 --- a/src/pages/assessment/list/index.vue +++ b/src/pages/assessment/list/index.vue @@ -152,10 +152,10 @@ export default { }, { value: 2, - name: "已完成" + name: "已结束" } ], - status: ["待开始", "进行中", "已完成"], + status: ["待开始", "进行中", "已结束"], dateList: [ { id: "", @@ -248,6 +248,13 @@ export default { const item = this.listData[i]; if (item.countDown > 0) { item.countDown--; + } else { + if (item.status === 0 && item.type === 2) { // 待开始-定时发布 + item.status = 1; + item.countDown = (new Date(item.stopTime).getTime() - new Date().getTime()) / 1000; + } else if (item.status === 1) { + item.status = 2; + } } this.$set(this.listData, i, item); } diff --git a/src/pages/course/courseManagement/preview.vue b/src/pages/course/courseManagement/preview.vue index 051b19c..0354c5c 100644 --- a/src/pages/course/courseManagement/preview.vue +++ b/src/pages/course/courseManagement/preview.vue @@ -7,8 +7,8 @@ - -
+ +
- - - + + - + @@ -52,10 +51,8 @@ {{ scope.row.playStartTime }} ~ {{ scope.row.playEndTime }} - - - - + +