yujialong 2 years ago
parent 4f8d4f5136
commit dbf89c8a9b
  1. 49
      public/index.html
  2. 2
      src/api/index.js
  3. 498
      src/pages/course/list/index.vue
  4. 8
      src/pages/index/list/index.vue
  5. 35
      src/pages/match/details/index.vue
  6. 4
      src/setting.js

@ -1,22 +1,33 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="keywords" content="职站,教学,教育,在线编程">
<meta name="description" content="职站是一款辅助院校教师开展虚拟仿真实验教学的智能云实践平台。平台采用了大数据,云计算等技术,为学校搭建信息化平台提供了基础,可助力院校实现教学智能化升级。职站平台设计遵循着极简、高效的理念,可帮助老师轻松开展实验教学,并支持自定义发布考核和练习,智能统计和检验学生的日常实训练习效果;老师还可以通过可视化图表报告直观查看学生实训成绩,评估教学成果。"/>
<meta name="baidu-site-verification" content="code-TRfXe8xIkJ" />
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no">
<link rel="stylesheet" href="//at.alicdn.com/t/font_830376_qzecyukz0s.css">
<title>职站——为院校打造一站式虚拟仿真实训教学数智云平台</title>
</head>
<body>
<noscript>
<strong>We're sorry but vms doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
<script src="/styles/tinymce/tinymce.min.js"></script>
</body>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="keywords" content="职站,教学,教育,在线编程" />
<meta
name="description"
content="职站是一款辅助院校教师开展虚拟仿真实验教学的智能云实践平台。平台采用了大数据,云计算等技术,为学校搭建信息化平台提供了基础,可助力院校实现教学智能化升级。职站平台设计遵循着极简、高效的理念,可帮助老师轻松开展实验教学,并支持自定义发布考核和练习,智能统计和检验学生的日常实训练习效果;老师还可以通过可视化图表报告直观查看学生实训成绩,评估教学成果。"
/>
<meta name="baidu-site-verification" content="code-TRfXe8xIkJ" />
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<link rel="stylesheet" href="//at.alicdn.com/t/font_830376_qzecyukz0s.css" />
<title>职站——为院校打造一站式虚拟仿真实训教学数智云平台</title>
<script>
var _hmt = _hmt || [];
(function () {
var hm = document.createElement('script');
hm.src = 'https://hm.baidu.com/hm.js?72fbad6ebf1d6c705117fe8fe0686a0e';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(hm, s);
})();
</script>
</head>
<body>
<noscript>
<strong>We're sorry but vms doesn't work properly without JavaScript enabled. Please enable it to continue.</strong>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
<script src="/styles/tinymce/tinymce.min.js"></script>
</body>
</html>

@ -215,4 +215,6 @@ export default {
courseRankings: `occupationlab/occupationlab/data/kanban/courseRankings`,
platformLoginStatistics: `users/users/user/platformLoginStatistics`,
activityRanking: `occupationlab/occupationlab/data/kanban/activityRanking`,
listByEntity: `product/productLogo/listByEntity`,
};

