From 12b19d4fbb6cc935bdc0b5f210e792923ed57d41 Mon Sep 17 00:00:00 2001 From: daihh Date: Fri, 3 Mar 2023 14:57:42 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=91=E7=9A=84=E4=BB=BB=E5=8A=A1=E6=8F=90?= =?UTF-8?q?=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/study/TaskList.vue | 66 ++++++++++++++++++------------------ vue.config.js | 2 +- 2 files changed, 34 insertions(+), 34 deletions(-) diff --git a/src/views/study/TaskList.vue b/src/views/study/TaskList.vue index c5ad1982..b98f50f3 100644 --- a/src/views/study/TaskList.vue +++ b/src/views/study/TaskList.vue @@ -122,17 +122,17 @@ export default { methods: { jumpRouter(item) { - //window.open(`${this.webBaseUrl}/course/boeframe?id=${item.cmtask_id}`,'_self') - location.href=`${this.webBaseUrl}/course/boeframe?id=${item.cmtask_id}`; - - let urlPre=window.location.protocol+'//'+window.location.host; - // if(item.cmtask_type==1){ //学习路径图 - // //let params=encodeURIComponent('projectId='+courseId); - // //this.$router.push('/forward?to='+studentPath+'/projectdetails¶ms='+params); - // location.href=urlPre+'/fe-student/pathdetails?routerId='+item.cmtask_code - // }else if(item.cmtask_type==2){ //学习项目 - // location.href=urlPre+'/fe-student/projectdetails?projectId='+item.cmtask_code - // } + //location.href=`${this.webBaseUrl}/course/boeframe?id=${item.cmtask_id}`; + + //let urlPre=window.location.protocol+'//'+window.location.host; + let studentPath=process.env.VUE_APP_STUDENT_PATH; + if(item.cmtask_type==1){ //学习路径图 + let params=encodeURIComponent('projectId='+item.cmtask_id); + this.$router.push('/forward?to='+studentPath+'/pathdetails¶ms='+params); + }else if(item.cmtask_type==2){ //学习项目 + let params=encodeURIComponent('routerId='+item.cmtask_id); + this.$router.push('/forward?to='+studentPath+'/projectdetails¶ms='+params); + } }, loadBoeData() { @@ -146,29 +146,29 @@ export default { cmtask_name:this.params.cmtask_name, } this.loading=true; - // apiManage.userTaskList(params).then(res=>{ - // if(res.code==200){ - // this.total = 10; - // this.couresList = res.data.records; - // }else{ - // this.$message.error('查询数据失败:'+res.msg); - // } - // this.loading=false; - // }).catch(()=>{ - // this.loading=false; - // }) - apiBoeCourse.cmtaskList(params).then(res=>{ - if(res.status==200){ - this.total = res.result.count - this.couresList = res.result.list; - }else{ - this.$message.error('查询数据失败:'+res.message); - } - this.loading=false; + apiManage.userTaskList(params).then(res=>{ + if(res.code==200){ + this.total =parseInt(res.data.total); + this.couresList = res.data.records; + }else{ + this.$message.error('查询数据失败:'+res.msg); + } + this.loading=false; + }).catch(()=>{ + this.loading=false; + }) + // apiBoeCourse.cmtaskList(params).then(res=>{ + // if(res.status==200){ + // this.total = res.result.count + // this.couresList = res.result.list; + // }else{ + // this.$message.error('查询数据失败:'+res.message); + // } + // this.loading=false; - }).catch(()=>{ - this.loading=false; - }) + // }).catch(()=>{ + // this.loading=false; + // }) }, search(){ this.loadBoeData() diff --git a/vue.config.js b/vue.config.js index 7523fae1..941ef445 100644 --- a/vue.config.js +++ b/vue.config.js @@ -138,7 +138,7 @@ module.exports = { }, '/uboeApi': { // 目标代理服务器地址 - target: 'https://u-pre.boe.comww', + target: 'https://u-pre.boe.com', changeOrigin: true, secure: false, pathRewrite: {