mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-09 19:06:43 +08:00
Merge remote-tracking branch 'zshyx/250207-growth-prod-master_1202-zp' into dev0515
# Conflicts: # src/components/UserCenter/menu.vue
This commit is contained in:
16369
package-lock.json
generated
16369
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
6
src/api/growth/growthpath.js
Normal file
6
src/api/growth/growthpath.js
Normal file
@@ -0,0 +1,6 @@
|
||||
// import ajax from '@/utils/xajax.js'
|
||||
import ajax from '../ajax';
|
||||
// const baseURL = '';
|
||||
const baseURL = '/growth';
|
||||
// 查询专业力必修列表
|
||||
export const listData = (obj) => ajax.get(baseURL, '/professional/student/studentGrowthList', { params: obj })
|
||||
BIN
src/assets/images/jindu.jpg
Normal file
BIN
src/assets/images/jindu.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.9 KiB |
BIN
src/assets/images/myGrowth.jpg
Normal file
BIN
src/assets/images/myGrowth.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
BIN
src/assets/images/shuoming.jpg
Normal file
BIN
src/assets/images/shuoming.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.9 KiB |
@@ -9,13 +9,12 @@
|
||||
> -->
|
||||
<!-- <i class="el-icon-collection-tag"></i> 我的导航 -->
|
||||
<!-- </div> -->
|
||||
<!-- :default-openeds="['manageTodo','manageFinish','teacherTodo','teacherFinish','lecturer','myqa','notice','mystudy', 'course', 'exam', 'u001', 'u002', 'u003', 'u004','mylecnotes','mycaseRecord']" -->
|
||||
<div class="uc-menu" style="background-color: #ffffff;padding-bottom:20px">
|
||||
<el-menu
|
||||
:default-active="activeMenu"
|
||||
router
|
||||
active-text-color="#3379FB"
|
||||
:default-openeds="openedsList"
|
||||
:default-openeds="['manageTodo','manageFinish','teacherTodo','teacherFinish','lecturer','myqa','notice','mystudy','myGrowth', 'course', 'exam', 'u001', 'u002', 'u003', 'u004','mylecnotes','mycaseRecord']"
|
||||
class="el-menu-vertical"
|
||||
@open="handleOpen"
|
||||
@close="handleClose"
|
||||
@@ -174,7 +173,7 @@
|
||||
<template slot="title">
|
||||
<svg-icon icon-class="course" style="font-size:16px"></svg-icon>
|
||||
<!-- <i class="el-icon-s-grid"></i> -->
|
||||
<span>专业贡献</span>
|
||||
<span>我的课程</span>
|
||||
</template>
|
||||
<el-menu-item index="/need/course">
|
||||
<!-- <i class="el-icon-menu"></i> -->
|
||||
@@ -243,30 +242,38 @@
|
||||
<svg-icon :icon-class="activeMenu == '/user/medal'?'myxunzhang-active':'myxunzhang'"></svg-icon>
|
||||
<span slot="title">我的勋章</span>
|
||||
</el-menu-item>
|
||||
<!-- <el-submenu index="mystudy" v-show="curIdentity == 1">
|
||||
<template slot="title"> -->
|
||||
<el-submenu index="myGrowth" v-show="curIdentity == 1">
|
||||
<template slot="title">
|
||||
<!-- <i class="el-icon-s-grid"></i> -->
|
||||
<!-- <svg-icon icon-class="mystudy"></svg-icon>
|
||||
<span>我的学习</span>
|
||||
</template> -->
|
||||
<!-- <el-menu-item index="/uc/study/task"> -->
|
||||
<img src="../../assets/images/myGrowth.jpg" style="width: 1em;height: 1em;margin-right: 8px;"></img>
|
||||
<span>我的必修</span>
|
||||
</template>
|
||||
<el-menu-item index="/growth/growthPage">
|
||||
<!-- <i class="el-icon-menu"></i> -->
|
||||
<!-- <span slot="title" class="study textl"><el-badge :value="studyTaskCount||''" class="item">学习任务</el-badge></span>
|
||||
</el-menu-item> -->
|
||||
<!-- <el-menu-item index="/uc/study/courses"> -->
|
||||
<span slot="title" class="study textl">专业力必修</span>
|
||||
</el-menu-item>
|
||||
</el-submenu>
|
||||
<el-submenu index="mystudy" v-show="curIdentity == 1">
|
||||
<template slot="title">
|
||||
<!-- <i class="el-icon-s-grid"></i> -->
|
||||
<svg-icon icon-class="mystudy"></svg-icon>
|
||||
<span>我的学习</span>
|
||||
</template>
|
||||
<el-menu-item index="/uc/study/task">
|
||||
<!-- <i class="el-icon-menu"></i> -->
|
||||
<span slot="title" class="study textl"><el-badge :value="studyTaskCount||''" class="item">学习任务</el-badge></span>
|
||||
</el-menu-item>
|
||||
<el-menu-item index="/uc/study/courses">
|
||||
<!-- <i class="el-icon-menu"></i> -->
|
||||
<!-- <span slot="title" class="textl">自主学习</span> -->
|
||||
<!-- <span slot="title" class="textl">我报名的</span>
|
||||
</el-menu-item> -->
|
||||
<!-- <el-menu-item index="/exam/mytask">
|
||||
<i class="el-icon-menu"></i>
|
||||
<span slot="title" class="textl">我报名的</span>
|
||||
</el-menu-item>
|
||||
<el-menu-item index="/exam/mytask">
|
||||
<!-- <i class="el-icon-menu"></i> -->
|
||||
<span slot="title" class="textl">我的考试</span>
|
||||
</el-menu-item> -->
|
||||
<!-- <el-menu-item index="/uc/study/growth">
|
||||
<span slot="title" class="textl">成长路径</span>
|
||||
</el-menu-item> -->
|
||||
<!-- 去掉
|
||||
<el-menu-item index="/uc/study/path" v-show="isTest">
|
||||
</el-menu-item>
|
||||
<!---去掉->
|
||||
<!-- <el-menu-item index="/uc/study/path" v-show="isTest">
|
||||
<span slot="title" class="textl">学习路径图</span>
|
||||
</el-menu-item>
|
||||
<el-menu-item index="/uc/study/project" v-show="isTest">
|
||||
@@ -276,47 +283,7 @@
|
||||
<!-- <i class="el-icon-menu"></i> -->
|
||||
<!-- <span slot="title" class="textl">历史记录</span>
|
||||
</el-menu-item> -->
|
||||
<!-- </el-submenu> -->
|
||||
<el-submenu v-if="fistTotals+pathTotals+growTotal" index="mystudy" v-show="curIdentity == 1">
|
||||
<template slot="title">
|
||||
<!-- <svg-icon icon-class="mystudy"></svg-icon> -->
|
||||
<i style="margin-right: 8px;width: 19px;color:#303133;" class="el-icon-collection"></i>
|
||||
<span><el-badge :value="fistTotal + pathTotal||''" class="item">我的必修</el-badge></span>
|
||||
</template>
|
||||
<el-menu-item v-if="fistTotals" index="/uc/study/task?type=1">
|
||||
<span slot="title" class="study textl"><el-badge :value="fistTotal||''" class="item">领导力必修</el-badge></span>
|
||||
</el-menu-item>
|
||||
<el-menu-item v-if="growTotal" index="/uc/study/growth">
|
||||
<span slot="title" class="textl">专业力必修</span>
|
||||
</el-menu-item>
|
||||
<el-menu-item v-if="pathTotals" index="/uc/study/task?type=2">
|
||||
<span slot="title" class="textl"><el-badge :value="pathTotal||''" class="item">定制化学习</el-badge></span>
|
||||
</el-menu-item>
|
||||
</el-submenu>
|
||||
<el-menu-item v-else index="/uc/study/task?type=9" v-show="curIdentity == 1">
|
||||
<!-- <svg-icon :icon-class="activeMenu == '/uc/study/task'?'mystudy':'mystudy'"></svg-icon> -->
|
||||
<i style="margin-right: 8px;width: 19px;" :style="{color:activeMenu == '/uc/study/task?type=9'?'rgb(51, 121, 251)':'#303133'}" class="el-icon-collection"></i>
|
||||
<span slot="title">我的必修</span>
|
||||
</el-menu-item>
|
||||
<el-menu-item v-if="courseNum == 0" index="/uc/study/courses" v-show="curIdentity == 1">
|
||||
<!-- <svg-icon :icon-class="activeMenu == '/exam/mytask'?'mybiji-active':'mybiji'"></svg-icon> -->
|
||||
<svg-icon icon-class="mystudy"></svg-icon>
|
||||
<span slot="title">我的选修</span>
|
||||
</el-menu-item>
|
||||
<el-submenu v-else index="myelective" v-show="curIdentity == 1">
|
||||
<template slot="title">
|
||||
<svg-icon icon-class="mystudy"></svg-icon>
|
||||
<span>我的选修</span>
|
||||
</template>
|
||||
<el-menu-item index="/uc/study/courses">
|
||||
<span slot="title" class="study textl">自选学习</span>
|
||||
</el-menu-item>
|
||||
</el-submenu>
|
||||
<el-menu-item index="/exam/mytask" v-show="curIdentity == 1">
|
||||
<!-- <svg-icon :icon-class="activeMenu == '/exam/mytask'?'mybiji-active':'mybiji'"></svg-icon> -->
|
||||
<i style="margin-right: 8px;width: 19px;" :style="{color:activeMenu == '/exam/mytask'?'rgb(51, 121, 251)':'#303133'}" class="el-icon-reading"></i>
|
||||
<span slot="title">我的考试</span>
|
||||
</el-menu-item>
|
||||
<el-menu-item index="/user/Mynotes" v-show="curIdentity == 1">
|
||||
<svg-icon :icon-class="activeMenu == '/user/Mynotes'?'mybiji-active':'mybiji'"></svg-icon>
|
||||
<span slot="title">我的笔记</span>
|
||||
@@ -426,12 +393,10 @@
|
||||
|
||||
<script>
|
||||
import { mapGetters } from 'vuex';
|
||||
import apiCourseStudy from '@/api/modules/courseStudy.js'
|
||||
import apicourseStudy from "../../api/modules/courseStudy.js"
|
||||
import {pageList} from "@/api/modules/lecturer"
|
||||
import courseImage from "@/components/Course/courseImage.vue"
|
||||
import testUser from '@/utils/testUsers.js'
|
||||
import apiManage from '@/api/manage/manage.js'
|
||||
import {getList} from '@/api/growth'
|
||||
export default {
|
||||
name: 'UcMenu',
|
||||
components: {
|
||||
@@ -442,25 +407,6 @@ export default {
|
||||
activeMenu() {
|
||||
const route = this.$route;
|
||||
const { meta, path } = route;
|
||||
console.log(path,meta,'path')
|
||||
console.log(this.fistTotals,this.growTotal,this.pathTotals,'geshu')
|
||||
if(path == '/uc/study/task' || path == '/uc/study/growth'){
|
||||
this.openedsList = ['mystudy']
|
||||
// window.location.href = `${this.webBaseUrl}/uc/study/task?type=${this.fistTotals || this.growTotal || this.pathTotals}`
|
||||
}
|
||||
console.log('1')
|
||||
if(path == '/uc/study/courses'){
|
||||
'/uc/study/courses'
|
||||
}
|
||||
if(sessionStorage.getItem('totalNums') == 0&&path == '/uc/study/task'){
|
||||
return '/uc/study/task?type=9'
|
||||
}
|
||||
console.log('2')
|
||||
if(path == '/uc/study/task'){
|
||||
console.log('/uc/study/task?type=' + (route.query.type || (this.fistTotals && 1) || 2),'type')
|
||||
return '/uc/study/task?type=' + (route.query.type || (this.fistTotals && 1) || 2)
|
||||
}
|
||||
console.log('3')
|
||||
if(meta.title == '添加受众' || meta.title == '查看受众'){
|
||||
meta.activeMenu = '/manage/ugroups'
|
||||
}
|
||||
@@ -478,21 +424,10 @@ export default {
|
||||
isCollapse: false,
|
||||
lastStudy:{},
|
||||
overlayShow: false,
|
||||
instructor:0,
|
||||
fistTotal:0,
|
||||
fistTotals:1,
|
||||
proTotal: 0,
|
||||
proTotals: 1,
|
||||
pathTotal:0,
|
||||
pathTotals:1,
|
||||
growTotal: 1,
|
||||
openedsList:[],
|
||||
courseNum: 0,
|
||||
instructor:0
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.learnTotal()
|
||||
this.courseNumsData()
|
||||
this.$store.dispatch('refrashReviewed');
|
||||
this.$store.dispatch('refrashStudyTaskCount');
|
||||
this.getLastStudy();
|
||||
@@ -500,7 +435,6 @@ export default {
|
||||
this.instructorCertification()
|
||||
},
|
||||
mounted() {
|
||||
// this.courseNum = sessionStorage.getItem('courseNums')
|
||||
//console.log(this.userInfo.loginName,'this.userInfo.loginName');
|
||||
let flag=testUser.isTest(this.userInfo.loginName);
|
||||
//console.log(flag,'this.isTest22');
|
||||
@@ -511,77 +445,6 @@ export default {
|
||||
// }
|
||||
},
|
||||
methods: {
|
||||
courseNumsData(){
|
||||
let reqData={
|
||||
courseName:'',
|
||||
courseType:'',
|
||||
status:'',
|
||||
progress:'',
|
||||
pageIndex:1,
|
||||
pageSize:10
|
||||
}
|
||||
if(sessionStorage.getItem('courseNums') === null || sessionStorage.getItem('courseNums') === ''){
|
||||
apiCourseStudy.myStudysFromES(reqData).then(res=>{
|
||||
this.courseNum = res.result.count;
|
||||
sessionStorage.setItem('courseNums',this.courseNum)
|
||||
console.log(this.courseNum,'this.courseNum')
|
||||
})
|
||||
}else{
|
||||
this.courseNum = sessionStorage.getItem('courseNums')
|
||||
console.log(this.courseNum,'this.courseNum')
|
||||
}
|
||||
},
|
||||
learnTotal(){
|
||||
const route = this.$route;
|
||||
const { meta, path } = route;
|
||||
let params = {
|
||||
pageNo: 1,
|
||||
pageSize: 10,
|
||||
cmtask_user_status: "",
|
||||
cmtask_name: ""
|
||||
}
|
||||
const promises = [
|
||||
//领导力
|
||||
apiManage.leadership(params).then(res=>{
|
||||
this.fistTotals =parseInt(res.data.total);
|
||||
}),
|
||||
//项目
|
||||
// apiManage.customized(params).then(res=>{
|
||||
// this.proTotals =parseInt(res.data.total);
|
||||
// })
|
||||
//学习路径
|
||||
apiManage.compulsoryList(params).then(res=>{
|
||||
this.pathTotals =parseInt(res.data.total);
|
||||
}),
|
||||
getList(this.userInfo.aid).then(res=>{
|
||||
if(res.code == 200 && Object.keys(res.data).length){
|
||||
this.growTotal = 1
|
||||
}else{
|
||||
this.growTotal = 0
|
||||
}
|
||||
})
|
||||
]
|
||||
Promise.all(promises).then(() => {
|
||||
sessionStorage.setItem('totalNums', this.fistTotals + this.pathTotals + this.growTotal);
|
||||
if(path == '/uc/study/task' && (route.query.type === undefined|| route.query.type === null)){
|
||||
if(this.fistTotals != 0){
|
||||
this.$router.push('/uc/study/task?type=1')
|
||||
}else if (this.growTotal != 0){
|
||||
this.$router.push('/uc/study/growth')
|
||||
}else if (this.pathTotals != 0){
|
||||
this.$router.push('/uc/study/task?type=2')
|
||||
}else{
|
||||
this.$router.push('/uc/study/task?type=9')
|
||||
}
|
||||
}
|
||||
});
|
||||
apiManage.queryTaskCounts({}).then(res=>{
|
||||
// this.proTotal =parseInt(res.data.count); //学习项目
|
||||
this.fistTotal =parseInt(res.data.count1); // 领导力必修
|
||||
this.pathTotal =parseInt(res.data.count2); // 学习路径
|
||||
// this.growTotal = parseInt(res.data.count3); //成长路径
|
||||
})
|
||||
},
|
||||
//讲师认证条数
|
||||
instructorCertification(){
|
||||
pageList({ teacherNo:this.userInfo.userNo,courseName:'', pageNo: 1, pageSize: 10}).then(res=>{
|
||||
@@ -602,7 +465,7 @@ export default {
|
||||
return '';
|
||||
},
|
||||
getLastStudy() {
|
||||
apiCourseStudy.lastStudy().then(res => {
|
||||
apicourseStudy.lastStudy().then(res => {
|
||||
if (res.status === 200) {
|
||||
this.lastStudy = res.result;
|
||||
if (res.result != '' && res.result.courseId) {
|
||||
@@ -615,7 +478,6 @@ export default {
|
||||
},
|
||||
handleOpen(key, keyPath) {
|
||||
console.log(key, keyPath);
|
||||
this.openedsList = [key]
|
||||
},
|
||||
handleClose(key, keyPath) {
|
||||
console.log(key, keyPath);
|
||||
@@ -634,9 +496,6 @@ export default {
|
||||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .el-badge__content.is-fixed {
|
||||
top: 6px !important;
|
||||
}
|
||||
.couerscard{
|
||||
padding: 0 15px;
|
||||
}
|
||||
|
||||
@@ -83,6 +83,9 @@ export const pages=[
|
||||
{title:'成长路径',path:'growth',component:'study/Growth',hidden:false},
|
||||
{title:'学习项目',path:'project',component:'study/StudyProject',hidden:false}
|
||||
]},
|
||||
{title:'我的必修',path:'/growth',hidden:false,children:[
|
||||
{title:'专业力必修',path:'growthPage',component:'growth/index',hidden:false},
|
||||
]},
|
||||
{title:'个人中心',path:'/uc',hidden:false,children:[
|
||||
{title:'首页',path:'index',component:'StudyIndex',hidden:false}
|
||||
]},
|
||||
|
||||
320
src/views/growth/index.vue
Normal file
320
src/views/growth/index.vue
Normal file
@@ -0,0 +1,320 @@
|
||||
<template>
|
||||
<div class="growth">
|
||||
<header class="header">
|
||||
<div class="f-a-c header-title">
|
||||
<div style="margin-right: 8px">我的专业力必修</div>
|
||||
|
||||
<el-popover
|
||||
placement="top-start"
|
||||
width="400"
|
||||
trigger="hover"
|
||||
content="根据您所在的组织、标准岗位、任职资格等级,已为您匹配专业力必修任务,抓紧时间学习吧~"
|
||||
>
|
||||
<i
|
||||
slot="reference"
|
||||
style="color: #a1a1a1"
|
||||
class="el-icon-question"
|
||||
></i>
|
||||
</el-popover>
|
||||
</div>
|
||||
<template v-if="list.length">
|
||||
<el-dropdown trigger="click">
|
||||
<el-button type="primary">
|
||||
<div class="f-a-c">
|
||||
<div class="select-active">{{ selectData.growthName }}</div>
|
||||
<i class="el-icon-arrow-down el-icon--right"></i>
|
||||
</div>
|
||||
</el-button>
|
||||
<el-dropdown-menu slot="dropdown">
|
||||
<el-dropdown-item
|
||||
v-for="item of list"
|
||||
:disabled="item.id === selectData.id"
|
||||
>
|
||||
<div @click="select(item)">
|
||||
{{ item.growthName }}
|
||||
</div></el-dropdown-item
|
||||
>
|
||||
</el-dropdown-menu>
|
||||
</el-dropdown>
|
||||
</template>
|
||||
</header>
|
||||
|
||||
<section class="container">
|
||||
<template v-if="list.length">
|
||||
<div class="title">{{ selectData.growthName }}</div>
|
||||
<div class="content">
|
||||
<div class="tip">
|
||||
<div class="tip-title f-a-c">
|
||||
<img class="icon" src="../../assets/images/shuoming.jpg" />
|
||||
<div>说明</div>
|
||||
</div>
|
||||
<div class="tip-text">
|
||||
{{ selectData.description || "暂无说明" }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="progress">
|
||||
<div class="progress-title f-a-c">
|
||||
<img class="icon" src="../../assets/images/jindu.jpg" />
|
||||
<div>学习进度</div>
|
||||
</div>
|
||||
<div class="progress-text">
|
||||
<div class="progress-item">
|
||||
<div class="item-title">总任务</div>
|
||||
<div class="item-progress">{{ selectData.totalTaskNum }}个</div>
|
||||
</div>
|
||||
<div class="progress-item">
|
||||
<div class="item-title">必修进度</div>
|
||||
<div class="item-progress">
|
||||
<el-progress
|
||||
:stroke-width="12"
|
||||
:text-inside="true"
|
||||
:percentage="requiredTaskCompletionRate"
|
||||
></el-progress>
|
||||
<div class="mask">
|
||||
{{ selectData.requiredTaskCompletedNum }}/{{
|
||||
selectData.requiredTaskNum
|
||||
}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="item-text">{{ requiredTaskCompletionRate }}%</div>
|
||||
</div>
|
||||
<div class="progress-item">
|
||||
<div class="item-title">选修进度</div>
|
||||
<div class="item-progress">
|
||||
<el-progress
|
||||
:stroke-width="12"
|
||||
:text-inside="true"
|
||||
:percentage="electiveTaskCompletionRate"
|
||||
></el-progress>
|
||||
<div class="mask">
|
||||
{{ selectData.electiveTaskCompletedNum }}/{{
|
||||
selectData.electiveTaskNum
|
||||
}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="item-text">{{ electiveTaskCompletionRate }}%</div>
|
||||
</div>
|
||||
<div class="progress-item">
|
||||
<div class="item-title">总进度</div>
|
||||
<div class="item-progress">
|
||||
<el-progress
|
||||
:stroke-width="12"
|
||||
:text-inside="true"
|
||||
:percentage="totalTaskCompletionRate"
|
||||
></el-progress>
|
||||
<div class="mask">
|
||||
{{ selectData.totalTaskCompletedNum }}/{{
|
||||
selectData.totalTaskNum
|
||||
}}
|
||||
</div>
|
||||
</div>
|
||||
<div class="item-text">{{ totalTaskCompletionRate }}%</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="learning f-j-c">
|
||||
<el-button style="width: 100px" type="primary" @click="jumpRouter">
|
||||
学习
|
||||
</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<template v-else>
|
||||
<el-empty :image-size="200"></el-empty>
|
||||
</template>
|
||||
</section>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { listData } from "@/api/growth/growthpath";
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
selectData: {},
|
||||
list: [],
|
||||
};
|
||||
},
|
||||
computed: {
|
||||
// 完成进度
|
||||
totalTaskCompletionRate() {
|
||||
if (
|
||||
this.selectData.totalTaskCompletedNum &&
|
||||
this.selectData.totalTaskNum
|
||||
) {
|
||||
let num =
|
||||
this.selectData.totalTaskCompletedNum / this.selectData.totalTaskNum;
|
||||
num = num * 100;
|
||||
num = num.toFixed(0);
|
||||
return Number(num);
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
},
|
||||
// 选修进度
|
||||
electiveTaskCompletionRate() {
|
||||
if (
|
||||
this.selectData.electiveTaskCompletedNum &&
|
||||
this.selectData.electiveTaskNum
|
||||
) {
|
||||
let num =
|
||||
this.selectData.electiveTaskCompletedNum /
|
||||
this.selectData.electiveTaskNum;
|
||||
num = num * 100;
|
||||
num = num.toFixed(0);
|
||||
return Number(num);
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
},
|
||||
// 必修进度
|
||||
requiredTaskCompletionRate() {
|
||||
if (
|
||||
this.selectData.requiredTaskCompletedNum &&
|
||||
this.selectData.requiredTaskNum
|
||||
) {
|
||||
let num =
|
||||
this.selectData.requiredTaskCompletedNum /
|
||||
this.selectData.requiredTaskNum;
|
||||
num = num * 100;
|
||||
num = num.toFixed(0);
|
||||
return Number(num);
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
},
|
||||
},
|
||||
methods: {
|
||||
select(item) {
|
||||
this.selectData = item;
|
||||
},
|
||||
jumpRouter() {
|
||||
//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 (this.selectData.template == 1) {
|
||||
//路径图
|
||||
let params = encodeURIComponent("routerId=" + this.selectData.id);
|
||||
this.$router.push(
|
||||
"/forward?to=" + studentPath + "/growthRoadmap¶ms=" + params
|
||||
);
|
||||
} else if (this.selectData.template == 2) {
|
||||
//任务列表
|
||||
let params = encodeURIComponent("routerId=" + this.selectData.id);
|
||||
this.$router.push(
|
||||
"/forward?to=" + studentPath + "/growthList¶ms=" + params
|
||||
);
|
||||
}
|
||||
},
|
||||
},
|
||||
created() {
|
||||
listData().then((res) => {
|
||||
this.list = res.data;
|
||||
this.selectData = this.list[0];
|
||||
});
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="less" scoped>
|
||||
.f-a-c {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.f-j-c {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
.header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
.header-title {
|
||||
font-size: 24px;
|
||||
}
|
||||
.select-active {
|
||||
font-size: 18px;
|
||||
max-width: 300px;
|
||||
white-space: nowrap; /* 防止文本换行 */
|
||||
overflow: hidden; /* 隐藏溢出的内容 */
|
||||
text-overflow: ellipsis; /* 显示省略符号来代表被修剪的文本 */
|
||||
}
|
||||
}
|
||||
.container {
|
||||
.title {
|
||||
margin-top: 30px;
|
||||
padding: 25px 40px;
|
||||
font-size: 18px;
|
||||
color: rgb(51, 121, 251);
|
||||
border: 1px solid #e2eefd;
|
||||
border-bottom: none;
|
||||
background-image: linear-gradient(to bottom, #e2eefd, #ffffff);
|
||||
}
|
||||
.content {
|
||||
border: 1px solid #e2eefd;
|
||||
padding: 25px 50px;
|
||||
.icon {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.tip-title,
|
||||
.progress-title {
|
||||
font-size: 24px;
|
||||
font-weight: 700;
|
||||
}
|
||||
.tip-text {
|
||||
font-size: 18px;
|
||||
line-height: 35px;
|
||||
margin-top: 20px;
|
||||
}
|
||||
.tip-text,
|
||||
.progress-text {
|
||||
padding-left: 50px;
|
||||
}
|
||||
.progress-text {
|
||||
.el-form-item {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
.progress {
|
||||
margin-top: 40px;
|
||||
}
|
||||
.progress-item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 14px;
|
||||
margin-top: 20px;
|
||||
.item-title {
|
||||
width: 80px;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.item-progress {
|
||||
width: 400px;
|
||||
position: relative;
|
||||
.mask {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
top: 0;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
.item-text {
|
||||
color: #409eff;
|
||||
}
|
||||
::v-deep.el-progress-bar__innerText {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
.learning {
|
||||
padding: 45px 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -85,28 +85,28 @@ module.exports = {
|
||||
.end()
|
||||
config
|
||||
.optimization.splitChunks({
|
||||
chunks: 'all',
|
||||
cacheGroups: {
|
||||
libs: {
|
||||
name: 'chunk-libs',
|
||||
test: /[\\/]node_modules[\\/]/,
|
||||
priority: 10,
|
||||
chunks: 'initial' // only package third parties that are initially dependent
|
||||
},
|
||||
elementUI: {
|
||||
name: 'chunk-elementUI', // split elementUI into a single package
|
||||
priority: 20, // the weight needs to be larger than libs and app or it will be packaged into libs or app
|
||||
test: /[\\/]node_modules[\\/]_?element-ui(.*)/ // in order to adapt to cnpm
|
||||
},
|
||||
commons: {
|
||||
name: 'chunk-commons',
|
||||
test: resolve('src/components'), // can customize your rules
|
||||
minChunks: 3, // minimum common number
|
||||
priority: 5,
|
||||
reuseExistingChunk: true
|
||||
chunks: 'all',
|
||||
cacheGroups: {
|
||||
libs: {
|
||||
name: 'chunk-libs',
|
||||
test: /[\\/]node_modules[\\/]/,
|
||||
priority: 10,
|
||||
chunks: 'initial' // only package third parties that are initially dependent
|
||||
},
|
||||
elementUI: {
|
||||
name: 'chunk-elementUI', // split elementUI into a single package
|
||||
priority: 20, // the weight needs to be larger than libs and app or it will be packaged into libs or app
|
||||
test: /[\\/]node_modules[\\/]_?element-ui(.*)/ // in order to adapt to cnpm
|
||||
},
|
||||
commons: {
|
||||
name: 'chunk-commons',
|
||||
test: resolve('src/components'), // can customize your rules
|
||||
minChunks: 3, // minimum common number
|
||||
priority: 5,
|
||||
reuseExistingChunk: true
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
})
|
||||
config.optimization.runtimeChunk('single'), {
|
||||
from: path.resolve(__dirname, './public/robots.txt'), //防爬虫文件
|
||||
to: './', //到根目录下
|
||||
@@ -124,6 +124,11 @@ module.exports = {
|
||||
// 114.115.162.187 测试环境
|
||||
// 192.168.0.107 晋宇
|
||||
proxy: {
|
||||
"/professional": {
|
||||
// target: 'http://192.168.16.195:32002',
|
||||
target: 'http://192.168.150.97:32002',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/manageApi': {
|
||||
// 目标代理服务器地址
|
||||
target: 'https://u-pre.boe.com',
|
||||
|
||||
Reference in New Issue
Block a user