|
|
|
@ -3,7 +3,7 @@
|
|
|
|
|
<view v-if="$store.getters.token || userInfo.uid"> |
|
|
|
|
<view class="swiper-box"> |
|
|
|
|
<view class="swiper-item"> |
|
|
|
|
<image :src="detail.imageArr[0]" mode="aspectFill" :key="index"></image> |
|
|
|
|
<image :src="detail.coverImg" mode="aspectFill" :key="index"></image> |
|
|
|
|
</view> |
|
|
|
|
<!-- <swiper :indicator-dots="true" :autoplay="true" :interval="3000" :duration="1000"> |
|
|
|
|
<swiper-item v-for="(item,index) in detail.imageArr" :key="index"> |
|
|
|
@ -19,7 +19,7 @@
|
|
|
|
|
</view> |
|
|
|
|
<view class="tips-box"> |
|
|
|
|
<view class="tip-item blue">{{detail.categoryName}}</view> |
|
|
|
|
<view class="tip-item orange">{{detail.levelName}}</view> |
|
|
|
|
<view class="tip-item orange">{{detail.flag[0]}}</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="tab-box acea-row row-around" :class="isFixedTop?'fixed':''"> |
|
|
|
@ -96,11 +96,13 @@
|
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="recommend-box content" id="content3"> |
|
|
|
|
<!-- 相关推荐 --> |
|
|
|
|
<view class="title-box acea-row row-middle row-center" v-if="detail.similarCourseList.length > 0"> |
|
|
|
|
<view class="row-line"></view> |
|
|
|
|
<view class="title">相关推荐</view> |
|
|
|
|
<view class="row-line"></view> |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
<view class="knowledge-list"> |
|
|
|
|
<view class="knowledge-item acea-row" v-for="(item,index) in detail.similarCourseList" :key="index" @click="toDetail(item.id)"> |
|
|
|
|
<view class="img-box"> |
|
|
|
@ -127,45 +129,31 @@
|
|
|
|
|
<view class="footer-box acea-row row-between-wrapper"> |
|
|
|
|
<view class="footer-left"> |
|
|
|
|
<view class="price" v-if="detail.signState == 1">座位号:{{detail.seat}}</view> |
|
|
|
|
<!-- <view class="price" v-if="detail.level > 2">{{detail.level}}级课程</view> |
|
|
|
|
<view class="price" v-if="detail.level == 2"><span class="fz24">¥</span>{{detail.courseCharge}} </view> |
|
|
|
|
<view class="price colG" v-if="detail.chargeType == 0">免费</view> --> |
|
|
|
|
</view> |
|
|
|
|
<view class="footer-right"> |
|
|
|
|
|
|
|
|
|
<view class="btn-box acea-row row-between-wrapper" v-if="userInfo.phone != '' && teacherId != null && detail.haveSeller == 0 && detail.enterState == 0"> |
|
|
|
|
<view class="count-down"> |
|
|
|
|
<view>距离截止时间还剩</view> |
|
|
|
|
<uni-countdown color="#F99C10" :day="day" :hour="hour" :minute="minute" :second="second" /> |
|
|
|
|
</view> |
|
|
|
|
<view class="signin-btn" @click="signInClick(2)">立即报名</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="btn-box acea-row row-between-wrapper" v-if="userInfo.phone != '' && detail.haveSeller == 1 && detail.enterState == 0"> |
|
|
|
|
<view class="btn-box acea-row row-between-wrapper" v-if="detail.enterState == 0"> |
|
|
|
|
<view class="count-down"> |
|
|
|
|
<view>距离截止时间还剩</view> |
|
|
|
|
<uni-countdown color="#F99C10" :day="day" :hour="hour" :minute="minute" :second="second" /> |
|
|
|
|
</view> |
|
|
|
|
<view class="signin-btn" @click="signInClick(2)">立即报名</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="signin-btn call-btn default-btn" v-if="detail.enterState == 1 && detail.signState == 2" >已报名</view> |
|
|
|
|
<!-- 在线直播 --> |
|
|
|
|
<view class="signin-btn call-btn default-btn" v-if="detail.enterState == 1 && detail.status == 1 && detail.courseType == 1" @click="signInClick(3)" >立即观看</view> |
|
|
|
|
|
|
|
|
|
<view class="signin-btn call-btn default-btn" v-if="detail.enterState == 1 && detail.status == 0" @click="signInClick(1)" >等待确认 联系服务老师</view> |
|
|
|
|
|
|
|
|
|
<view class="signin-btn call-btn default-btn" v-if="detail.signState == 1" >已签到</view> |
|
|
|
|
<view class="signin-btn call-btn" |
|
|
|
|
@click="signInClick(1)" |
|
|
|
|
v-if="userInfo.phone != '' && detail.haveSeller == 0 && detail.enterState == 0 && teacherId == null"> |
|
|
|
|
联系服务老师 |
|
|
|
|
</view> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- #ifdef MP-WEIXIN --> |
|
|
|
|
<button open-type="getPhoneNumber" |
|
|
|
|
@getphonenumber="getPhoneNumber" v-if="userInfo.phone == '' && detail.haveSeller == 0 && detail.enterState == 0" class="binding signin-btn call-btn" v-else> |
|
|
|
|
@getphonenumber="getPhoneNumber" v-if="userInfo.phone == '' " class="binding signin-btn call-btn" v-else> |
|
|
|
|
<text>点击绑定手机号</text> |
|
|
|
|
</button> |
|
|
|
|
<!-- #endif --> |
|
|
|
|
|
|
|
|
|
<!-- #ifndef MP-WEIXIN --> |
|
|
|
|
<button class="binding" @click="goBindPhone()" v-if="userInfo.phone == '' && detail.haveSeller == 0"> |
|
|
|
|
<text>点击绑定手机号</text> |
|
|
|
|
</button> |
|
|
|
|
<!-- #endif --> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
<view class="mask-box" v-if="maskDialog"> |
|
|
|
@ -348,7 +336,7 @@
|
|
|
|
|
let nowTime = Date.parse(new Date())/1000; |
|
|
|
|
getCourseDetail({id:this.courseId}).then((res)=>{ |
|
|
|
|
uni.hideLoading() |
|
|
|
|
res.data.courseIntroduce = res.data.courseIntroduce.replace(/\<img/g, "<img style='width: 100%;'") |
|
|
|
|
//res.data.courseIntroduce = res.data.courseIntroduce.replace(/\<img/g, "<img style='width: 100%;'") |
|
|
|
|
this.detail = res.data |
|
|
|
|
let t = res.data.signEndTime.replace(/-/g, '/'); |
|
|
|
|
let endTime = Date.parse(new Date(t))/1000 |
|
|
|
@ -388,6 +376,13 @@
|
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
}else if(type == 3){ |
|
|
|
|
console.log("进入直播间"); |
|
|
|
|
let roomId = this.detail.roomId; |
|
|
|
|
let customParams = encodeURIComponent(JSON.stringify({ path: 'pages/index/index', pid: 1 })) |
|
|
|
|
wx.navigateTo({ |
|
|
|
|
url: `plugin-private://wx2b03c6e691cd7370/pages/live-player-plugin?room_id=${roomId}&custom_params=${customParams}` |
|
|
|
|
}) |
|
|
|
|
} else{ |
|
|
|
|
this.sign() |
|
|
|
|
} |
|
|
|
|