This commit is contained in:
parent
0f2f253b7f
commit
c807a13d5e
|
|
@ -2,53 +2,27 @@
|
|||
<view class="page">
|
||||
<u-navbar title="学习项目" @leftClick="leftClick" placeholder />
|
||||
<view class="proj-cont">
|
||||
<h2 style="margin-bottom: 15rpx">{{ name }}</h2>
|
||||
<span style="font-size: 12px; color: #b0b0b0">合格标准:学习进度达到{{ eligibility }}%</span>
|
||||
<h2 style="margin: 0 10px 8px">{{ name }}</h2>
|
||||
<span style="font-size: 15px; color: #b0b0b0; margin: 0 10px">合格标准:学习进度达到{{ eligibility }}%</span>
|
||||
<view class="user-info">
|
||||
<div style="font-size: 18px">{{ createUserName }}</div>
|
||||
<div style="font-size: 18px; margin: 0 10px">{{ createUserName }}</div>
|
||||
<div class="training-content">
|
||||
<div>培训内容:{{ listStageContentNum || '暂无' }}</div>
|
||||
</div>
|
||||
<!-- <view class="info-lef">
|
||||
<view class="avatar">
|
||||
<image src="/static/eduImg/avatar.jpg"></image>
|
||||
<div style="font-size: 18px">{{ createUserName }}</div>
|
||||
</view>
|
||||
<view style="display: flex; align-items: center">
|
||||
<l-starRate v-model="starRate" :disabled="true" style="margin-right: 1vw"></l-starRate>
|
||||
<span style="color: #ffca3e">{{ starRate }}.0</span>
|
||||
</view>
|
||||
</view>
|
||||
<view class="info-rig">
|
||||
<view class="rig-up">
|
||||
<view>
|
||||
培训内容
|
||||
<span>{{ 'listStageContentNum' }}</span>
|
||||
</view>
|
||||
<view style="margin-left: 2vw">
|
||||
观看记录
|
||||
<span>28</span>
|
||||
<uni-icons style="color: #b0b0b0" type="right" size="12"></uni-icons>
|
||||
</view>
|
||||
</view>
|
||||
<view class="rig-dn">
|
||||
去评分
|
||||
<uni-icons style="color: #b0b0b0" type="right" size="12"></uni-icons>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
<!-- <view class="tip">已开启进度同步,其他途径的学习进度已自动同步</view> -->
|
||||
<div v-for="(stageItem, stageIndex) in listStage" :key="stageIndex" :title="stageItem.stageName">
|
||||
<div class="item-stage" @click="handleShow(stageItem)">
|
||||
<span>{{ stageItem.stageName }}</span>
|
||||
<u-icon :name="stageItem.isShow ? 'arrow-down' : 'arrow-up'" size="17" />
|
||||
<span style="font-size: 18px; margin: 0 10px">{{ stageItem.stageName }}</span>
|
||||
<u-icon :name="stageItem.isShow ? 'arrow-down' : 'arrow-up'" size="20" />
|
||||
</div>
|
||||
<div v-if="stageItem.isShow">
|
||||
<div v-for="(content, conIndex) in stageItem.listStageContent" :key="conIndex">
|
||||
<u-collapse :border="false">
|
||||
<u-collapse-item title="素材" v-if="content.stageType == 1" :border="false">
|
||||
<u-collapse :border="false" :value="[1]">
|
||||
<u-collapse-item v-if="content.stageType == 1" :border="false" :name="1">
|
||||
<text slot="title" class="u-page__item__title__slot-title slot-item-title">素材</text>
|
||||
<div
|
||||
class="list-wrapper"
|
||||
class="list-wrapper u-collapse-content"
|
||||
v-for="(item, index) in content.studyList"
|
||||
:key="index"
|
||||
@click="toggleTheoryLearn(item, content)"
|
||||
|
|
@ -74,9 +48,10 @@
|
|||
</div>
|
||||
</div>
|
||||
</u-collapse-item>
|
||||
<u-collapse-item title="课程" v-if="content.stageType == 2" :border="false">
|
||||
<u-collapse-item v-if="content.stageType == 2" :border="false" :name="1">
|
||||
<text slot="title" class="u-page__item__title__slot-title slot-item-title">课程</text>
|
||||
<div
|
||||
class="list-wrapper"
|
||||
class="list-wrapper u-collapse-content"
|
||||
v-for="(item, index) in content.studyList"
|
||||
:key="index"
|
||||
@click="toggleTheoryLearn(item, content)"
|
||||
|
|
@ -103,8 +78,9 @@
|
|||
</div>
|
||||
</u-collapse-item>
|
||||
|
||||
<u-collapse-item title="练习" v-if="content.stageType == 3" :border="false">
|
||||
<div class="list-wrapper" @click="toggleTheoryPrac(content)">
|
||||
<u-collapse-item v-if="content.stageType == 3" :border="false" :name="1">
|
||||
<text slot="title" class="u-page__item__title__slot-title slot-item-title">练习</text>
|
||||
<div class="list-wrapper u-collapse-content" @click="toggleTheoryPrac(content)">
|
||||
<div class="left-content">
|
||||
<div class="title">
|
||||
<u-icon name="/static/images/exercises.png" size="15" />
|
||||
|
|
@ -125,8 +101,9 @@
|
|||
</div>
|
||||
</u-collapse-item>
|
||||
|
||||
<u-collapse-item title="考试" v-if="content.stageType == 4" :border="false">
|
||||
<div class="list-wrapper" @click="toggleTheoryExam(content)">
|
||||
<u-collapse-item v-if="content.stageType == 4" :border="false" :name="1">
|
||||
<text slot="title" class="u-page__item__title__slot-title slot-item-title">考试</text>
|
||||
<div class="list-wrapper u-collapse-content" @click="toggleTheoryExam(content)">
|
||||
<div class="left-content">
|
||||
<div class="title">
|
||||
<u-icon name="/static/images/examine.png" size="15" />
|
||||
|
|
@ -157,43 +134,6 @@
|
|||
</div>
|
||||
</div>
|
||||
</view>
|
||||
<!-- <view class="comment-area">
|
||||
<h2 style="margin-bottom: 15rpx">最新评论 ({{ commentList.length }})</h2>
|
||||
<view class="write-cmt">
|
||||
<u--input
|
||||
ref="uInput"
|
||||
placeholder="写评论"
|
||||
prefixIcon="edit-pen"
|
||||
prefixIconStyle="font-size: 18px;color: #c0c4cc"
|
||||
placeholderStyle="font-size: 13px;color: #c0c4cc"
|
||||
border="none"
|
||||
maxlength="999"
|
||||
clearable
|
||||
/>
|
||||
</view>
|
||||
<view class="cmts" v-for="(item, index) in commentList" :key="index">
|
||||
<view class="cmt-up">
|
||||
<image :src="item.avatar"></image>
|
||||
<span>{{ item.username }}</span>
|
||||
</view>
|
||||
<view class="cmt-dn">
|
||||
{{ item.cont }}
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
<!-- <view class="btm-sticky">
|
||||
<view class="icons">
|
||||
<view>
|
||||
<uni-icons style="color: #1989fa; margin-right: 1vw" type="chat-filled" size="24"></uni-icons>
|
||||
<span>23</span>
|
||||
</view>
|
||||
<view>
|
||||
<uni-icons style="color: #1989fa; margin-right: 1vw" type="hand-up-filled" size="24"></uni-icons>
|
||||
<span>12</span>
|
||||
</view>
|
||||
</view>
|
||||
<view class="learn-btn">继续学习</view>
|
||||
</view> -->
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
|
@ -214,34 +154,6 @@ export default {
|
|||
learnIconObj: { color: '#1A63AC', size: '18', type: 'calendar' },
|
||||
pracIconObj: { color: '#38B022', size: '18', type: 'compose' },
|
||||
listStage: []
|
||||
// theoryLearnList: [
|
||||
// { title: '高压电', id: 121, percent: 86 },
|
||||
// { title: '氨基酸', id: 122, percent: 42 },
|
||||
// { title: '维他命', id: 123, percent: 66 },
|
||||
// { title: '电功率', id: 124, percent: 13 }
|
||||
// ],
|
||||
// theoryPracList: [
|
||||
// { title: '物理练习', id: 141, ifPrac: false },
|
||||
// { title: '魔法练习', id: 142, ifPrac: true },
|
||||
// { title: '近战练习', id: 143, ifPrac: true },
|
||||
// { title: '远程练习', id: 144, ifPrac: false }
|
||||
// ],
|
||||
// theoryExamList: [
|
||||
// { title: '物理考试', id: 161, ifExam: false, time: '00:34:21' },
|
||||
// { title: '魔法考试', id: 162, ifExam: true, time: '00:34:21' },
|
||||
// { title: '近战考试', id: 163, ifExam: true, time: '00:34:21' },
|
||||
// { title: '远程考试', id: 164, ifExam: false, time: '00:34:21' }
|
||||
// ],
|
||||
// commentList: [
|
||||
// { username: '王二', avatar: '/static/eduImg/avatar.jpg', cont: '写的什么东西' },
|
||||
// { username: '张三', avatar: '/static/eduImg/avatar.jpg', cont: '我感觉写得挺好' },
|
||||
// { username: '李四', avatar: '/static/eduImg/avatar.jpg', cont: '+3' },
|
||||
// {
|
||||
// username: '孙笑川',
|
||||
// avatar: '/static/eduImg/avatar.jpg',
|
||||
// cont: '我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了我着火了'
|
||||
// }
|
||||
// ]
|
||||
}
|
||||
},
|
||||
onLoad(params) {
|
||||
|
|
@ -342,6 +254,9 @@ export default {
|
|||
const validityDate = item.examMsg.validityDate.split('~')
|
||||
const startDate = new Date(validityDate[0].trim())
|
||||
const endDate = new Date(validityDate[1].trim())
|
||||
console.log('🚀 ~ 时间 ~ date:', date)
|
||||
console.log('🚀 ~ 时间 ~ startDate:', startDate)
|
||||
console.log('🚀 ~ 时间 ~ endDate:', endDate)
|
||||
if (date < startDate || date > endDate) {
|
||||
uni.showToast({
|
||||
title: '当前时间不在考试时间范围内',
|
||||
|
|
@ -422,10 +337,12 @@ export default {
|
|||
height: 100vh;
|
||||
background-color: #f8f8f8;
|
||||
box-sizing: border-box;
|
||||
padding: 5vw 5px;
|
||||
padding: 5vw 10px;
|
||||
position: relative;
|
||||
font-style: 20px;
|
||||
|
||||
.item-stage {
|
||||
height: 50px;
|
||||
margin: 8px 0;
|
||||
font-size: 16px;
|
||||
display: flex;
|
||||
|
|
@ -436,13 +353,20 @@ export default {
|
|||
.proj-cont {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
padding: 30rpx 20rpx;
|
||||
padding: 30rpx 0;
|
||||
background-color: #fff;
|
||||
border-radius: 20rpx;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
box-shadow: #f4f4f4 2px 2px;
|
||||
|
||||
.slot-item-title {
|
||||
margin-left: 10px;
|
||||
height: 45px;
|
||||
line-height: 45px;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.user-info {
|
||||
width: 100%;
|
||||
/* height: 8vh; */
|
||||
|
|
@ -452,6 +376,7 @@ export default {
|
|||
margin-bottom: 2vh;
|
||||
|
||||
.training-content {
|
||||
margin: 0 10px;
|
||||
display: flex;
|
||||
margin-top: 10px;
|
||||
white-space: normal;
|
||||
|
|
@ -518,6 +443,8 @@ export default {
|
|||
}
|
||||
|
||||
.list-wrapper {
|
||||
padding: 10px;
|
||||
min-height: 90px;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
|
@ -525,11 +452,12 @@ export default {
|
|||
margin-bottom: 10px;
|
||||
padding-bottom: 5px;
|
||||
border-bottom: 1px solid #f0f0f0;
|
||||
font-size: 12px;
|
||||
color: #b0b0b0;
|
||||
/* height: 400px; */
|
||||
background-color: #e6f0fa;
|
||||
overflow: auto;
|
||||
.left-content {
|
||||
font-size: 18px;
|
||||
width: 50vw;
|
||||
.title {
|
||||
display: flex;
|
||||
|
|
@ -537,8 +465,8 @@ export default {
|
|||
}
|
||||
.note {
|
||||
/* width: 130px; */
|
||||
margin-top: 10px;
|
||||
font-size: 14px;
|
||||
margin-top: 15px;
|
||||
margin-bottom: 10px;
|
||||
color: #333;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue