视频
This commit is contained in:
@@ -2,124 +2,77 @@
|
||||
<view class="container commonPageBox commonDetailPage">
|
||||
<!-- 公共组件-每个页面必须引入 -->
|
||||
<public-module></public-module>
|
||||
<z-nav-bar bgColor="#3AB3AE" fontColor="#fff"></z-nav-bar>
|
||||
<z-nav-bar
|
||||
bgColor="#333"
|
||||
fontColor="#fff"
|
||||
:title="options.navTitle"
|
||||
></z-nav-bar>
|
||||
|
||||
<view class="contentBox commonPageContentBox curriculum_box">
|
||||
<!-- <view class="curriulum_box">
|
||||
<view class="curriulum_title_box">
|
||||
<view class="curriulum_title">{{ curriculumData.courseTitle
|
||||
}} 介绍</view>
|
||||
<view class="buy">购买</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view> -->
|
||||
<view class="curriculum_content">
|
||||
<common-rich-detail :detailInfo="curriculumData">
|
||||
<template #richHeadImg>
|
||||
<image
|
||||
:src="curriculumData.imgUrl"
|
||||
mode="widthFix"
|
||||
class="headImage"
|
||||
></image>
|
||||
|
||||
<!-- <image :src="detailInfo.imgUrl" v-if="detailInfo.imgUrl" mode="widthFix" class="headImage"></image> -->
|
||||
</template>
|
||||
</common-rich-detail>
|
||||
<p class="aui-text-danger" style="text-align: center">
|
||||
本课程版权归天津众妙之门科技有限公司所有,翻版必究!
|
||||
</p>
|
||||
<view
|
||||
class="contentBox curriculum_box"
|
||||
:style="`height:calc(100% - ${60 + statusBarHeight}px !important;`"
|
||||
>
|
||||
<view :style="`background:#000`">
|
||||
<common-video
|
||||
v-if="isfresh"
|
||||
ref="commonVideo"
|
||||
:currentVideo="currentVideo"
|
||||
:currentVideoList="videoArray"
|
||||
>
|
||||
</common-video>
|
||||
<view style="height: 30vh" v-else></view>
|
||||
</view>
|
||||
|
||||
<!-- <view :class="`priceDetail`" v-if="this.statusList[this.currentStatusIndex].type == 'price'">
|
||||
<!-- <common-sticky
|
||||
style=""
|
||||
itemStyle="width:auto; height: 80rpx;font-size:20rpx;color:#fff"
|
||||
:list="ordersTabs"
|
||||
label="name"
|
||||
:currentCateIndex="currentCateIndex"
|
||||
@handleselectCate="ordersTabCLi"
|
||||
></common-sticky> -->
|
||||
|
||||
<scroll-view scroll-y="true" class="scroll-Y">
|
||||
<price ref="priceDetail" type="price" :oid="this.statusList[this.currentStatusIndex].oid"></price>
|
||||
|
||||
</scroll-view>
|
||||
|
||||
|
||||
|
||||
|
||||
</view>
|
||||
<view :class="`priceDetail`" v-else-if="this.statusList[this.currentStatusIndex].type == 'purchaseNotice'">
|
||||
|
||||
<scroll-view scroll-y="true" class="scroll-Y">
|
||||
<price ref="purchaseNotice" :oid="this.statusList[this.currentStatusIndex].oid"></price>
|
||||
|
||||
</scroll-view>
|
||||
|
||||
|
||||
|
||||
|
||||
</view>
|
||||
-->
|
||||
|
||||
<!-- <view :class="`dataList `">
|
||||
|
||||
<courseDescription :isCondition="true" :dataList="dataList" @hancleClick="gotoDetail" label="title">
|
||||
<template slot="labelSlot" slot-scope="slotProps">
|
||||
<text :class="`${slotProps.row.viewFlg == 1 ? 'aui-text-success' : ''}`">{{ slotProps.row.title
|
||||
}}</text>
|
||||
|
||||
|
||||
|
||||
|
||||
</template>
|
||||
|
||||
<template slot="leftSlot" slot-scope="slotProps">
|
||||
|
||||
|
||||
|
||||
|
||||
</template>
|
||||
<template slot="rightSlot" slot-scope="slotProps">
|
||||
|
||||
|
||||
|
||||
|
||||
<text class="fdButtonBox aui-text-success" v-if="slotProps.row.conditions != '03'">试听</text>
|
||||
|
||||
|
||||
|
||||
<view>
|
||||
|
||||
|
||||
</view>
|
||||
|
||||
</template>
|
||||
|
||||
</courseDescription>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</view> -->
|
||||
|
||||
<view class="small_class_teaching_box" v-if="videoArray.length > 0">
|
||||
<view class="small_class_teaching_top">
|
||||
<view class="small_class_teaching_top_left">
|
||||
<image
|
||||
src="@/static/icon/course_ic.png"
|
||||
mode="aspectFil"
|
||||
class="icon1"
|
||||
></image>
|
||||
<text style="font-weight: 700">视频教学</text>
|
||||
<scroll-view
|
||||
:style="`height:calc(100% - 30vh - 40rpx) ;`"
|
||||
scroll-y="true"
|
||||
class="scroll-Y"
|
||||
style="background-color: #fff"
|
||||
>
|
||||
<view class="PM_font" style="padding: 20rpx;font-size: 40rpx;color: #3ab3ae;">视频教学</view>
|
||||
<view class="scroll-view-item">
|
||||
<view style="padding: 20rpx; margin-bottom: 40rpx">
|
||||
{{ curriculumData.title }}
|
||||
</view>
|
||||
</view>
|
||||
<view class="small_class_teaching_content">
|
||||
<common-curriculum-video
|
||||
v-if="videoArray.length > 0"
|
||||
:detailInfo="curriculumData"
|
||||
:currentVideo="currentVideo"
|
||||
:dataList="videoArray"
|
||||
@open="openVideo"
|
||||
@open="changeVideo"
|
||||
>
|
||||
</common-curriculum-video>
|
||||
<!-- <curriculum-mp3 v-if="isOpenMp3" :detailInfo="curriculumData" :dataList="videoArray" @open="openVideo" ref="mp3Detail">
|
||||
</curriculum-mp3> -->
|
||||
</view>
|
||||
</view>
|
||||
<view class="small_class_teaching_box" v-if="medicalCasesList.length > 0">
|
||||
|
||||
<view class="PM_font" style="padding: 20rpx;font-size: 40rpx;color: #333;">文章简介</view>
|
||||
<view class="scroll-view-item">
|
||||
<common-rich-detail :detailInfo="{ ...curriculumData, title: '' }">
|
||||
<template #richHeadImg>
|
||||
<image
|
||||
:src="curriculumData.imgUrl"
|
||||
mode="widthFix"
|
||||
class="headImage"
|
||||
></image>
|
||||
|
||||
<!-- <image :src="detailInfo.imgUrl" v-if="detailInfo.imgUrl" mode="widthFix" class="headImage"></image> -->
|
||||
</template>
|
||||
</common-rich-detail>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<p class="aui-text-danger" style="text-align: center">
|
||||
本课程版权归天津众妙之门科技有限公司所有,翻版必究!
|
||||
</p>
|
||||
|
||||
<!-- <view class="small_class_teaching_box" v-if="medicalCasesList.length > 0">
|
||||
<view class="small_class_teaching_top">
|
||||
<view class="small_class_teaching_top_left">
|
||||
<image
|
||||
@@ -159,12 +112,10 @@
|
||||
slotProps.row.title
|
||||
}}</view>
|
||||
|
||||
<!-- <text v-if="slotProps.row.conditions!='03'">【试听】</text> -->
|
||||
</template>
|
||||
</template>
|
||||
|
||||
<template slot="rightSlot" slot-scope="slotProps">
|
||||
<!-- {{ slotProps.row.bxType }} -->
|
||||
|
||||
|
||||
<text class="aui-text-danger">
|
||||
¥{{ slotProps.row.courseFee }}</text
|
||||
>
|
||||
@@ -198,7 +149,6 @@
|
||||
style="display: inline-block; margin-right: 10rpx"
|
||||
></u-icon>
|
||||
</template>
|
||||
<!-- <image src="@/static/icon/course_ic.png" mode="aspectFil" class="icon1"></image> -->
|
||||
<text
|
||||
:style="`color:${v.color ? v.color : '#71d5a1'}`"
|
||||
class="title"
|
||||
@@ -255,7 +205,7 @@
|
||||
style="display: inline-block; margin-left: 10rpx"
|
||||
></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
</view> -->
|
||||
</view>
|
||||
|
||||
<!-- <u-modal
|
||||
@@ -286,6 +236,10 @@ export default {
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
isfresh: false,
|
||||
currentCateIndex: 0,
|
||||
currentVideo: {},
|
||||
videoList: {},
|
||||
isOpenMp3: false,
|
||||
praise: "",
|
||||
reward: "",
|
||||
@@ -304,8 +258,8 @@ export default {
|
||||
curriculumInfo: {},
|
||||
fdButtonStyle: {
|
||||
width: "120rpx",
|
||||
"border-color": "$themeColor",
|
||||
color: "$themeColor",
|
||||
"border-color": "#000",
|
||||
color: "#000",
|
||||
float: "right",
|
||||
"margin-right": "20rpx",
|
||||
"margin-left": "30rpx",
|
||||
@@ -316,28 +270,15 @@ export default {
|
||||
playData: {},
|
||||
taiHuClassInfo: {},
|
||||
searchValue: "",
|
||||
teachingList: [
|
||||
ordersTabs: [
|
||||
{
|
||||
title: "临床实践",
|
||||
name: "视频教学",
|
||||
|
||||
type: "02",
|
||||
apiUrl: "app/phoneDoctor.do?getTaiHuToShine",
|
||||
type: "1",
|
||||
},
|
||||
{
|
||||
title: "学习问答",
|
||||
type: "03",
|
||||
oid: "8a9fb99809e4428888aad6b56a3096a6",
|
||||
},
|
||||
{
|
||||
title: "学习心得",
|
||||
|
||||
type: "01",
|
||||
},
|
||||
{
|
||||
title: "在线作业",
|
||||
|
||||
type: "04",
|
||||
oid: "d0f47071c2194e94845fbb373d06f59d",
|
||||
name: "文章简介",
|
||||
type: "2",
|
||||
},
|
||||
], // 一级分类标题1
|
||||
cateList: [], // 一级分类标题1
|
||||
@@ -345,7 +286,7 @@ export default {
|
||||
dataList: [], // 方剂标题
|
||||
allDataList: [], // 方剂标题
|
||||
currentStatusIndex: 0, // 当前选中的一级分类
|
||||
currentCateIndex: 0, // 当前选中的一级分类
|
||||
|
||||
curTwoCateIndex: 0, // 当前选中的二级分类
|
||||
searchList: [], // 搜索结果数组
|
||||
showSearchList: false,
|
||||
@@ -374,6 +315,7 @@ export default {
|
||||
// this.searchList = []
|
||||
},
|
||||
onShow() {
|
||||
this.currentCateIndex = 0;
|
||||
// #ifdef APP-PLUS
|
||||
plus.screen.unlockOrientation(); //解除锁定屏幕方向
|
||||
plus.screen.lockOrientation("portrait-primary");
|
||||
@@ -383,34 +325,50 @@ export default {
|
||||
...mapState(["userInfo"]),
|
||||
},
|
||||
methods: {
|
||||
openVideo(data) {
|
||||
ordersTabCLi(data) {
|
||||
console.log("i at line 312:", data);
|
||||
this.currentCateIndex = data.index;
|
||||
this.$forceUpdate();
|
||||
},
|
||||
initVideo() {
|
||||
this.isfresh = false;
|
||||
this.$nextTick(() => {
|
||||
this.isfresh = true;
|
||||
setTimeout(() => {
|
||||
this.$refs.commonVideo.init({
|
||||
currentVideo: this.currentVideo,
|
||||
currentVideoList: this.videoArray,
|
||||
});
|
||||
}, 200);
|
||||
});
|
||||
},
|
||||
changeVideo(data) {
|
||||
this.currentVideo = data;
|
||||
this.initVideo();
|
||||
this.isOpenMp3 = false;
|
||||
console.log("data at line 380111111111111111111:", data.type);
|
||||
|
||||
var mynavData = JSON.stringify(data); // 这里转换成 字符串
|
||||
console.log(
|
||||
mynavData,
|
||||
"mynavDatamynavDatamynavDatamynavDatamynavDatamynavDatamynavDatass"
|
||||
);
|
||||
if (data.type == 0 || data.type == 2) {
|
||||
//1 mp4 2 mp3
|
||||
uni.navigateTo({
|
||||
url: `/pages/curriculum/order/curriculum/videoDetail?data=${mynavData}`,
|
||||
});
|
||||
} else if (data.type == 1) {
|
||||
//视频云点播
|
||||
uni.navigateTo({
|
||||
url: `/pages/curriculum/order/curriculum/videoDetailOss?data=${mynavData}`,
|
||||
});
|
||||
}
|
||||
|
||||
// else if (data.type == 2) {
|
||||
// //mp3
|
||||
// this.isOpenMp3 = true;
|
||||
// this.$nextTick(() => {
|
||||
// this.$refs.mp3Detail.init({ data: mynavData });
|
||||
// });
|
||||
// }
|
||||
// var mynavData = JSON.stringify(data); // 这里转换成 字符串
|
||||
|
||||
// if (data.type == 0 || data.type == 2) {
|
||||
// //1 mp4 2 mp3
|
||||
// uni.navigateTo({
|
||||
// url: `/pages/curriculum/order/curriculum/videoDetail?data=${mynavData}`,
|
||||
// });
|
||||
// } else if (data.type == 1) {
|
||||
// //视频云点播
|
||||
// uni.navigateTo({
|
||||
// url: `/pages/curriculum/order/curriculum/videoDetailOss?data=${mynavData}`,
|
||||
// });
|
||||
// }
|
||||
|
||||
// else if (data.type == 2) {
|
||||
// //mp3
|
||||
// this.isOpenMp3 = true;
|
||||
// this.$nextTick(() => {
|
||||
// this.$refs.mp3Detail.init({ data: mynavData });
|
||||
// });
|
||||
// }
|
||||
|
||||
// uni.navigateTo({
|
||||
// // url: '../bookShop/commodityDetail?id=' + item.id
|
||||
@@ -461,6 +419,7 @@ export default {
|
||||
getCourseDescriptionData() {
|
||||
var data = {
|
||||
id: this.options.id,
|
||||
load: false,
|
||||
// id: "16457",
|
||||
};
|
||||
var that = this;
|
||||
@@ -480,6 +439,10 @@ export default {
|
||||
.then(async (res) => {
|
||||
that.curriculumData = res.data.detail;
|
||||
that.videoArray = res.data.videos;
|
||||
if (that.videoArray.length > 0) {
|
||||
this.currentVideo = that.videoArray[0];
|
||||
this.initVideo();
|
||||
}
|
||||
// if (res.obj.correlatedList && res.obj.correlatedList.length > 0) {
|
||||
// this.relatedCoursesList =
|
||||
// res.obj.correlatedList && res.obj.correlatedList.length > 0
|
||||
@@ -912,7 +875,7 @@ export default {
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import '@/style/mixin.scss';
|
||||
@import "@/style/mixin.scss";
|
||||
.u-grid-list {
|
||||
// height: 40rpx;
|
||||
}
|
||||
@@ -932,7 +895,7 @@ export default {
|
||||
}
|
||||
|
||||
.contentBox {
|
||||
height: calc(100% - 50px);
|
||||
height: 100vh;
|
||||
|
||||
.statusList {
|
||||
padding: 10rpx;
|
||||
@@ -1094,7 +1057,6 @@ export default {
|
||||
}
|
||||
|
||||
.commonDetailPage {
|
||||
|
||||
}
|
||||
|
||||
.curriulum_box {
|
||||
@@ -1133,7 +1095,7 @@ export default {
|
||||
.small_class_teaching_box {
|
||||
width: 100%;
|
||||
margin-top: 20rpx;
|
||||
background: #B7E0E2;
|
||||
background: #b7e0e2;
|
||||
|
||||
.small_class_teaching_top {
|
||||
padding: 20rpx 20rpx 0 10rpx;
|
||||
@@ -1182,7 +1144,7 @@ export default {
|
||||
background: #cef8ea;
|
||||
text-align: center;
|
||||
border-radius: 10rpx;
|
||||
box-shadow: 0px 0px 6rpx 0px #E9DCCC;
|
||||
box-shadow: 0px 0px 6rpx 0px #e9dccc;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1290,7 +1252,7 @@ export default {
|
||||
background: #f4fffb;
|
||||
|
||||
border-radius: 10rpx;
|
||||
box-shadow: 0px 0px 6rpx 0px #E9DCCC;
|
||||
box-shadow: 0px 0px 6rpx 0px #e9dccc;
|
||||
}
|
||||
|
||||
.dashang_box {
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
v-if="
|
||||
cateList.length > 0 &&
|
||||
cateList[currentCateIndex].isBuy == 0 &&
|
||||
vip == '0'
|
||||
vip.type == '0'
|
||||
"
|
||||
>
|
||||
<template slot="rightSlot" slot-scope="slotProps">
|
||||
@@ -33,7 +33,8 @@
|
||||
? ''
|
||||
: 'aui-text-danger fdButtonBoxRed'
|
||||
} `"
|
||||
>{{
|
||||
>
|
||||
{{
|
||||
cateList[currentCateIndex].type == 0 ? "开始学习" : "立即购买"
|
||||
}}</text
|
||||
>
|
||||
@@ -41,18 +42,28 @@
|
||||
<view> </view>
|
||||
</template>
|
||||
</u-alert>
|
||||
<u-alert
|
||||
style="position: fixed; width: 100%; z-index: 10"
|
||||
type="warning"
|
||||
@click="handleClickGetGoodsList"
|
||||
:title="`尊贵的VIP会员,您的有效期到 ${vip.endTime.split(' ')[0]}`"
|
||||
:show-icon="true"
|
||||
v-if="cateList.length > 0 && vip.type != 0"
|
||||
>
|
||||
</u-alert>
|
||||
<view
|
||||
v-if="curriculumData.image"
|
||||
:style="`height: auto !important;${
|
||||
cateList.length > 0 &&
|
||||
cateList[currentCateIndex].isBuy == 0 &&
|
||||
vip == '0'
|
||||
(cateList.length > 0 &&
|
||||
cateList[currentCateIndex].isBuy == 0 &&
|
||||
vip.type == '0') ||
|
||||
vip.type != 0
|
||||
? 'padding-top:80rpx'
|
||||
: ''
|
||||
}`"
|
||||
>
|
||||
<image
|
||||
style="width: 100%;"
|
||||
style="width: 100%"
|
||||
:src="curriculumData.image"
|
||||
mode="widthFix"
|
||||
@click="previewImage(curriculumData.image)"
|
||||
@@ -116,7 +127,7 @@
|
||||
type="locked-filled"
|
||||
color="#b0b0b0"
|
||||
size="24"
|
||||
v-if="slotProps.data.isBuy == 0 && vip == '0'"
|
||||
v-if="slotProps.data.isBuy == 0 && vip.type == '0'"
|
||||
style="display: inline-block; margin-left: 10rpx"
|
||||
></uni-icons>
|
||||
</template>
|
||||
@@ -182,7 +193,7 @@
|
||||
|
||||
<text
|
||||
class="fdButtonBox aui-text-success"
|
||||
v-if="slotProps.row.isAudition == 1 && vip == '0'"
|
||||
v-if="slotProps.row.isAudition == 1 && vip.type == '0'"
|
||||
>试听</text
|
||||
>
|
||||
|
||||
@@ -418,7 +429,7 @@ export default {
|
||||
"margin-left": "30rpx",
|
||||
},
|
||||
modalInfo: {},
|
||||
vip: "0",
|
||||
vip: {},
|
||||
|
||||
show: false,
|
||||
playData: {},
|
||||
@@ -510,8 +521,8 @@ export default {
|
||||
getUserInfo() {
|
||||
this.$http.post("common/user/getUserInfo").then((res) => {
|
||||
console.log("res at line 505:", res);
|
||||
if (res.result.vip) {
|
||||
this.vip = res.result.vip;
|
||||
if (res.result.userVip) {
|
||||
this.vip = res.result.userVip;
|
||||
}
|
||||
});
|
||||
},
|
||||
@@ -699,11 +710,11 @@ export default {
|
||||
if (
|
||||
this.cateList[this.currentCateIndex].isBuy == 1 ||
|
||||
v.isAudition == 1 ||
|
||||
this.vip != "0"
|
||||
this.vip.type != "0"
|
||||
) {
|
||||
uni.navigateTo({
|
||||
// url: '../bookShop/commodityDetail?id=' + item.id
|
||||
url: `/pages/curriculum/order/curriculum/detail?navTitle=${v.title}&title=${v.title}&id=${v.id}&conditions=${v.conditions}&detailOid=${v.detailOid}`,
|
||||
url: `/pages/curriculum/order/curriculum/detail?navTitle=${this.options.navTitle}&title=${v.title}&id=${v.id}&conditions=${v.conditions}&detailOid=${v.detailOid}`,
|
||||
});
|
||||
} else {
|
||||
this.$commonJS.showToast("请先购买课程");
|
||||
|
||||
Reference in New Issue
Block a user