2023-03-16 10:06:15 +08:00
|
|
|
|
<template>
|
|
|
|
|
|
<div>
|
|
|
|
|
|
<div class="fullHeight">
|
|
|
|
|
|
<div class="headers">
|
|
|
|
|
|
<div class="headerName">课程学习</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
|
|
<video
|
|
|
|
|
|
:src="$store.state.FILEURL + courseDetail.eduVideo"
|
|
|
|
|
|
controls
|
|
|
|
|
|
class="videoBox"
|
|
|
|
|
|
></video>
|
|
|
|
|
|
<div class="courseTitle">
|
|
|
|
|
|
{{ courseDetail.eduCourseName }}
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="desc">
|
|
|
|
|
|
课程类型:{{ educateTypeList[courseDetail.eduType - 1] }}
|
|
|
|
|
|
</div>
|
|
|
|
|
|
<div class="desc">试卷总分:{{ courseDetail.totalScore }}</div>
|
|
|
|
|
|
<div class="desc">及格分数:{{ courseDetail.passScore }}</div>
|
|
|
|
|
|
<div class="desc">创建时间:{{ courseDetail.addTime }}</div>
|
|
|
|
|
|
<button
|
|
|
|
|
|
type="primary"
|
|
|
|
|
|
class="btn submitBtn big"
|
|
|
|
|
|
@click="gotoTest"
|
|
|
|
|
|
v-if="courseDetail.questionList.length > 0"
|
|
|
|
|
|
>
|
|
|
|
|
|
开始考试
|
|
|
|
|
|
</button>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
|
import { getSelectSafeEducationQuestionInfoList } from '@/assets/js/api/safeManage.js'
|
|
|
|
|
|
export default {
|
|
|
|
|
|
data() {
|
|
|
|
|
|
return {
|
|
|
|
|
|
courseDetail: {
|
|
|
|
|
|
eduAddr: '',
|
|
|
|
|
|
eduClasshour: '',
|
|
|
|
|
|
eduContent: '',
|
|
|
|
|
|
eduCourseName: '',
|
|
|
|
|
|
eduPhoto: '',
|
|
|
|
|
|
eduTeacher: '',
|
|
|
|
|
|
eduTime: '',
|
|
|
|
|
|
eduType: 1,
|
|
|
|
|
|
eduVideo: '',
|
|
|
|
|
|
passScore: '',
|
|
|
|
|
|
projectSn: '',
|
|
|
|
|
|
questionList: [],
|
|
|
|
|
|
totalScore: '',
|
|
|
|
|
|
addTime: ''
|
|
|
|
|
|
},
|
|
|
|
|
|
educateTypeList: [
|
|
|
|
|
|
'入场三级教育',
|
|
|
|
|
|
'定期安全教育',
|
|
|
|
|
|
'安全技术交底',
|
|
|
|
|
|
'VR安全教育'
|
|
|
|
|
|
],
|
|
|
|
|
|
eduId: '',
|
|
|
|
|
|
workerId: ''
|
|
|
|
|
|
}
|
|
|
|
|
|
},
|
|
|
|
|
|
created(options) {
|
|
|
|
|
|
console.log('获取课程详细数据1516', this.$route.query)
|
|
|
|
|
|
this.eduId = this.$route.query.eduId
|
|
|
|
|
|
this.workerId = this.$route.query.workerId
|
|
|
|
|
|
this.getDetailData()
|
|
|
|
|
|
},
|
|
|
|
|
|
methods: {
|
|
|
|
|
|
gotoTest() {
|
|
|
|
|
|
this.$router.push({
|
|
|
|
|
|
path: '/test',
|
|
|
|
|
|
query: {
|
|
|
|
|
|
eduId: this.eduId,
|
|
|
|
|
|
workerId: this.workerId
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
|
|
|
},
|
|
|
|
|
|
//获取课程详细数据
|
|
|
|
|
|
getDetailData() {
|
|
|
|
|
|
var that = this
|
|
|
|
|
|
console.log('获取课程详细数据1515')
|
|
|
|
|
|
getSelectSafeEducationQuestionInfoList({ eduId: this.eduId }).then(
|
|
|
|
|
|
(result) => {
|
|
|
|
|
|
if (result.result) {
|
|
|
|
|
|
that.courseDetail = result.result.safeEducation
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
)
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
<style scoped>
|
2023-03-17 10:46:11 +08:00
|
|
|
|
.fullHeight {
|
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
height: 120%;
|
|
|
|
|
|
}
|
2023-03-16 10:06:15 +08:00
|
|
|
|
.videoBox {
|
|
|
|
|
|
width: 100%;
|
2023-03-17 10:46:11 +08:00
|
|
|
|
height: 100rem;
|
|
|
|
|
|
margin: 0rem 0;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
}
|
|
|
|
|
|
.courseTitle {
|
2023-03-17 10:46:11 +08:00
|
|
|
|
font-size: 7.5rem;
|
|
|
|
|
|
|
|
|
|
|
|
padding: 2rem 7.5rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
}
|
|
|
|
|
|
.desc {
|
2023-03-17 10:46:11 +08:00
|
|
|
|
font-size: 6rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
opacity: 0.6;
|
2023-03-17 10:46:11 +08:00
|
|
|
|
padding: 2.5rem 0 0 7.5rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
}
|
|
|
|
|
|
.submitBtn {
|
2023-03-17 10:46:11 +08:00
|
|
|
|
margin: -70rem 5rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
position: fixed;
|
2023-03-17 10:46:11 +08:00
|
|
|
|
bottom: 10rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
/* left: 20px; */
|
2023-03-17 10:46:11 +08:00
|
|
|
|
width: calc(100% - 10rem);
|
2023-03-16 10:06:15 +08:00
|
|
|
|
background: #4181fe;
|
2023-03-17 10:46:11 +08:00
|
|
|
|
height: 15rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
border: none;
|
|
|
|
|
|
color: #fff;
|
2023-03-17 10:46:11 +08:00
|
|
|
|
font-size: 7.5rem;
|
|
|
|
|
|
border-radius: 10rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
}
|
|
|
|
|
|
.headers {
|
2023-03-17 10:46:11 +08:00
|
|
|
|
/* border-bottom: 0.5rem solid #f3f3f3; */
|
|
|
|
|
|
height: 8rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
color: #3d4490;
|
2023-03-17 10:46:11 +08:00
|
|
|
|
font-size: 7.5rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
text-align: center;
|
2023-03-17 10:46:11 +08:00
|
|
|
|
line-height: 6rem;
|
|
|
|
|
|
margin-top: -55%;
|
|
|
|
|
|
/* background-color: pink; */
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/* 播放器按钮 */
|
|
|
|
|
|
::v-deep video::-webkit-media-controls-play-button {
|
|
|
|
|
|
/* background-image: url(play-button.png); */
|
|
|
|
|
|
/* display: none; */
|
|
|
|
|
|
width: 200rem;
|
|
|
|
|
|
height: 200rem;
|
2023-03-16 10:06:15 +08:00
|
|
|
|
}
|
|
|
|
|
|
</style>
|