diff --git a/src/api/index1.js b/src/api/index1.js index 34e6f565..42b3b5bd 100644 --- a/src/api/index1.js +++ b/src/api/index1.js @@ -43,14 +43,26 @@ export const uploadFile = (obj) => http.post('/test/testRequest', qs.stringify({ export const createLearnPath = (obj) => http.post('/admin/router/edit', obj); // 获取学习路径图列表 export const getLearnPath = (obj) => http.post('/admin/router/list', obj); -//删除学习路径图 -export const deleteLearnPath = (obj) => http.post('/admin/router/handle', obj); +//学习路径图的发布、停用、删除 +export const handleLearnPath = (obj) => http.post('/admin/router/handle', obj); //获取关卡 export const getChapter = (obj) => http.post('/admin/router/detail', { params: obj }); //新建或编辑关卡 export const editChapter = (obj) => http.post('/admin/router/editChapter', obj); +//获取学员列表 +export const getStudent = (obj) => http.post('/admin/router/studentList', obj); +//获取路径图详情-包含关卡及任务列表 +export const getRouterDetail = (routerId) => http.get('/admin/router/detail', { + params: { + routerId: routerId, + } +}); + + + + // 测试方法 // import * as api from '../../api/index' diff --git a/src/api/indexExam.js b/src/api/indexExam.js index fc9a30af..727dd42c 100644 --- a/src/api/indexExam.js +++ b/src/api/indexExam.js @@ -8,7 +8,10 @@ export const createExamination = (obj) => http.post('/examination/createExaminat // 根据Id删除考试信息 export const deleteExaminationById = (obj) => http.post('/examination/deleteExaminationById',obj); // 根据ID获取考试信息详情 -export const queryExaminationDetailById = (obj) => http.post('/examination/queryExaminationDetailById',obj); +export const queryExaminationDetailById = (obj) => http.post('/examination/queryExaminationDetailById',obj,{headers: { + 'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8' +} +}); // 创建考试信息接口 export const updateExamination = (obj) => http.post('/examination/updateExamination',obj); diff --git a/src/api/indexWork.js b/src/api/indexWork.js index 49ab456a..d44b72eb 100644 --- a/src/api/indexWork.js +++ b/src/api/indexWork.js @@ -8,7 +8,11 @@ export const createWorkTask = (obj) => http.post('/work/createWorkTask',obj,{ // 删除作业信息接口 export const deleteWorkTask = (obj) => http.post('/work/deleteWorkTask',obj); // 根据ID获取作业信息详情 -export const queryWorkDetailById = (obj) => http.post('/work/queryWorkDetailById',obj); +export const queryWorkDetailById = (obj) => http.post('/work/queryWorkDetailById',obj,{ + headers: { + 'Content-Type': 'application/x-www-form-urlencoded;charset=UTF-8' + } +}); // 修改作业信息接口 export const updateWorkTaskUsing = (obj) => http.post('/work/updateWorkTask',obj); diff --git a/src/components/BreadCrumb.vue b/src/components/BreadCrumb.vue index 1229413b..2abfc972 100644 --- a/src/components/BreadCrumb.vue +++ b/src/components/BreadCrumb.vue @@ -33,7 +33,10 @@ export default { // console.log("监听路由"); console.log("new:" + n + ",old:" + o); - if (n === "/learningpath" || n === "/LearningPath") { + if ( + n.indexOf("/learningpath") !== -1 || + n.indexOf("/LearningPath") !== -1 + ) { state.list = [ { name: "学习路径", @@ -42,25 +45,28 @@ export default { }, ]; } - if (n === "/leveladd" || n === "/LevelAdd") { + if (n.indexOf("/leveladd") !== -1 || n.indexOf("/LevelAdd") !== -1) { state.list = [ { name: "学习路径", href: "/learningpath", }, { - name: "关卡", + name: "管理", }, ]; } - if (n === "/leveladddetail" || n === "/LevelAddDetail") { + if ( + n.indexOf("/leveladddetail") !== -1 || + n.indexOf("/LevelAddDetail") !== -1 + ) { state.list = [ { name: "学习路径", href: "/learningpath", }, { - name: "关卡", + name: "管理", href: "/leveladd", }, { @@ -68,14 +74,17 @@ export default { }, ]; } - if (n === "/levelcheck" || n === "/LevelCheck") { + if ( + n.indexOf("/levelcheck") !== -1 || + n.indexOf("/LevelCheck") !== -1 + ) { state.list = [ { name: "学习路径", href: "/learningpath", }, { - name: "关卡", + name: "管理", href: "/leveladd", }, { @@ -83,7 +92,10 @@ export default { }, ]; } - if (n === "/projectmanage" || n === "/ProjectManage") { + if ( + n.indexOf("/projectmanage") !== -1 || + n.indexOf("/ProjectManage") !== -1 + ) { state.list = [ { name: "项目中心", @@ -96,7 +108,10 @@ export default { }, ]; } - if (n === "/projectadd" || n === "/ProjectAdd") { + if ( + n.indexOf("/projectadd") !== -1 || + n.indexOf("/ProjectAdd") !== -1 + ) { state.list = [ { name: "项目", @@ -107,7 +122,7 @@ export default { }, ]; } - if (n === "/taskpage" || n === "/TaskPage") { + if (n.indexOf("/taskpage") !== -1 || n.indexOf("/TaskPage") !== -1) { state.list = [ { name: "项目", @@ -118,7 +133,7 @@ export default { }, ]; } - if (n === "/taskadd" || n === "/TaskAdd") { + if (n.indexOf("/taskadd") !== -1 || n.indexOf("/TaskAdd") !== -1) { state.list = [ { name: "项目", @@ -135,7 +150,10 @@ export default { }, ]; } - if (n === "/templatelibrary" || n === "/TemplateLibrary") { + if ( + n.indexOf("/templatelibrary") !== -1 || + n.indexOf("/TemplateLibrary") !== -1 + ) { state.list = [ { name: "项目中心", @@ -145,7 +163,10 @@ export default { }, ]; } - if (n === "/libraryadd" || n === "/LibraryAdd") { + if ( + n.indexOf("/libraryadd") !== -1 || + n.indexOf("/LibraryAdd") !== -1 + ) { state.list = [ { name: "项目中心", @@ -155,11 +176,14 @@ export default { }, { name: "查看", - href:"/libraryadd", + href: "/libraryadd", }, ]; } - if (n === "/coursemanage" || n === "/CourseManage") { + if ( + n.indexOf("/coursemanage") !== -1 || + n.indexOf("/CourseManage") !== -1 + ) { state.list = [ { name: "课程库", @@ -172,7 +196,10 @@ export default { }, ]; } - if (n === "/coursewaremanage" || n === "/CoursewareManage") { + if ( + n.indexOf("/coursewaremanage") !== -1 || + n.indexOf("/CoursewareManage") !== -1 + ) { state.list = [ { name: "课程库", @@ -182,7 +209,10 @@ export default { }, ]; } - if (n === "/researchmanage" || n === "/ResearchManage") { + if ( + n.indexOf("/researchmanage") !== -1 || + n.indexOf("/ResearchManage") !== -1 + ) { state.list = [ { name: "评估管理", @@ -191,7 +221,10 @@ export default { }, ]; } - if (n === "/managepage" || n === "/ManagePage") { + if ( + n.indexOf("/managepage") !== -1 || + n.indexOf("/ManagePage") !== -1 + ) { state.list = [ { name: "评估管理", @@ -204,7 +237,10 @@ export default { ]; } - if (n === "/researchadd" || n === "/ResearchAdd") { + if ( + n.indexOf("/researchadd") !== -1 || + n.indexOf("/ResearchAdd") !== -1 + ) { state.list = [ { name: "评估管理", @@ -217,14 +253,20 @@ export default { ]; } - if (n === "/certificatecenter" || n === "/CertificateCenter") { + if ( + n.indexOf("/certificatecenter") !== -1 || + n.indexOf("/CertificateCenter") !== -1 + ) { state.list = [ { name: "证书中心", }, ]; } - if (n === "/systemmanage" || n === "/SystemManage") { + if ( + n.indexOf("/systemmanage") !== -1 || + n.indexOf("/SystemManage") !== -1 + ) { state.list = [ { name: "系统管理", diff --git a/src/components/drawers/AddHomework.vue b/src/components/drawers/AddHomework.vue index e5f6f5fc..9247ee49 100644 --- a/src/components/drawers/AddHomework.vue +++ b/src/components/drawers/AddHomework.vue @@ -3,13 +3,12 @@ :visible="addhomeworkVisible" class="drawerStyle addhomeworkDrawer" width="80%" - title="添加作业" placement="right" @after-visible-change="afterVisibleChange" >