mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-manage.git
synced 2025-12-09 19:06:45 +08:00
-- fix bug
This commit is contained in:
@@ -80,6 +80,7 @@ export const delStudent = (obj) =>
|
||||
|
||||
// 获取学员路径图进度明细
|
||||
export const stuProgress = (params) => http.get('/admin/router/detail', { params });
|
||||
export const stuRouterProgress = (params) => http.get('/admin/router/stuDetail', { params });
|
||||
// export const stuProgress = (obj) =>http.post("/admin/router/studentProcess", obj);
|
||||
|
||||
//编辑学习路径基本信息
|
||||
|
||||
@@ -27,7 +27,9 @@ export const removeGroupStudent = (obj) => http.post('/admin/project/removeGroup
|
||||
//查看学员
|
||||
// export const studentProcess = (obj) => http.get('/admin/project/studentProcess', { params: obj })
|
||||
export const studentProcess = (obj) => http.get('/admin/project/detail', { params: obj })
|
||||
export const studentRank = (obj) => http.get('/admin/project/studentRank', { params: obj })
|
||||
export const projectStudentProcess = (obj) => http.get('/admin/project/stuDetail', { params: obj })
|
||||
export const projectStudentRank = (obj) => http.get('/admin/project/studentRank', { params: obj })
|
||||
export const routerStudentRank = (obj) => http.get('/admin/router/studentRank', { params: obj })
|
||||
|
||||
//是否优秀学员
|
||||
export const topStudent = (obj) => http.post('/admin/project/topStudent', obj)
|
||||
|
||||
@@ -1,40 +1,41 @@
|
||||
<template>
|
||||
<a-drawer
|
||||
:visible="CheckStuvisible"
|
||||
class="drawerStyle CheckStu"
|
||||
placement="right"
|
||||
width="70%"
|
||||
@after-visible-change="afterVisibleChange"
|
||||
:visible="CheckStuvisible"
|
||||
class="drawerStyle CheckStu"
|
||||
placement="right"
|
||||
width="70%"
|
||||
>
|
||||
<div class="drawerMain">
|
||||
<div class="header">
|
||||
<div class="headerTitle">查看</div>
|
||||
<img
|
||||
style="width: 29px; height: 29px; cursor: pointer"
|
||||
src="../../assets/images/basicinfo/close.png"
|
||||
@click="closeDrawer"
|
||||
style="width: 29px; height: 29px; cursor: pointer"
|
||||
src="../../assets/images/basicinfo/close.png"
|
||||
@click="closeDrawer"
|
||||
/>
|
||||
</div>
|
||||
<a-spin v-if="loading" :spinning="loading"/>
|
||||
<div v-if="!loading" class="main">
|
||||
<div class="stuinfor">
|
||||
<div class="portrait">
|
||||
<img src="../../assets/images/studentimg/character.png" />
|
||||
<img src="../../assets/images/studentimg/character.png"/>
|
||||
</div>
|
||||
<div class="stumation">
|
||||
<div class="stuname">{{pro==null?"":pro.routerInfo.name}}</div>
|
||||
<div class="stugangw">{{pro==null?"":pro.routerInfo.organizationName?pro.routerInfo.organizationName:"" + '-' + pro==null?"":pro.routerInfo.jobName?pro.routerInfo.jobName:""}}</div>
|
||||
<div class="stuname">{{ pro.userInfo?.realName }}</div>
|
||||
<div class="stugangw">
|
||||
{{pro.routerInfo?.departName || '' }} - {{ info.userInfo?.jobName || ''}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="sortbox">
|
||||
<div class="sortname">进度排名</div>
|
||||
<div class="sortnub">
|
||||
<span class="nub1">{{rank.current}}</span>
|
||||
<span class="total">/{{rank.total}}</span>
|
||||
<span class="nub1">{{ rank.current || 0 }}</span>
|
||||
<span class="total">/{{ rank.total || 0 }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<a-divider
|
||||
type="vertical"
|
||||
style="
|
||||
type="vertical"
|
||||
style="
|
||||
height: 49px;
|
||||
margin-left: 34px;
|
||||
background-color: rgba(170, 166, 166, 0.3);
|
||||
@@ -43,13 +44,13 @@
|
||||
<div class="sortbox" style="margin-left: 34px">
|
||||
<div class="sortname">完成必修</div>
|
||||
<div class="sortnub">
|
||||
<span class="nub1">{{pro==null?"":pro.currentReqCnt}}</span>
|
||||
<span class="total">/{{pro==null?"":pro.totalReqCnt}}</span>
|
||||
<span class="nub1">{{ rank.finishCompulsoryNum || 0 }}</span>
|
||||
<span class="total">/{{ rank.totalCompulsoryNum || 0 }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<a-divider
|
||||
type="vertical"
|
||||
style="
|
||||
type="vertical"
|
||||
style="
|
||||
height: 49px;
|
||||
margin-left: 34px;
|
||||
background-color: rgba(170, 166, 166, 0.3);"
|
||||
@@ -57,56 +58,16 @@
|
||||
<div class="sortbox" style="margin-left: 34px">
|
||||
<div class="sortname">已修证书</div>
|
||||
<div class="sortnub">
|
||||
<span class="nub1">{{pro==null?"":pro.routerInfo.certCnt?pro.routerInfo.certCnt:0}}</span>
|
||||
<span class="nub1">{{ rank.certNum || 0 }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="secondrow">
|
||||
<div class="rowleft">{{ pro.name }}</div> -->
|
||||
<!-- <div class="rowbox" @click="showProMess">
|
||||
<div class="shuom">说明</div>
|
||||
<div><img src="../../assets/images/studentimg/chak.png" /></div>
|
||||
</div> -->
|
||||
<!-- </div> -->
|
||||
<!-- <div v-for="(item) in pro.chapterList" class="mainbox"
|
||||
style="margin-top: 15px; height: 56px"
|
||||
:key="item.chapterId">
|
||||
<div class="rowtitle" @click="changeDown">
|
||||
<div class="titleimg">
|
||||
<img
|
||||
:src="
|
||||
showDown
|
||||
? require('../../assets/images/studentimg/open.png')
|
||||
: require('../../assets/images/studentimg/close.png')
|
||||
"
|
||||
/>
|
||||
</div>
|
||||
<div class="titletext">{{item.chapterName}}</div>
|
||||
</div>
|
||||
|
||||
<div :style="{ display: showDown ? 'block' : 'none' }">
|
||||
<div v-for="_item in item.taskList" :key="_item.routerTaskId" class="rowclass">
|
||||
<div class="leftclass">
|
||||
<div><img src="../../assets/images/leveladd/zai.png" /></div>
|
||||
<div class="text1">{{checkType(_item.type)}}</div>
|
||||
<div class="text2">{{_item.name}}</div>
|
||||
</div>
|
||||
<div class="alreadyclass">
|
||||
<div class="alimg">
|
||||
<img src="../../assets/images/studentimg/complete.png" />
|
||||
</div>
|
||||
<div class="altext">{{checkStatus(_item.status)}}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div> -->
|
||||
|
||||
<div class="mainbox">
|
||||
<a-collapse v-model:activeKey="stageListActive">
|
||||
<template #expandIcon="{ isActive }">
|
||||
<img
|
||||
style="margin-right: 20px"
|
||||
:src="
|
||||
style="margin-right: 20px"
|
||||
:src="
|
||||
isActive
|
||||
? require('../../assets/images/studentimg/open.png')
|
||||
: require('../../assets/images/studentimg/close.png')
|
||||
@@ -114,36 +75,29 @@
|
||||
/>
|
||||
<div></div>
|
||||
</template>
|
||||
<a-collapse-panel
|
||||
v-for="value in pro==null?[]:pro.chapterList"
|
||||
:key="value.chapterId"
|
||||
:header="value.chapterName"
|
||||
|
||||
>
|
||||
<template #extra >
|
||||
<div @click.stop="">
|
||||
<div class="rowbox">
|
||||
<a-popover title="关卡说明">
|
||||
<template #content>
|
||||
<p>{{value.remark}}</p>
|
||||
</template>
|
||||
<div class="shuom">说明</div>
|
||||
</a-popover>
|
||||
<div><img src="../../assets/images/studentimg/chak.png" /></div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<div
|
||||
class="rowclass"
|
||||
v-for="(item, key) in value.taskList"
|
||||
:key="key"
|
||||
<a-collapse-panel v-for="value in pro.chapterList || []" :key="value.id" :header="value.name">
|
||||
<template #extra>
|
||||
<div @click.stop="">
|
||||
<div class="rowbox">
|
||||
<a-popover title="关卡说明">
|
||||
<template #content>
|
||||
<p>{{ value.remark }}</p>
|
||||
</template>
|
||||
<div class="shuom">说明</div>
|
||||
</a-popover>
|
||||
<div><img src="../../assets/images/studentimg/chak.png"/></div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<div
|
||||
class="rowclass"
|
||||
v-for="(item, key) in value.taskList"
|
||||
:key="key"
|
||||
>
|
||||
|
||||
<div class="leftclass">
|
||||
<div>
|
||||
<img
|
||||
:src="
|
||||
:src="
|
||||
item.type === 1
|
||||
? require('../../assets/images/leveladd/zai.png')
|
||||
: item.type === 2
|
||||
@@ -180,16 +134,16 @@
|
||||
<div class="alreadyclass">
|
||||
<div class="alimg">
|
||||
<img
|
||||
:src="
|
||||
:src="
|
||||
item.status === 1
|
||||
? require('../../assets/images/studentimg/complete.png')
|
||||
: require('../../assets/images/studentimg/notice.png')
|
||||
"
|
||||
/>
|
||||
</div>
|
||||
<div class="altext">{{ item.status ==0?"进行中":item.status ==1?"已完成":"未开始" }}</div>
|
||||
<div class="altext">{{ item.status === 0 ? "进行中" : item.status === 1 ? "已完成" : "未开始" }}</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</a-collapse-panel>
|
||||
</a-collapse>
|
||||
@@ -201,18 +155,16 @@
|
||||
</div>
|
||||
</div>
|
||||
</a-drawer>
|
||||
<check-stu-mess v-model:StuMessvisible="StuMessvisible" />
|
||||
<check-stu-mess v-model:StuMessvisible="StuMessvisible"/>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { reactive, toRefs } from "vue";
|
||||
import CheckStuMess from "./CheckStuMess.vue";
|
||||
import {stuProgress} from "@/api/index1";
|
||||
import {studentRank} from "@/api/indexProjStu";
|
||||
// import {message} from "ant-design-vue";
|
||||
import {reactive, toRefs, watch} from "vue";
|
||||
import {stuRouterProgress} from "@/api/index1";
|
||||
import {routerStudentRank} from "@/api/indexProjStu";
|
||||
|
||||
export default {
|
||||
name: "CheckStu",
|
||||
components: { CheckStuMess },
|
||||
props: {
|
||||
CheckStuvisible: {
|
||||
type: Boolean,
|
||||
@@ -231,58 +183,43 @@ export default {
|
||||
const state = reactive({
|
||||
StuMessvisible: false,
|
||||
showDown: false,
|
||||
pro:null,
|
||||
loading:true,
|
||||
pro: null,
|
||||
loading: false,
|
||||
stageListActive: 0,
|
||||
rank:{total:1,current:1},
|
||||
rank: {total: 0, current: 0, finishCompulsoryNum: 0, totalCompulsoryNum: 0, certNum: 0},
|
||||
});
|
||||
|
||||
watch([()=>props.studentId, ()=>props.routerId], () => {
|
||||
console.log(111111)
|
||||
console.log(props)
|
||||
getStuProgress()
|
||||
getStuRank()
|
||||
})
|
||||
|
||||
const closeDrawer = () => {
|
||||
ctx.emit("update:CheckStuvisible", false);
|
||||
};
|
||||
|
||||
const getStuRank = () => {
|
||||
studentRank({
|
||||
projectId: props.routerId,
|
||||
studentId: props.studentId,
|
||||
type:2
|
||||
}).then(res=>{
|
||||
state.rank = res.data.data
|
||||
})
|
||||
routerStudentRank({routerId: props.routerId, studentId: props.studentId}).then(res => state.rank = res.data.data)
|
||||
}
|
||||
|
||||
const showProMess = () => {
|
||||
state.StuMessvisible = true;
|
||||
};
|
||||
const afterVisibleChange = (bool) => {
|
||||
if(props.CheckStuvisible) {
|
||||
getStuProgress()
|
||||
getStuRank()
|
||||
}
|
||||
console.log("state", bool);
|
||||
};
|
||||
const changeDown = () => {
|
||||
state.showDown = !state.showDown;
|
||||
};
|
||||
const getStuProgress = () => {
|
||||
state.loading = true
|
||||
let obj = {
|
||||
routerId:props.routerId==null?props.studentId:props.routerId
|
||||
// routerId:props.studentId
|
||||
}
|
||||
stuProgress(obj).then(res => {
|
||||
console.log("查询当前学员进度信息success",res)
|
||||
stuRouterProgress({routerId: props.routerId, userId: props.studentId}).then(res => {
|
||||
state.pro = res.data.data
|
||||
state.loading = false
|
||||
console.log(res)
|
||||
}).catch(err => {
|
||||
console.log("查询当前学员进度信息err",err)
|
||||
state.loading = false
|
||||
console.log(err)
|
||||
})
|
||||
}
|
||||
|
||||
const checkType = (type) => {
|
||||
let typeRules = [
|
||||
const checkType = (type) => {
|
||||
let typeRules = [
|
||||
"",
|
||||
"在线",
|
||||
"面授",
|
||||
@@ -299,49 +236,39 @@ export default {
|
||||
"项目",
|
||||
];
|
||||
return typeRules[type];
|
||||
}
|
||||
|
||||
const checkStatus = (status) => {
|
||||
if(status < 0) return "未开始"
|
||||
let statusRules = [
|
||||
"进行中","已完成"
|
||||
]
|
||||
return statusRules[status]
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return {
|
||||
...toRefs(state),
|
||||
afterVisibleChange,
|
||||
closeDrawer,
|
||||
showProMess,
|
||||
changeDown,
|
||||
checkType,
|
||||
checkStatus,
|
||||
// change,
|
||||
|
||||
};
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" >
|
||||
<style lang="scss">
|
||||
.CheckStu {
|
||||
.ant-drawer-content-wrapper {
|
||||
// max-width: 1000px;
|
||||
.ant-drawer-header {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.ant-drawer-body {
|
||||
padding: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.drawerMain {
|
||||
min-width: 600px;
|
||||
margin: 0px 32px 0px 32px;
|
||||
overflow-x: auto;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
|
||||
.header {
|
||||
height: 73px;
|
||||
border-bottom: 1px solid #e8e8e8;
|
||||
@@ -351,6 +278,7 @@ export default {
|
||||
// background-color: red;
|
||||
margin-bottom: 20px;
|
||||
flex-shrink: 0;
|
||||
|
||||
.headerTitle {
|
||||
font-size: 18px;
|
||||
font-weight: 600;
|
||||
@@ -359,11 +287,13 @@ export default {
|
||||
// margin-left: 24px;
|
||||
}
|
||||
}
|
||||
|
||||
.main {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow-y: auto;
|
||||
padding-bottom: 80px;
|
||||
|
||||
.stuinfor {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -373,35 +303,43 @@ export default {
|
||||
background-image: url("../../assets/images/studentimg/bgimg.png");
|
||||
background-repeat: no-repeat;
|
||||
background-position: right;
|
||||
|
||||
.stumation {
|
||||
margin-left: 24px;
|
||||
|
||||
.stuname {
|
||||
color: #333333;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.stugangw {
|
||||
color: #999999;
|
||||
font-size: 16px;
|
||||
margin-top: 7px;
|
||||
}
|
||||
}
|
||||
|
||||
.sortbox {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
margin-left: 114px;
|
||||
|
||||
.sortname {
|
||||
color: #666660;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.sortnub {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin-top: 7px;
|
||||
|
||||
.nub1 {
|
||||
color: #0060ff;
|
||||
font-size: 22px;
|
||||
}
|
||||
|
||||
.total {
|
||||
color: #999999;
|
||||
font-size: 22px;
|
||||
@@ -409,13 +347,16 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.secondrow {
|
||||
margin-top: 32px;
|
||||
display: flex;
|
||||
|
||||
.rowleft {
|
||||
color: rgba(51, 51, 51, 1);
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
.rowbox {
|
||||
width: 64px;
|
||||
height: 24px;
|
||||
@@ -426,6 +367,7 @@ export default {
|
||||
border: 1px solid rgba(64, 158, 255, 1);
|
||||
background: rgba(64, 158, 255, 0.1);
|
||||
cursor: pointer;
|
||||
|
||||
.shuom {
|
||||
color: rgba(64, 158, 255, 1);
|
||||
font-size: 14px;
|
||||
@@ -434,6 +376,7 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// .mainbox {
|
||||
// // height: 463px;
|
||||
// margin-right: 37px;
|
||||
@@ -511,6 +454,7 @@ export default {
|
||||
background: rgba(64, 158, 255, 0.1);
|
||||
margin-right: 480px;
|
||||
cursor: pointer;
|
||||
|
||||
.shuom {
|
||||
color: rgba(64, 158, 255, 1);
|
||||
font-size: 14px;
|
||||
@@ -518,23 +462,28 @@ export default {
|
||||
margin-right: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.ant-collapse {
|
||||
background-color: #ffffff;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.ant-collapse-content > .ant-collapse-content-box {
|
||||
padding: 0;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.ant-collapse > .ant-collapse-item {
|
||||
border: 1px solid rgba(221, 238, 255, 1);
|
||||
border-radius: 6px;
|
||||
margin-bottom: 15px;
|
||||
border-bottom: 0px;
|
||||
}
|
||||
|
||||
.ant-collapse-content {
|
||||
border-top: 0;
|
||||
}
|
||||
|
||||
.ant-collapse-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
@@ -544,52 +493,60 @@ export default {
|
||||
color: rgba(51, 51, 51, 1);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.rowclass {
|
||||
height: 81px;
|
||||
border-bottom: 1px solid rgba(221, 238, 255, 1);
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
.leftclass {
|
||||
display: flex;
|
||||
margin-left: 25px;
|
||||
align-items: center;
|
||||
|
||||
.text1 {
|
||||
color: #000000;
|
||||
font-size: 14px;
|
||||
font-weight: 500;
|
||||
margin-left: 25px;
|
||||
word-break:keep-all;
|
||||
white-space:nowrap;
|
||||
word-break: keep-all;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.text2 {
|
||||
color: rgba(51, 51, 51, 0.8);
|
||||
font-size: 14px;
|
||||
margin-left: 65px;
|
||||
word-break:keep-all;
|
||||
white-space:nowrap;
|
||||
overflow:hidden;
|
||||
text-overflow:ellipsis;
|
||||
word-break: keep-all;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
}
|
||||
|
||||
.alreadyclass {
|
||||
display: flex;
|
||||
margin-right: 57px;
|
||||
|
||||
.alimg {
|
||||
height: 16px;
|
||||
width: 16px;
|
||||
}
|
||||
|
||||
.altext {
|
||||
color: rgba(56, 125, 247, 1);
|
||||
font-size: 14px;
|
||||
margin-left: 16px;
|
||||
word-break:keep-all;
|
||||
white-space:nowrap;
|
||||
word-break: keep-all;
|
||||
white-space: nowrap;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.btnn {
|
||||
height: 72px;
|
||||
width: 100%;
|
||||
@@ -601,6 +558,7 @@ export default {
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
box-shadow: 0px 1px 35px 0px rgba(118, 136, 166, 0.16);
|
||||
|
||||
.btn2 {
|
||||
cursor: pointer;
|
||||
width: 100px;
|
||||
|
||||
@@ -1,58 +1,56 @@
|
||||
<!-- eslint-disable vue/no-use-v-if-with-v-for -->
|
||||
<template>
|
||||
<a-drawer :visible="Seevisible" class="drawerStyle seestu" placement="right" width="70%"
|
||||
@after-visible-change="afterVisibleChange">
|
||||
<a-drawer :visible="Seevisible" class="drawerStyle seestu" placement="right" width="70%">
|
||||
<div class="drawerMain">
|
||||
<div class="header">
|
||||
<div class="headerTitle">查看</div>
|
||||
<img style="width: 29px; height: 29px; cursor: pointer" src="../../assets/images/basicinfo/close.png"
|
||||
@click="closeDrawer" />
|
||||
@click="closeDrawer"/>
|
||||
</div>
|
||||
<a-spin v-if="loading" :spinning="loading" />
|
||||
<a-spin v-if="loading" :spinning="loading"/>
|
||||
<div v-if="!loading" class="main">
|
||||
<div class="stuinfor">
|
||||
<div class="portrait">
|
||||
<img src="../../assets/images/studentimg/character.png" />
|
||||
<img src="../../assets/images/studentimg/character.png"/>
|
||||
</div>
|
||||
<div class="stumation">
|
||||
<div class="stuname">{{ userName }}</div>
|
||||
<div class="stugangw">{{ deptName }} - {{ jobName }}</div>
|
||||
<div class="stuname">{{ info.userInfo.realName }}</div>
|
||||
<div class="stugangw">{{ info.userInfo.departName }} - {{ info.userInfo.jobName }}</div>
|
||||
</div>
|
||||
<div class="sortbox">
|
||||
<div class="sortname">进度排名</div>
|
||||
<div class="sortnub">
|
||||
<span class="nub1">{{ rank.current }}</span>
|
||||
<span class="total">/{{ rank.total }}</span>
|
||||
<span class="nub1">{{ rank.current || 0 }}</span>
|
||||
<span class="total">/{{ rank.total || 0 }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<a-divider type="vertical" style="
|
||||
height: 49px;
|
||||
margin-left: 34px;
|
||||
background-color: rgba(170, 166, 166, 0.3);
|
||||
" />
|
||||
"/>
|
||||
<div class="sortbox" style="margin-left: 34px">
|
||||
<div class="sortname">完成必修</div>
|
||||
<div class="sortnub">
|
||||
<span class="nub1">{{ currentReqCnt }}</span>
|
||||
<span class="total">/{{ totalReqCnt }}</span>
|
||||
<span class="nub1">{{ rank.finishCompulsoryNum || 0 }}</span>
|
||||
<span class="total">/{{ rank.totalCompulsoryNum || 0 }}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<a-divider type="vertical" style="
|
||||
height: 49px;
|
||||
margin-left: 34px;
|
||||
background-color: rgba(170, 166, 166, 0.3);" />
|
||||
background-color: rgba(170, 166, 166, 0.3);"/>
|
||||
<div class="sortbox" style="margin-left: 34px">
|
||||
<div class="sortname">已修证书</div>
|
||||
<div class="sortnub">
|
||||
<span class="nub1">{{ 0 }}</span>
|
||||
<span class="nub1">{{ rank.certNum || 0 }}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<div class="secondrow">
|
||||
<div class="rowleft">{{ name }} </div>
|
||||
<div class="rowRight"> 排序号:{{ sort }}</div>
|
||||
<div class="rowleft">{{ info.projectInfo.name }}</div>
|
||||
</div>
|
||||
<div class="mainbox">
|
||||
<a-collapse v-model:activeKey="stageListActive">
|
||||
@@ -61,10 +59,10 @@
|
||||
isActive
|
||||
? require('../../assets/images/studentimg/open.png')
|
||||
: require('../../assets/images/studentimg/close.png')
|
||||
" />
|
||||
"/>
|
||||
<div></div>
|
||||
</template>
|
||||
<a-collapse-panel v-for="value in stageList" :key="value.stageId" :header="value.stageName">
|
||||
<a-collapse-panel v-for="value in info.stageList" :key="value.id" :header="value.name || '无阶段任务'">
|
||||
<template #extra>
|
||||
<div @click.stop="">
|
||||
<div class="rowbox">
|
||||
@@ -74,7 +72,7 @@
|
||||
</template>
|
||||
<div class="shuom">说明</div>
|
||||
</a-popover>
|
||||
<div><img src="../../assets/images/studentimg/chak.png" /></div>
|
||||
<div><img src="../../assets/images/studentimg/chak.png"/></div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -83,37 +81,36 @@
|
||||
|
||||
<div class="leftclass">
|
||||
<div>
|
||||
<img :src="
|
||||
item.course === '在线'
|
||||
? require('../../assets/images/leveladd/zai.png')
|
||||
: item.course === '面授'
|
||||
<img
|
||||
:src="
|
||||
item.type === 1
|
||||
? require('../../assets/images/leveladd/zai.png')
|
||||
: item.type === 2
|
||||
? require('../../assets/images/leveladd/mian.png')
|
||||
: item.course === '案例'
|
||||
? require('../../assets/images/leveladd/an.png')
|
||||
: item.course === '作业'
|
||||
? require('../../assets/images/leveladd/zuo.png')
|
||||
: item.course === '考试'
|
||||
? require('../../assets/images/leveladd/kao.png')
|
||||
: item.course === '直播'
|
||||
? require('../../assets/images/leveladd/zhi.png')
|
||||
: item.course === '外链'
|
||||
? require('../../assets/images/leveladd/wai.png')
|
||||
: item.course === '讨论'
|
||||
? require('../../assets/images/leveladd/tao.png')
|
||||
: item.course === '活动'
|
||||
? require('../../assets/images/leveladd/huo.png')
|
||||
: item.course === '测评'
|
||||
? require('../../assets/images/leveladd/ce.png')
|
||||
: item.course === '调研'
|
||||
? require('../../assets/images/leveladd/diao.png')
|
||||
: item.course === '投票'
|
||||
? require('../../assets/images/leveladd/tou.png')
|
||||
: item.course === '评估'
|
||||
? require('../../assets/images/leveladd/diao.png')
|
||||
: item.course === '项目'
|
||||
? require('../../assets/images/leveladd/xiangmu.png')
|
||||
: null
|
||||
" />
|
||||
: item.type === 3
|
||||
? require('../../assets/images/leveladd/an.png')
|
||||
: item.type === 4
|
||||
? require('../../assets/images/leveladd/zuo.png')
|
||||
: item.type === 5
|
||||
? require('../../assets/images/leveladd/kao.png')
|
||||
: item.type === 6
|
||||
? require('../../assets/images/leveladd/zhi.png')
|
||||
: item.type === 7
|
||||
? require('../../assets/images/leveladd/wai.png')
|
||||
: item.type === 8
|
||||
? require('../../assets/images/leveladd/tao.png')
|
||||
: item.type === 9
|
||||
? require('../../assets/images/leveladd/huo.png')
|
||||
: item.type === 10
|
||||
? require('../../assets/images/leveladd/ce.png')
|
||||
: item.type === 11
|
||||
? require('../../assets/images/leveladd/diao.png')
|
||||
: item.type === 12
|
||||
? require('../../assets/images/leveladd/tou.png')
|
||||
: item.type === 13
|
||||
? require('../../assets/images/leveladd/xiangmu.png')
|
||||
: null"
|
||||
/>
|
||||
</div>
|
||||
<div class="text1">{{ item.course }}</div>
|
||||
<div class="text2">{{ item.name }}</div>
|
||||
@@ -124,11 +121,10 @@
|
||||
item.complete === '已完成'
|
||||
? require('../../assets/images/studentimg/complete.png')
|
||||
: require('../../assets/images/studentimg/notice.png')
|
||||
" />
|
||||
"/>
|
||||
</div>
|
||||
<div class="altext">{{ item.complete }}</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</a-collapse-panel>
|
||||
</a-collapse>
|
||||
@@ -138,17 +134,18 @@
|
||||
<button class="btn2" @click="closeDrawer">关闭</button>
|
||||
</div>
|
||||
</div>
|
||||
<pro-mess v-model:Provisible="Provisible" />
|
||||
<pro-mess v-model:Provisible="Provisible"/>
|
||||
</a-drawer>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { reactive, toRefs } from "vue";
|
||||
import {reactive, toRefs, watch} from "vue";
|
||||
import ProMess from "./ProMess.vue";
|
||||
import { studentProcess, studentRank } from "../../api/indexProjStu";
|
||||
import {projectStudentRank, projectStudentProcess} from "@/api/indexProjStu";
|
||||
|
||||
export default {
|
||||
name: "SeeStu",
|
||||
components: { ProMess },
|
||||
components: {ProMess},
|
||||
props: {
|
||||
Seevisible: {
|
||||
type: Boolean,
|
||||
@@ -166,213 +163,40 @@ export default {
|
||||
setup(props, ctx) {
|
||||
const state = reactive({
|
||||
loading: false,
|
||||
userName: null, //用户名
|
||||
deptName: null, //部门
|
||||
jobName: null, //岗位
|
||||
certCnt: null, //已修证书
|
||||
name: null, //路径图名称
|
||||
totalReqCnt: null, //累计必修数
|
||||
currentReqCnt: null, //完成必修数
|
||||
info: {},
|
||||
Provisible: false,
|
||||
showDown: true,
|
||||
showDown1: false,
|
||||
rank: { total: 1, current: 1 },
|
||||
sort: null,
|
||||
stageList: [
|
||||
// {
|
||||
// stageName: "阶段1腾飞班阶段1",
|
||||
// stageId: 1,
|
||||
// taskList: [
|
||||
// {
|
||||
// course: "在线",
|
||||
// name: "如何成为一个产品经理",
|
||||
// complete: "已完成",
|
||||
// },
|
||||
// {
|
||||
// course: "直播",
|
||||
// name: "管理直播课",
|
||||
// complete: "已完成",
|
||||
// },
|
||||
// {
|
||||
// course: "面授",
|
||||
// name: "管理面授课",
|
||||
// complete: "未完成",
|
||||
// },
|
||||
// {
|
||||
// course: "活动",
|
||||
// name: "管理活动",
|
||||
// complete: "未完成",
|
||||
// },
|
||||
// {
|
||||
// course: "作业",
|
||||
// name: "管理者作业",
|
||||
// complete: "未完成",
|
||||
// },
|
||||
// ],
|
||||
// },
|
||||
],
|
||||
stageListActive: 0,
|
||||
rank: {total: 0, current: 0, finishCompulsoryNum: 0, totalCompulsoryNum: 0, certNum: 0},
|
||||
});
|
||||
|
||||
watch([() => props.checkStuId, () => props.projectId], () => {
|
||||
getStuRank()
|
||||
check()
|
||||
})
|
||||
|
||||
|
||||
const closeDrawer = () => {
|
||||
ctx.emit("update:Seevisible", false);
|
||||
};
|
||||
|
||||
const getStuRank = () => {
|
||||
studentRank({
|
||||
projectId: props.projectId,
|
||||
studentId: props.checkStuId,
|
||||
type: 1
|
||||
}).then(res => {
|
||||
state.rank = res.data.data
|
||||
})
|
||||
projectStudentRank({projectId: props.projectId, studentId: props.checkStuId}).then(res => state.rank = res.data.data)
|
||||
}
|
||||
|
||||
const showProMess = () => {
|
||||
state.Provisible = true;
|
||||
};
|
||||
const afterVisibleChange = (bool) => {
|
||||
console.log("state", bool);
|
||||
if (bool == true) {
|
||||
check();
|
||||
getStuRank()
|
||||
}
|
||||
};
|
||||
const changeDown = () => {
|
||||
state.showDown = !state.showDown;
|
||||
};
|
||||
const changeDown1 = () => {
|
||||
state.showDown1 = !state.showDown1;
|
||||
};
|
||||
const taskList = (tableData) => {
|
||||
let data = tableData;
|
||||
console.log('我排序了吗--------------------------》', data)
|
||||
let array = [];
|
||||
if (data != undefined) {
|
||||
data.map((value) => {
|
||||
console.log('我排序了吗---------value-----------------》', value)
|
||||
let obj = {
|
||||
course:
|
||||
value.type == 1
|
||||
? "在线"
|
||||
: value.type == 2
|
||||
? "面授"
|
||||
: value.type == 3
|
||||
? "案例"
|
||||
: value.type == 4
|
||||
? "作业"
|
||||
: value.type == 5
|
||||
? "考试"
|
||||
: value.type == 6
|
||||
? "直播"
|
||||
: value.type == 7
|
||||
? "外链"
|
||||
: value.type == 8
|
||||
? "讨论"
|
||||
: value.type == 9
|
||||
? "活动"
|
||||
: value.type == 10
|
||||
? "测评"
|
||||
: value.type == 11
|
||||
? "评估"
|
||||
: value.type == 12
|
||||
? "投票"
|
||||
: "-",
|
||||
name: value.name,
|
||||
projectId: value.projectId,
|
||||
complete:
|
||||
value.status == -1
|
||||
? "未开始"
|
||||
: value.status == 1
|
||||
? "已完成"
|
||||
: value.status == 0
|
||||
? "未完成"
|
||||
: "-",
|
||||
flag: value.flag == 0 ? "选修" : "必修",
|
||||
currentRatio: value.currentRatio,
|
||||
routerTaskId: value.routerTaskId,
|
||||
};
|
||||
console.log('我排序了吗---------obj-----------------》', obj)
|
||||
array.push(obj);
|
||||
});
|
||||
array.sort((a, b) => { return a.projectId - b.projectId })
|
||||
}
|
||||
|
||||
console.log('我排序了吗-----------1---------------》', array)
|
||||
return array;
|
||||
};
|
||||
const setStageList = (tableData) => {
|
||||
let data = tableData;
|
||||
console.log("查看了学员1", data);
|
||||
let array = [];
|
||||
//无阶段任务
|
||||
if (data?.length == 1 && data[0].id == 0) {
|
||||
console.log("无阶段任务", data);
|
||||
data.map((value) => {
|
||||
let obj = {
|
||||
stageName: "无阶段任务",
|
||||
stageId: 0,
|
||||
remark: value.remark,
|
||||
taskList: taskList(value.taskList),
|
||||
};
|
||||
array.push(obj);
|
||||
});
|
||||
} else { //有阶段
|
||||
console.log("有阶段", data);
|
||||
data.map((value) => {
|
||||
console.log("有阶段value", value);
|
||||
let obj = {
|
||||
stageName: value.name,
|
||||
stageId: value.id,
|
||||
remark: value.remark,
|
||||
taskList: taskList(value.taskList),
|
||||
};
|
||||
if (value.id > 0) {
|
||||
array.push(obj);
|
||||
}
|
||||
console.log("有阶段array", array);
|
||||
});
|
||||
}
|
||||
|
||||
state.stageList = array;
|
||||
};
|
||||
const check = () => {
|
||||
state.loading = true
|
||||
let obj = {
|
||||
projectId: props.projectId,
|
||||
studentId: props.checkStuId,
|
||||
};
|
||||
studentProcess(obj).then((res) => {
|
||||
projectStudentProcess({projectId: props.projectId, userId: props.checkStuId}).then((res) => {
|
||||
state.loading = false
|
||||
console.log("查看了学员", res.data);
|
||||
let result = res.data.data;
|
||||
console.log("查看了学员result:", result);
|
||||
state.userName = result.projectInfo.name;
|
||||
state.deptName = result.projectInfo.deptName;
|
||||
state.jobName = result.projectInfo.jobName;
|
||||
state.certCnt = result.projectInfo.certCnt == null ? 0 : result.projectInfo.certCnt;
|
||||
state.name = result.projectInfo.name;
|
||||
state.currentReqCnt = result.projectInfo.currentReqCnt;
|
||||
state.totalReqCnt = result.projectInfo.totalReqCnt;
|
||||
|
||||
if (result.stageList.length > 0) {
|
||||
state.sort = result.stageList[0].sort;
|
||||
|
||||
}
|
||||
setStageList(result.stageList);
|
||||
});
|
||||
};
|
||||
state.info = res.data.data;
|
||||
})
|
||||
}
|
||||
|
||||
return {
|
||||
...toRefs(state),
|
||||
afterVisibleChange,
|
||||
closeDrawer,
|
||||
showProMess,
|
||||
changeDown,
|
||||
changeDown1,
|
||||
check,
|
||||
setStageList,
|
||||
taskList,
|
||||
// change,
|
||||
};
|
||||
},
|
||||
};
|
||||
@@ -521,12 +345,12 @@ export default {
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.ant-collapse-content>.ant-collapse-content-box {
|
||||
.ant-collapse-content > .ant-collapse-content-box {
|
||||
padding: 0;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.ant-collapse>.ant-collapse-item {
|
||||
.ant-collapse > .ant-collapse-item {
|
||||
border: 1px solid rgba(221, 238, 255, 1);
|
||||
border-radius: 6px;
|
||||
margin-bottom: 15px;
|
||||
|
||||
Reference in New Issue
Block a user