@ -1,221 +1,252 @@
<template>
<div class="wrap index">
<div class="search">
<h6>精品课程精彩讲解</h6>
<div class="input">
<img src="@/assets/img/search.png" alt="">
<input type="text" placeholder="请输入课程名称" v-model="keyword">
<div class="wrap index">
<div class="search">
<h6>精品课程精彩讲解</h6>
<div class="input">
<img src="@/assets/img/search.png"
alt="">
<input type="text"
placeholder="请输入课程名称"
v-model="keyword">
</div>
</div>
<div class="tabs">
<a class="item"
v-for="(item, i) in tabs"
:key="i"
:class="{active: item.id == active}"
@click="tabChange(item)">{{ item.name }}</a>
</div>
<!-- 课程筛选 -->
<div class="filter">
<div class="wrap-inner"
style="padding-bottom: 0">
<dl v-if="active != 2">
<dt>课程分类</dt>
<dd :class="{active: form.categoryId === ''}"
@click="changeCategory('')">不限</dd>
<dd v-for="(item, i) in classificationList"
:key="i"
:class="{active: form.categoryId === item.id}"
@click="changeCategory(item.id)">{{ item.classificationName }}</dd>
</dl>
<dl>
<dt>课程类型</dt>
<dd v-for="(item, i) in types"
:key="i"
:class="{active: form.courseType === item.id}"
@click="changeType(item.id)">{{ item.name }}</dd>
</dl>
</div>
</div>
<!-- 课程列表 -->
<div class="courses">
<div class="course-bg"></div>
<template v-if="list.length">
<ul>
<li v-for="(item, index) in list"
:key="index"
@click="toDetail(item.id)">
<img :src="item.coverUrl"
alt="" />
<div class="title">{{ item.courseName }}</div>
<div class="desc"
:class="{ie: core.isIE(),ie: core.isFirefox()}"
v-html="item.courseIntroduction"></div>
<div class="metas">
<div class="meta">
<i class="el-icon-view"></i>
{{ item.pageviews }}
</div>
<div class="meta collect"
@click.stop="collect(item)">
<i :class="item.collectionStatus ? 'el-icon-star-on' : 'el-icon-star-off'"></i>
</div>
<div class="meta">
<i class="el-icon-user"></i>
{{ item.schoolName }}
</div>
<span v-if="item.courseType == 0"
class="type">{{ item.courseType == 1 ? '付费' : '免费'}}</span>
</div>
</li>
</ul>
<div class="pagination">
<el-pagination background
layout="total, prev, pager, next"
:total="total"
@current-change="handleCurrentChange"
:current-page="page">
</el-pagination>
</div>
<div class="tabs">
<a class="item" v-for="(item, i) in tabs" :key="i" :class="{active: item.id == active}" @click="tabChange(item)">{{ item.name }}</a>
</template>
<template v-else>
<div class="empty">
<div>
<img src="@/assets/img/none.png"
alt="">
<p>暂无课程</p>
</div>
<!-- 课程筛选 -->
<div class="filter">
<div class="wrap-inner" style="padding-bottom: 0">
<dl v-if="active != 2">
<dt>课程分类</dt>
<dd :class="{active: form.categoryId === ''}" @click="changeCategory('')">不限</dd>
<dd v-for="(item, i) in classificationList" :key="i" :class="{active: form.categoryId === item.id}" @click="changeCategory(item.id)">{{ item.classificationName }}</dd>
</dl>
<dl>
<dt>课程类型</dt>
<dd v-for="(item, i) in types" :key="i" :class="{active: form.courseType === item.id}" @click="changeType(item.id)">{{ item.name }}</dd>
</dl>
</div>
</div>
<!-- 课程列表 -->
<div class="courses">
<div class="course-bg"></div>
<template v-if="list.length">
<ul>
<li v-for="(item, index) in list" :key="index" @click="toDetail(item.id)">
<img :src="item.coverUrl" alt="" />
<div class="title">{{ item.courseName }}</div>
<div class="desc" :class="{ie: core.isIE(),ie: core.isFirefox()}" v-html="item.courseIntroduction"></div>
<div class="metas">
<div class="meta">
<i class="el-icon-view"></i>
{{ item.pageviews }}
</div>
<div class="meta collect" @click.stop="collect(item)">
<i :class="item.collectionStatus ? 'el-icon-star-on' : 'el-icon-star-off'"></i>
</div>
<div class="meta">
<i class="el-icon-user"></i>
{{ item.schoolName }}
</div>
<span v-if="item.courseType == 0" class="type">{{ item.courseType == 1 ? '付费' : '免费'}}</span>
</div>
</li>
</ul>
<div class="pagination">
<el-pagination background layout="total, prev, pager, next" :total="total" @current-change="handleCurrentChange" :current-page="page">
</el-pagination>
</div>
</template>
<template v-else>
<div class="empty">
<div>
<img src="@/assets/img/none.png" alt="">
<p>暂无课程</p>
</div>
</div>
</template>
</div>
</template>
</div>
</div>
</template>
<script>
import { Loading } from "element-ui";
import Setting from "@/setting";
import util from "@/libs/util"
export default {
name: "course",
data() {
return {
timer: null,
isTourist: !!Setting.whiteList.find(e => e === this.$route.path),
active: +this.$route.query.source || 0,
tabs: [
{
id: 0,
name: '共享课程'
},
{
id: 2,
name: '我的收藏'
}
],
form: {
categoryId: '',
courseType: ''
},
classificationList: [],
types: [
{
id: '',
name: '不限'
},
{
id: 0,
name: '免费'
},
{
id: 1,
name: '付费'
}
],
list: [],
keyword: '',
total: 0,
page: 1,
pageSize: window.innerWidth > 1700 ? 10 : 8,
searchTimer: null,
loadIns: null
};
},
mounted() {
//
this.isTourist || this.tabs.splice(1, 0, {
id: 1,
name: '本校课程'
})
this.getClassification(0)
this.getData()
this.$once('hook:beforeDestroy', function() {
clearInterval(this.timer)
})
},
watch: {
keyword: function(val) {
clearTimeout(this.searchTimer);
this.searchTimer = setTimeout(() => {
this.initData();
}, 500);
}
},
methods: {
getList() {
//
this.$post(this.api[this.isTourist ? 'studentLoginPreCourse' : 'pageConditionalQueryCourseByStudent'], {
...this.form,
pageNum: this.page,
pageSize: this.pageSize,
courseSource: this.active,
keyWord: this.keyword
}).then(({ page }) => {
this.list = page.records
this.total = page.total
this.list.map(n => {
n.courseIntroduction = n.courseIntroduction.replace(/<img.*?(?:>|\/>)/gi, "")
})
this.loadIns.close()
}).catch(res => {
this.loadIns.close()
})
},
// redis
getRedis() {
this.$post(this.api.getRedisCache).then(({ data }) => {
data && this.getList()
}).catch(res => {})
},
getData() {
this.loadIns = Loading.service()
this.getList()
if (!Setting.isDev) {
clearInterval(this.timer)
this.timer = setInterval(this.getRedis, 1000)
}
},
initData() {
this.page = 1;
this.getData();
name: "course",
data () {
return {
timer: null,
token: util.local.get(Setting.tokenKey),
isTourist: !!Setting.whiteList.find(e => e === this.$route.path),
active: +this.$route.query.source || 0,
tabs: [
{
id: 0,
name: '共享课程'
},
//
getClassification(platformSource) {
this.$post(this.api.listClassification, {
pageNum: 1,
pageSize: 1000,
platformSource
}).then(({ page }) => {
this.classificationList = page.records
}).catch(res => {})
],
form: {
categoryId: '',
courseType: ''
},
classificationList: [],
types: [
{
id: '',
name: '不限'
},
// tab
tabChange(item) {
this.form = {
categoryId: '',
courseType: ''
}
this.active = item.id
this.getClassification(item.id)
this.initData()
{
id: 0,
name: '免费'
},
//
changeCategory(id) {
this.form.categoryId = id
this.initData()
},
//
changeType(id) {
this.form.courseType = id
this.initData()
},
handleCurrentChange(val) {
this.page = val;
this.getData();
},
//
collect(item) {
this.$post(`${this.api.collectCourse}?courseId=${item.id}&state=${item.collectionStatus ? 0 : 1}`).then(res => {
this.getData()
}).catch(res => {})
},
toDetail(id) {
this.$router.push(`/${this.isTourist ? 'preCourse' : 'course'}/details?id=${id}&source=${this.active}`);
{
id: 1,
name: '付费'
}
],
list: [],
keyword: '',
total: 0,
page: 1,
pageSize: window.innerWidth > 1700 ? 10 : 8,
searchTimer: null,
loadIns: null
};
},
mounted () {
//
this.token && this.tabs.push({
id: 2,
name: '我的收藏'
})
//
this.isTourist || this.tabs.splice(1, 0, {
id: 1,
name: '本校课程'
})
this.getClassification(0)
this.getData()
this.$once('hook:beforeDestroy', function () {
clearInterval(this.timer)
})
},
watch: {
keyword: function (val) {
clearTimeout(this.searchTimer);
this.searchTimer = setTimeout(() => {
this.initData();
}, 500);
}
},
methods: {
getList () {
//
this.$post(this.api[this.isTourist ? 'studentLoginPreCourse' : 'pageConditionalQueryCourseByStudent'], {
...this.form,
pageNum: this.page,
pageSize: this.pageSize,
courseSource: this.active,
keyWord: this.keyword
}).then(({ page }) => {
this.list = page.records
this.total = page.total
this.list.map(n => {
n.courseIntroduction = n.courseIntroduction.replace(/<img.*?(?:>|\/>)/gi, "")
})
this.loadIns.close()
}).catch(res => {
this.loadIns.close()
})
},
// redis
getRedis () {
this.$post(this.api.getRedisCache).then(({ data }) => {
data && this.getList()
}).catch(res => { })
},
getData () {
this.loadIns = Loading.service()
this.getList()
if (!Setting.isDev) {
clearInterval(this.timer)
this.timer = setInterval(this.getRedis, 1000)
}
},
initData () {
this.page = 1;
this.getData();
},
//
getClassification (platformSource) {
this.$post(this.api.listClassification, {
pageNum: 1,
pageSize: 1000,
platformSource
}).then(({ page }) => {
this.classificationList = page.records
}).catch(res => { })
},
// tab
tabChange (item) {
this.form = {
categoryId: '',
courseType: ''
}
this.active = item.id
this.getClassification(item.id)
this.initData()
},
//
changeCategory (id) {
this.form.categoryId = id
this.initData()
},
//
changeType (id) {
this.form.courseType = id
this.initData()
},
handleCurrentChange (val) {
this.page = val;
this.getData();
},
//
collect (item) {
this.$post(`${this.api.collectCourse}?courseId=${item.id}&state=${item.collectionStatus ? 0 : 1}`).then(res => {
this.getData()
}).catch(res => { })
},
toDetail (id) {
this.$router.push(`/${this.isTourist ? 'preCourse' : 'course'}/details?id=${id}&source=${this.active}`);
}
}
};
</script>
@ -225,9 +256,9 @@ export default {
padding: 100px 0 130px;
text-align: center;
background: url(../../../assets/img/course-bg2.png) (73px 50px)/250px auto no-repeat,
url(../../../assets/img/course-bg4.png) (top left)/auto no-repeat,
url(../../../assets/img/course-bg3.png) (top right)/auto no-repeat,
url(../../../assets/img/course-bg1.png) 0 0/100% 100% no-repeat;
url(../../../assets/img/course-bg4.png) (top left) / auto no-repeat,
url(../../../assets/img/course-bg3.png) (top right) / auto no-repeat,
url(../../../assets/img/course-bg1.png) 0 0/100% 100% no-repeat;
h6 {
margin-bottom: 25px;
font-size: 26px;
@ -269,8 +300,8 @@ export default {
border-bottom: 3px solid transparent;
cursor: pointer;
&.active {
color: #007EFF;
border-color: #007EFF;
color: #007eff;
border-color: #007eff;
}
}
}
@ -305,14 +336,14 @@ export default {
.courses {
position: relative;
padding: 10px 0 20px;
background: url(../../../assets/img/course3.png) 0 0/auto no-repeat;
background: url(../../../assets/img/course3.png) 0 0 / auto no-repeat;
.course-bg {
position: absolute;
top: 0;
right: 0;
width: 602px;
height: 100%;
background: url(../../../assets/img/course4.png) (0 -100px)/140% 140% no-repeat;
position: absolute;
top: 0;
right: 0;
width: 602px;
height: 100%;
background: url(../../../assets/img/course4.png) (0 -100px)/140% 140% no-repeat;
}
ul {
position: relative;
@ -334,11 +365,11 @@ export default {
img {
width: 100%;
height: 165px;
transition: .3s;
transition: 0.3s;
}
.title {
margin: 10px 0 5px;
color: #0B1D30;
color: #0b1d30;
font-size: 16px;
word-wrap: break-word;
word-break: break-all;
@ -352,7 +383,7 @@ export default {
background-color: #f00;
}
.desc {
color: #757F92;
color: #757f92;
font-size: 14px;
display: -webkit-box;
-webkit-box-orient: vertical;
@ -366,36 +397,37 @@ export default {
}
}
.type {
display: inline-block;
padding: 2px 10px;
border-radius: 20px;
color: #1cdbb8;
border: 1px solid;
display: inline-block;
padding: 2px 10px;
border-radius: 20px;
color: #1cdbb8;
border: 1px solid;
}
.metas {
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 10px;
display: flex;
justify-content: space-between;
align-items: center;
margin-top: 10px;
}
.meta {
color: #a9a9a9;
font-size: 12px;
color: #a9a9a9;
font-size: 12px;
}
.collect {
font-size: 20px;
font-size: 20px;
}
&:hover {
box-shadow: 0px 5px 12px 4px rgba(142, 123, 253, 0.09), 0px 3px 6px 0px rgba(142, 123, 253, 0.12), 0px 1px 2px -2px rgba(142, 123, 253, 0.16);
box-shadow: 0px 5px 12px 4px rgba(142, 123, 253, 0.09), 0px 3px 6px 0px rgba(142, 123, 253, 0.12),
0px 1px 2px -2px rgba(142, 123, 253, 0.16);
img {
transform: scale(1.05);
transform: scale(1.05);
}
}
}
@media (max-width: 1700px) {
li {
width: calc(25% - 20px);
}
li {
width: calc(25% - 20px);
}
}
}
}

@ -352,9 +352,9 @@
alt="">
</div>
<div class="text">
<p class="title">售前咨询</p>
<p class="title">产品咨询</p>
<p class="tel-num"
style="margin-bottom: 5px"></p>
style="margin-bottom: 5px">老师</p>
<p class="tel-num">17671782660</p>
</div>
</div>
@ -396,7 +396,9 @@ export default {
methods: {
toPart (i) {
this.active = i
document.querySelector(`#part${i}`).scrollIntoView()
document.querySelector(`#part${i}`).scrollIntoView({
behavior: 'smooth'
})
},
//
topping () {

@ -1166,19 +1166,28 @@ export default {
},
//
removePar (e, stage) {
this.$confirm('确定要移除该成员吗?', '提示', {
type: 'warning'
}).then(() => {
this.$post(this.api.cancelParticipant, {
accountId: e.id,
competitionId: this.id,
stageId: stage.stageId,
teamId: this.info.teamId
}).then(res => {
util.successMsg('移除成功')
this.getInfo()
}).catch(res => { })
}).catch(() => { })
const item = this.form.competitionStage.find(e => e.stageId == stage.stageId)
if (item) {
//
const now = new Date()
if (now >= new Date(item.startTime) && now <= new Date(item.endTime)) {
return util.errorMsg('该阶段比赛已经开始,无法修改允许参赛人员!')
} else {
this.$confirm('确定要移除该成员吗?', '提示', {
type: 'warning'
}).then(() => {
this.$post(this.api.cancelParticipant, {
accountId: e.id,
competitionId: this.id,
stageId: stage.stageId,
teamId: this.info.teamId
}).then(res => {
util.successMsg('移除成功')
this.getInfo()
}).catch(res => { })
}).catch(() => { })
}
}
},
//
selectPar (row) {

@ -28,8 +28,8 @@ if (isPro) {
uploadURL = `http://121.37.12.51/`
host = "http://121.37.12.51/"; // 测试服
// host = 'https://www.occupationlab.com/' // 正式服
// host = "http://192.168.31.152:9000/"; // 榕
host = "http://192.168.31.51:9000/"; // 赓
// host = "http://192.168.31.217:9000/"; // 榕
// host = "http://192.168.31.51:9000/"; // 赓
}
const Setting = {

Loading…
Cancel
Save