Browse Source

排行榜最新,首页以及视频等优化

pansl 1 year ago
parent
commit
cf2a85e7fa

+ 9 - 1
common/apis/index.js

@@ -3,4 +3,12 @@ import http from "../http.js";
 // 获取剧院(首页)
 export const getMiniprogramHall = () => {
 	return http.get('/api/weixin/miniprogram/hall');
-} 
+}
+// 获取最新(首页)
+export const getMiniprogramRecentvideo = () => {
+	return http.get('/api/weixin/miniprogram/recentvideo');
+}
+// 获取排行榜(首页)
+export const getMiniprogramRank = () => {
+	return http.get('/api/weixin/miniprogram/rank');
+}

+ 1 - 1
components/common/tuij.vue

@@ -1,5 +1,5 @@
 <view class="pd16_15">
-				<navigator url="/pages/client/tuan/detail">
+				<navigator url="/pages/video/index">
 				<view class="box pd16_15 flex alcenter mb16">
 					<image class="tuan-product-l"></image>
 					<view class="tuan-product-r pl15">

BIN
duanjuwxmin/icon/index/new.png


BIN
duanjuwxmin/icon/index/phb.png


BIN
duanjuwxmin/icon/index/phb_bg.jpg


BIN
duanjuwxmin/icon/index/zuiju.png


+ 26 - 3
pages.json

@@ -1,6 +1,6 @@
 {
 	"pages": [{
-			"path": "pages/client/index", //默认首页
+			"path": "pages/index/index", //默认首页
 			"style": {
 				// #ifdef H5
 				"navigationStyle": "custom",
@@ -11,6 +11,30 @@
 			}
 		},
 		{
+			"path": "pages/index/new/index",
+			"style": {
+				"navigationBarTitleText": "最新"
+			}
+		},
+		{
+			"path": "pages/index/billboard/index",
+			"style": {
+				"navigationBarTitleText": "排行榜"
+			}
+		},
+		{
+			"path": "pages/video/index",
+			"style": {
+				"navigationBarTitleText": "",
+				"navigationStyle": "custom",
+				"app-plus": {
+					"titleNView": {
+						"type": "transparent"
+					}
+				}
+			}
+		},
+		{
 			"path": "pages/client/zui",
 			"style": {
 				// #ifdef H5
@@ -284,7 +308,6 @@
 					}
 				}
 			}
-
 		},
 		{
 			"path": "pages/client/tuan/info",
@@ -431,7 +454,7 @@
 				"text": "追剧"
 			},
 			{
-				"pagePath": "pages/client/index",
+				"pagePath": "pages/index/index",
 				"iconPath": "static/icon/jy.png",
 				"selectedIconPath": "static/icon/xz_jy.png",
 				"text": "小剧场"

+ 2 - 3
pages/client/components/home/banner.vue

@@ -3,11 +3,10 @@
 		<swiper class="home-swiper-banner" indicator-color="rgba(255, 255, 255, 0.3)" indicator-active-color="#FFFFFF"
 			:indicator-dots="true" :autoplay="true" :interval="3000" :duration="500">
 			<swiper-item v-for="(item,index) in banners" :key="index">
-				<navigator url="#">
-					<image :src="item.banner" style="border-radius: 16rpx;"></image>
+				<navigator :url="'/pages/video/index?video_id='+item.video_id">
+					<image :src="item.banner" mode="scaleToFill" style="border-radius: 16rpx;"></image>
 				</navigator>
 			</swiper-item>
-
 		</swiper>
 	</view>
 </template>

+ 2 - 2
pages/client/components/home/default.vue

@@ -52,10 +52,10 @@
 			// },1000);
 		},
 		methods:{
-			//'/pages/client/tuan/detail?id='+value.id
+			//'/pages/video/index?id='+value.id
 			detail(vid,mid){
 				uni.navigateTo({
-					url:'/pages/client/tuan/detail?vid='+vid+'&mid='+mid
+					url:'/pages/video/index?vid='+vid+'&mid='+mid
 				})
 			},
 			showLoginAct(){

+ 2 - 2
pages/client/components/home/jqjs.vue

@@ -52,10 +52,10 @@
 			// },1000);
 		},
 		methods:{
-			//'/pages/client/tuan/detail?id='+value.id
+			//'/pages/video/index?id='+value.id
 			detail(vid,mid){
 				uni.navigateTo({
-					url:'/pages/client/tuan/detail?vid='+vid+'&mid='+mid
+					url:'/pages/video/index?vid='+vid+'&mid='+mid
 				})
 			},
 			showLoginAct(){

+ 3 - 3
pages/client/tuan/detail(原版模板) .nvue

@@ -266,7 +266,7 @@ export default {
   },
   onShareAppMessage: function(res) {
   	  // #ifdef MP-WEIXIN
-  	  var href='/pages/client/tuan/detail?vid='+this.vid+'&fxpid='+this.uid+'&mid=0'
+  	  var href='/pages/video/index?vid='+this.vid+'&fxpid='+this.uid+'&mid=0'
       console.log(res)
       let that = this;
       const obj = {
@@ -304,7 +304,7 @@ export default {
 	  	});		
 	  },
 	  share(){
-		  var href='/pages/client/tuan/detail?vid='+this.vid+'&fxpid='+this.uid+'&mid=0'
+		  var href='/pages/video/index?vid='+this.vid+'&fxpid='+this.uid+'&mid=0'
 		  // #ifdef H5
 		  uni.setClipboardData({
 		  	data: this.urls+'/h5/#'+href,
@@ -590,7 +590,7 @@ export default {
 			 fxpid=uni.getStorageSync("userinfo").id
 		}
 		uni.navigateTo({
-			url:'/pages/client/tuan/detail?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
+			url:'/pages/video/index?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
 		})
 	},
 	toComment(sss,vid,mid){

+ 33 - 25
pages/client/tuan/detail.nvue

@@ -6,7 +6,7 @@
 		<swiper :style="'width: '+ windowWidth +'px; height:100vh; background-color: #000;'" class="swiper"
 			:circular='false' @change="swiperChange" :current="swiperCurrent" :vertical="true" duration="300">
 			<block v-for="content in videoInfo.updated_episode_num">
-				<swiper-item :key="content" v-if="content">
+				<swiper-item :key="content">
 					<view :style="'width: '+ windowWidth +'px; height:'+heightxw+'vh;'">
 						<video autoplay :key="content" id="myVideo" :controls="controls" :loop="!isplay"
 							:enable-progress-gesture="false" :show-center-play-btn="false" :show-loading="false"
@@ -93,6 +93,7 @@
 						<block v-for="content in labelList[tabcurrent].content">
 							<view class="ju-content" :class="activeIndex ==content?'active':'' "
 								@click="playTest(content)">
+								<!-- <view :class="isShowUpdate(content)?'lock-wrapper-no':'lock-wrapper'" -->
 								<view class="lock-wrapper" v-if="isShowUpdate(content)">
 									<text class="update-title">待更新</text>
 								</view>
@@ -108,7 +109,6 @@
 			</view>
 			<view v-if="fenji==2"
 				:style="'width: '+ windowWidth +'px;height:500px; background-color: #fff; border-top-left-radius: 10px; border-top-right-radius: 10px;'">
-				<u-tabs v-if="fenji==2" :list="list1" @click="click"></u-tabs>
 			</view>
 		</uni-popup>
 	</view>
@@ -186,12 +186,12 @@
 		computed: {
 			isShowVip(item) {
 				return (item) => {
-					return item >= this.videoInfo.charge_sequence && item < this.videoInfo.updated_episode_num
+					return item >= this.videoInfo.charge_sequence && item <= this.videoInfo.updated_episode_num
 				}
 			},
 			isShowUpdate(item) {
 				return (item) => {
-					return item >= this.videoInfo.updated_episode_num
+					return item > this.videoInfo.updated_episode_num
 				}
 			},
 			topTitle() {
@@ -241,7 +241,7 @@
 		},
 		onShareAppMessage: function(res) {
 			// #ifdef MP-WEIXIN
-			var href = '/pages/client/tuan/detail?video_id=' + this.video_id
+			var href = '/pages/video/index?video_id=' + this.video_id
 			console.log(res)
 			let that = this;
 			const obj = {
@@ -281,25 +281,29 @@
 				})
 			},
 			leftClick(e) {
-				uni.showModal({
-					title: '加入追剧',
-					content: '喜欢就加入追剧吧',
-					confirmText: '加入追剧',
-					confirmColor: '#FFA500',
-					cancelText: '不用了',
-					success: (res) => {
-						if (res.confirm) {
-							this.bingewatch()
-							// 用户点击了确定按钮
-							// 执行加入追剧的逻辑
-						} else if (res.cancel) {
-							// 用户点击了取消按钮
-							// 执行取消逻辑
-							uni.navigateBack()
+				if (!this.videoInfo?.is_binge_watch) {
+					uni.showModal({
+						title: '加入追剧',
+						content: '喜欢就加入追剧吧',
+						confirmText: '加入追剧',
+						confirmColor: '#FFA500',
+						cancelText: '不用了',
+						success: (res) => {
+							if (res.confirm) {
+								this.bingewatch()
+								uni.navigateBack()
+								// 用户点击了确定按钮
+								// 执行加入追剧的逻辑
+							} else if (res.cancel) {
+								// 用户点击了取消按钮
+								// 执行取消逻辑
+								uni.navigateBack()
+							}
 						}
-					}
-				});
-				return true
+					});
+				} else {
+					uni.navigateBack()
+				}
 			},
 			myLike(like) {
 				videoEpisodeZan({
@@ -381,7 +385,7 @@
 				console.log('item', item);
 			},
 			share() {
-				var href = '/pages/client/tuan/detail?video_id=' + this.video_id
+				var href = '/pages/video/index?video_id=' + this.video_id
 				// #ifdef H5
 				uni.setClipboardData({
 					data: this.urls + '/h5/#' + href,
@@ -612,7 +616,8 @@
 			padding: 45rpx 68rpx;
 			margin: 6rpx;
 
-			.lock-wrapper {
+			.lock-wrapper,
+			.lock-wrapper-no {
 				position: absolute;
 				width: 100%;
 				height: 100%;
@@ -640,6 +645,9 @@
 				}
 			}
 
+			.lock-wrapper-no {
+				background-color: #f6f6f6;
+			}
 
 			.title {
 				font-size: 16px;

+ 1 - 1
pages/client/tuan/index.vue

@@ -175,7 +175,7 @@
 						 fxpid=uni.getStorageSync("userinfo").id
 					}
 					uni.navigateTo({
-						url:'/pages/client/tuan/detail?id='+id+'&fxpid='+fxpid
+						url:'/pages/video/index?id='+id+'&fxpid='+fxpid
 					})
 				}else if(lx==2){
 					uni.navigateTo({

+ 1 - 1
pages/client/tuan/info.vue

@@ -265,7 +265,7 @@ export default {
 						 fxpid=uni.getStorageSync("userinfo").id
 					}
 					uni.navigateTo({
-						url:'/pages/client/tuan/detail?id='+id+'&mid='+mid+'&fxpid='+fxpid
+						url:'/pages/video/index?id='+id+'&mid='+mid+'&fxpid='+fxpid
 					})
 				}else if(lx==2){
 					uni.navigateTo({

+ 1 - 1
pages/client/tuan/list.vue

@@ -224,7 +224,7 @@ export default {
 						 fxpid=uni.getStorageSync("userinfo").id
 					}
 					uni.navigateTo({
-						url:'/pages/client/tuan/detail?id='+id+'&mid='+mid+'&fxpid='+fxpid
+						url:'/pages/video/index?id='+id+'&mid='+mid+'&fxpid='+fxpid
 					})
 				}else if(lx==2){
 					uni.navigateTo({

+ 1 - 1
pages/client/tuan/share.vue

@@ -29,7 +29,7 @@
 			</view>
 		</view>
 		
-		<navigator url="/pages/client/tuan/detail">
+		<navigator url="/pages/video/index">
 		<view class="box pd16_15 flex alcenter mt24">
 			<image class="tuan-product-l"></image>
 			<view class="tuan-product-r pl15">

+ 1 - 1
pages/client/tuan/ss.vue

@@ -153,7 +153,7 @@
 					 fxpid=uni.getStorageSync("userinfo").id
 				}
 				uni.navigateTo({
-					url:'/pages/client/tuan/detail?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
+					url:'/pages/video/index?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
 				})
 			},
 			onPageChange(e) {

+ 1 - 1
pages/client/tuan/wdxh.vue

@@ -144,7 +144,7 @@
 					fxpid = uni.getStorageSync("userinfo").id
 				}
 				uni.navigateTo({
-					url: '/pages/client/tuan/detail?vid=' + vid + '&mid=' + mid + '&fxpid=' + fxpid
+					url: '/pages/video/index?vid=' + vid + '&mid=' + mid + '&fxpid=' + fxpid
 				})
 			},
 			onPageChange(e) {

+ 1 - 1
pages/client/tuan/zjgk.vue

@@ -54,7 +54,7 @@
 					fxpid = uni.getStorageSync("userinfo").id
 				}
 				uni.navigateTo({
-					url: '/pages/client/tuan/detail?vid=' + vid + '&mid=' + mid + '&fxpid=' + fxpid
+					url: '/pages/video/index?vid=' + vid + '&mid=' + mid + '&fxpid=' + fxpid
 				})
 			}
 		}

+ 1 - 1
pages/client/tuan/zjjl.vue

@@ -162,7 +162,7 @@
 					 fxpid=uni.getStorageSync("userinfo").id
 				}
 				uni.navigateTo({
-					url:'/pages/client/tuan/detail?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
+					url:'/pages/video/index?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
 				})
 			},
 			onPageChange(e) {

+ 1 - 1
pages/client/video.nvue

@@ -286,7 +286,7 @@ export default {
 			 fxpid=uni.getStorageSync("userinfo").id
 		}
 		uni.navigateTo({
-			url:'/pages/client/tuan/detail?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
+			url:'/pages/video/index?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
 		})
 	},
 	toComment(sss,vid,mid){

+ 1 - 1
pages/client/zui copy.vue

@@ -154,7 +154,7 @@
 					 fxpid=uni.getStorageSync("userinfo").id
 				}
 				uni.navigateTo({
-					url:'/pages/client/tuan/detail?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
+					url:'/pages/video/index?vid='+vid+'&mid='+mid+'&fxpid='+fxpid
 				})
 			},
 			linkTo(e){

+ 66 - 64
pages/client/zui.vue

@@ -7,63 +7,65 @@
 						<view class="flex alcenter">
 							<text class="ft16 ftw600 cl-main">最近观看</text>
 						</view>
-						
-						<navigator url="/pages/client/tuan/zjgk">
-							<view class="ft14 cl-notice" v-show="historyList.length >  3" >更多</view>
-							<!-- <view class="ft14 cl-notice" >更多</view> -->
+
+						<navigator url="/pages/client/tuan/zjgk">
+							<view class="ft14 cl-notice" v-show="historyList.length >  3">更多</view>
+							<!-- <view class="ft14 cl-notice" >更多</view> -->
 						</navigator>
-						</view>
 					</view>
-					<view class="mt16 history-box ">
-						<block v-for="(value,key) in historyList" :key="key" v-if="key<3">
-							<view class="history-item-box" @click="detail(value.video_id,value.video_series_sequence)">
-								<image class="history-item-image" :src="value.cover_image"></image>
-								<label class="history-item-title">{{value.name}}</label>
-							</view>
-						</block>
-						<view class="box pb10 history-item-box  history-add-box" @click="goToJuYuan">
-							<image class="add-icon" src="/static/img/zhuiju/add.png"></image>
+				</view>
+				<view class="mt16 history-box ">
+					<block v-for="(value,key) in historyList" :key="key" v-if="key<3">
+						<view class="history-item-box" @click="detail(value)">
+							<image class="history-item-image" :src="value.cover_image"></image>
+							<label class="history-item-title">{{value.name}}</label>
 						</view>
+					</block>
+					<view class="box pb10 history-item-box  history-add-box" @click="goToJuYuan">
+						<image class="add-icon" src="/static/img/zhuiju/add.png"></image>
+					</view>
 
+				</view>
+			</view>
+			<view class="mt24 pd16_15">
+				<view class="flex alcenter space">
+					<view class="flex alcenter">
+						<text class="ft16 ftw600 cl-main">我的追剧</text>
 					</view>
 				</view>
-				<view class="mt24 pd16_15">
-					<view class="flex alcenter space">
-						<view class="flex alcenter">
-							<text class="ft16 ftw600 cl-main">我的追剧</text>
+				<view class="mt16 zuiju-box">
+					<block v-if="zhuijuList.length >  0" v-for="(value,key) in zhuijuList" :key="key">
+						<view class="box pd16_15  mb16 zuiju-box-item">
+							<image @click="detail(value)" class="zuiju-box-item-cover" :src="value.cover_image"></image>
+							<view class="zuiju-box-item-info" @click="detail(value)">
+								<label class="zuiju-box-item-info-title">{{value.name}}</label>
+								<label class="zuiju-box-item-info-juji">看到<span
+										class="guankan">{{value.watch_episode_num}}集</span></label>
+								<label class="zuiju-box-item-info-gx">更新至<span
+										class="update-ji">{{value.updated_episode_num}}集</span></label>
+							</view>
+							<view class="zuiju-box-item-del-box" @click="delzj(value.video_id)">
+								<image class="del-icon" src="../../static/img/zhuiju/delete.png"></image>
+							</view>
 						</view>
-					</view>
-					<view class="mt16 zuiju-box">
-						<block v-if="zhuijuList.length >  0" v-for="(value,key) in zhuijuList" :key="key">
-							<view class="box pd16_15  mb16 zuiju-box-item">
-								<image  @click="detail(value.video_id,value.atch_episode_num)" class="zuiju-box-item-cover" :src="value.cover_image"></image>
-								<view class="zuiju-box-item-info"  @click="detail(value.video_id,value.watch_episode_num)">
-									<label class="zuiju-box-item-info-title">{{value.name}}</label>
-									<label class="zuiju-box-item-info-juji">看到<span class="guankan">{{value.watch_episode_num}}集</span></label>
-									<label class="zuiju-box-item-info-gx">更新至<span class="update-ji">{{value.updated_episode_num}}集</span></label>
-								</view>
-								<view class="zuiju-box-item-del-box"  @click="delzj(value.video_id)">
-									<image class="del-icon" src="../../static/img/zhuiju/delete.png"></image>
-								</view>
-							</view>
-							
-						</block>
-					</view>
-					<view v-if="is_show" class="mt16 zuiju-box-kong">
-						<image src="../../static/img/zhuiju/kong.png"></image>
-						<text class="ft14">暂无追剧</text>
-						<label class="ft16" @click="goToJuYuan()">去追剧</label>
-					</view>
+
+					</block>
+				</view>
+				<view v-if="is_show" class="mt16 zuiju-box-kong">
+					<image src="../../static/img/zhuiju/kong.png"></image>
+					<text class="ft14">暂无追剧</text>
+					<label class="ft16" @click="goToJuYuan()">去追剧</label>
 				</view>
 			</view>
-
 		</view>
+
+	</view>
 	</view>
 </template>
 <script>
 	import {
 		watchRecord,
-		shelfList,
+		shelfList,
 		delShelf
 	} from "@/common/apis/zju.js";
 	export default {
@@ -84,8 +86,8 @@
 				historyList: [],
 				zhuijuList: [],
 				mbgColor: this.$mbgColor,
-				is_show_more: false,
-				is_show:false
+				is_show_more: false,
+				is_show: false
 			}
 		},
 		computed: {
@@ -115,9 +117,9 @@
 			},
 			async getList() {
 				this.historyList = await watchRecord();
-				this.zhuijuList = await shelfList();
-				if(this.zhuijuList.length <  1){
-					this.is_show = 0;
+				this.zhuijuList = await shelfList();
+				if (this.zhuijuList.length < 1) {
+					this.is_show = 0;
 				}
 			},
 			saoma() {
@@ -142,13 +144,9 @@
 				//#endif
 
 			},
-			detail(vid, mid) {
-				var fxpid = 1
-				if (uni.getStorageSync("userinfo")) {
-					fxpid = uni.getStorageSync("userinfo").id
-				}
+			detail(value) {
 				uni.navigateTo({
-					url: '/pages/client/tuan/detail?vid=' + vid + '&mid=' + mid + '&fxpid=' + fxpid
+					url: '/pages/video/index?video_id=' + value.video_id
 				})
 			},
 			linkTo(e) {
@@ -160,12 +158,16 @@
 						url: link
 					})
 				}
-			},async delzj(id){
-				let res =  await delShelf(id);
-				uni.showToast({ title: "删除成功",icon:"none" });	
-				// 更新最近列表数据
-				this.zhuijuList = await shelfList();
-				console.log(res);
+			},
+			async delzj(id) {
+				let res = await delShelf(id);
+				uni.showToast({
+					title: "删除成功",
+					icon: "none"
+				});
+				// 更新最近列表数据
+				this.zhuijuList = await shelfList();
+				console.log(res);
 			},
 			exchange(e) {
 				if (this.isLogin == false) {
@@ -176,11 +178,11 @@
 						url: '/pages/client/integral/exchange?id=' + id
 					})
 				}
-			},
-			goToJuYuan(){
-				uni.switchTab({
-					url: '/pages/client/index'
-				})
+			},
+			goToJuYuan() {
+				uni.switchTab({
+					url: '/pages/index/index'
+				})
 			}
 		},
 	}

+ 190 - 0
pages/index/billboard/index.vue

@@ -0,0 +1,190 @@
+<template>
+	<view>
+		<view class="top">
+			<image class="top-img" mode="scaleToFill" src="@/static/icon/index/phb_bg.jpg"></image>
+			<view class="top-wrapper">
+				<text class="top-title">排行榜</text>
+				<text class="top-content">最后更新于 {{listData.update_time}}</text>
+			</view>
+		</view>
+
+		<view class="flex space" style="display:flex; flex-wrap:wrap; padding: 30upx 30upx 0px 30upx;">
+			<block v-for="(value,key) in listData.data" :key="key">
+				<view class="box pb10 mb15" style="width:31%; border-radius:20rpx;" @click="detail(value)">
+					<image class="integral-mall-goods" mode="aspectFill" :src="value.cover_image"></image>
+					<view class="mt8 plr10 ft14 ftw400 text-center text-over cl-main">{{value.name}}</view>
+				</view>
+			</block>
+		</view>
+		<!-- <uni-load-more :status="status" :content-text="contentText" /> -->
+		<view style="width: 100%; height: 30upx;"></view>
+		<!-- <com-footer model="tuan"></com-footer> -->
+
+	</view>
+</template>
+
+<script>
+	import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
+	import {
+		getMiniprogramRank
+	} from '@/common/apis/index.js'
+	import cellGroup from '../../../uni_modules/uview-ui/libs/config/props/cellGroup';
+	export default {
+		components: {
+			uniLoadMore
+		},
+		data() {
+			return {
+				banners: [],
+				searchValue: '',
+				total: 0,
+				selectIndex: 0,
+				scrollTop: 0,
+				keytext: '',
+				listData: [],
+				last_id: 0,
+				reload: true,
+				status: 'more',
+				contentText: {
+					contentdown: '上拉加载更多',
+					contentrefresh: '加载中',
+					contentnomore: '没有数据了'
+				}
+			}
+		},
+		onLoad(e) {
+			if (e.selectIndex) {
+				this.selectIndex = e.selectIndex * 1
+			}
+			this.status = 'more';
+			this.getList();
+			this.banners = uni.getStorageSync("config").banner
+		},
+		onPageScroll(e) {
+			this.scrollTop = e.scrollTop;
+		},
+		onReachBottom() {
+			this.status = 'more';
+			this.getList();
+		},
+		methods: {
+			detail(value) {
+				uni.navigateTo({
+					url: '/pages/video/index?video_id=' + value.video_id
+				})
+			},
+			getList() {
+				getMiniprogramRank().then(res => {
+					console.log(res, 'getMiniprogramRecentvideogetMiniprogramRecentvideogetMiniprogramRecentvideo')
+					this.listData = res
+				})
+			},
+			getdata() {
+				this.last_id = 0
+				this.reload = true
+				this.getList()
+			},
+			search(res) {
+				this.listData = [];
+				this.last_id = 0;
+				this.keytext = res.value;
+				this.type = '';
+				this.getList(0)
+			},
+			cancel(res) {
+				this.keytext = '';
+				this.type = '';
+				this.getList(0)
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	.top {
+		position: relative;
+
+		.top-img {
+			width: 100%;
+			height: 250rpx;
+		}
+
+		.top-wrapper {
+			display: flex;
+			flex-direction: column;
+			position: absolute;
+			color: #FDF6EC;
+			margin-left: 25rpx;
+			bottom: 20px;
+
+			.top-title {
+				font-size: 36px;
+				font-weight: bolder;
+				margin-bottom: 35rpx;
+				font-family: Georgia, 'Times New Roman', Times, serif;
+			}
+
+			.top-content {
+				font-size: 16px;
+				font-family: Impact, Haettenschweiler, 'Arial Narrow Bold', sans-serif;
+			}
+		}
+	}
+
+
+	.integral-mall-goods {
+		width: 100%;
+		height: 280rpx;
+		object-fit: contain;
+		background: #F2F2F2;
+		border-radius: 16upx;
+	}
+
+	.user-not-vip {
+		width: 100%;
+		height: 80rpx;
+		background: #FDF6EC;
+		border-radius: 40rpx;
+		border: 2rpx solid #EFC381;
+		text-align: center;
+		line-height: 76rpx;
+		font-size: 24rpx;
+		color: #000000;
+		font-weight: bold;
+	}
+
+
+	.tuan-product-l {
+		width: 320rpx;
+		height: 240rpx;
+		border-radius: 16rpx;
+		background: #F2F2F2;
+	}
+
+	.tuan-product-r {
+		width: calc(100% - 320rpx);
+	}
+
+	.search-result {
+		padding-top: 10px;
+		padding-bottom: 20px;
+		text-align: center;
+	}
+
+	.search-result-text {
+		text-align: center;
+		font-size: 14px;
+		color: #666;
+	}
+
+	.example-body {
+		/* #ifndef APP-NVUE */
+		display: block;
+		/* #endif */
+		padding: 0px;
+	}
+
+	.uni-mt-10 {
+		margin-top: 10px;
+	}
+</style>

+ 23 - 200
pages/client/index.vue

@@ -21,30 +21,27 @@
 		</view>
 		<view class="integral-mall-main plr15" style="margin-top: 30upx;">
 			<view class="integal-mall-menu flex pt10 pb10">
-				<view class="col2 text-center" @click="linkTo" data-link="/pages/client/tuan/zjjl">
+				<view class="col2 text-center" @click="linkTo" data-link="/pages/client/zui" data-type='tabbar'>
 					<view>
-						<image style="width: 100rpx; height: 100rpx;" :src="statics.zhuico[0]"></image>
+						<!-- <image style="width: 100rpx; height: 100rpx;" :src="statics.zhuico[0]"></image> -->
+						<image style="width: 100rpx; height: 100rpx;" src="/static/icon/index/zuiju.png"></image>
 					</view>
 					<view class="ft14 ftw600">追剧</view>
 				</view>
-				<view class="col2 text-center bd-left" @click="linkTo" data-link="/pages/client/tuan/ss?selectIndex=3">
+				<view class="col2 text-center bd-left" @click="linkTo" data-link="/pages/index/billboard/index">
 					<view>
-						<image style="width: 100rpx; height: 100rpx;" :src="statics.zhuico[2]"></image>
+						<!-- <image style="width: 100rpx; height: 100rpx;" :src="statics.zhuico[2]"></image> -->
+						<image style="width: 100rpx; height: 100rpx;" src="/static/icon/index/phb.png"></image>
 					</view>
 					<view class="ft14 ftw600">排行</view>
 				</view>
-				<view class="col2 text-center bd-left" @click="linkTo" data-link="/pages/client/tuan/ss">
+				<view class="col2 text-center bd-left" @click="linkTo" data-link="/pages/index/new/index">
 					<view>
-						<image style="width: 100rpx; height: 100rpx;" :src="statics.zhuico[6]"></image>
+						<!-- <image style="width: 100rpx; height: 100rpx;" :src="statics.zhuico[6]"></image> -->
+						<image style="width: 100rpx; height: 100rpx;" src="/static/icon/index/new.png"></image>
 					</view>
 					<view class="ft14 ftw600">最新</view>
 				</view>
-				<!-- <view class="col2 text-center bd-left" @click="linkTo" data-link="/pages/client/tuan/ss?selectIndex=2">
-					<view>
-						<image style="width: 100rpx; height: 100rpx;" :src="statics.zhuico[5]"></image>
-					</view>
-					<view class="ft14 ftw600">免费</view>
-				</view> -->
 			</view>
 			<view class="mt24">
 				<view class="flex alcenter start">
@@ -83,7 +80,6 @@
 					<block v-for="(value,key) in givedata.data" :key="key">
 						<view class="box card" style="width:31%; position: relative; border-radius:20rpx;"
 							@click="detail(value)">
-							<!-- <view class="btn-mini" style="position: absolute; top: 20upx; right: 20upx; border-radius: 10upx;font-size: 18upx;width: 60upx; height: 36upx; z-index: 1;" :style="getBtnStyle">{{value.lxname}}</view> -->
 							<image class="integral-mall-goods" mode="aspectFill" :src="value.cover_image"></image>
 							<view class="mt8 plr10 ft14 ftw400 text-center text-over cl-main">{{value.name}}</view>
 						</view>
@@ -93,7 +89,6 @@
 		</view>
 	</view>
 	<!-- <home-default :datasa="datasa"></home-default> -->
-	<!-- <com-footer model="index"></com-footer> -->
 	</view>
 	</view>
 </template>
@@ -105,30 +100,17 @@
 	export default {
 		data() {
 			return {
-				hyh: 0,
 				navLock: false,
-				datasa: [],
-				listjq: [],
-				listbz: [],
-				showdyxx: true,
-				dataconfig: [],
 				banners: [],
-				datainfo: [],
-				dataindex: [],
 				hotdata: [],
 				givedata: [],
-
 				typetab: [{
-						name: '推荐短剧',
-						id: 1
-					},
-					// {name:'剧情介绍',id:2},
-					// {name:'剧情壁纸',id:3},
-				],
+					name: '推荐短剧',
+					id: 1
+				}, ],
 				selecttype: 0,
 				scrollTop: 0,
 				type: 1,
-
 				mbgColor: this.$mbgColor,
 			}
 		},
@@ -161,25 +143,9 @@
 				}
 			}
 		},
-		onShareAppMessage(e) {
-
-		},
-		onShareTimeline(e) {
-
-		},
-		onLoad(e) {
-			// uni.setStorage({//缓存配置信息
-			// 	key: 'webUrl',  
-			// 	data: this.configs.webUrl
-			// })
-			//this.getList();
-		},
+		onLoad(e) {},
 		onShow() {
 			this.getList();
-			// this.getList(1);
-			// this.getList(2);
-			// this.getList(3);
-			let this_ = this
 		},
 		methods: {
 			changeIndex(index) {
@@ -191,12 +157,7 @@
 				this.selecttype = index;
 			},
 			huanyihuan() {
-				if (this.hyh < 12) {
-					this.hyh = this.hyh + 3
-				}
-				if (this.hyh >= 12) {
-					this.hyh = 0
-				}
+
 			},
 			getList() {
 				getMiniprogramHall().then(res => {
@@ -205,41 +166,6 @@
 					this.hotdata = res.recommend[0]
 					this.givedata = res.recommend[1]
 				})
-				let this_ = this
-				let data = {};
-				// uni.request({
-				// 	url: this.configs.webUrl + '/api/video/indexdata',
-				// 	data: data,
-				// 	success: data => {
-				// 		//console.log(data.data)
-				// 		uni.setStorage({ //缓存配置信息
-				// 			key: 'config',
-				// 			data: data.data.config
-				// 		})
-				// 		this.banners = data.data.config.banner
-				// 		if (data.data.config.name) {
-				// 			uni.setNavigationBarTitle({
-				// 				title: data.data.config.name
-				// 			});
-				// 		}
-				// 		if (data.data.config.mbgColor) {
-				// 			this.mbgColor = data.data.config.mbgColor
-				// 			uni.setNavigationBarColor({
-				// 				frontColor: "#000000",
-				// 				backgroundColor: this_.mbgColor,
-				// 				complete: () => {
-				// 					this.navLock = false;
-				// 				}
-				// 			});
-				// 		}
-				// 		this.listbz = data.data.listbz
-				// 		this.listjq = data.data.listjq
-				// 		this.datasa = data.data.new
-				// 		this.hotdata = data.data.hotdata
-				// 		this.givedata = data.data.givedata
-				// 	},
-				// 	fail: (data, code) => {}
-				// });
 			},
 			saoma() {
 				//#ifdef APP-PLUS  
@@ -264,39 +190,24 @@
 
 			},
 			detail(value) {
-				console.log(value)
-				// if (uni.getStorageSync("userinfo")) {
-				// 	fxpid = uni.getStorageSync("userinfo").id
-				// }
 				uni.navigateTo({
-					url: '/pages/client/tuan/detail?video_id=' + value.video_id
+					url: '/pages/video/index?video_id=' + value.video_id
 				})
 			},
 			linkTo(e) {
-				if (this.isLogin == false) {
-					this.showLogin = true;
-				} else {
-					let link = e.currentTarget.dataset.link;
-					uni.navigateTo({
+				console.log(e, 'linkTolinkTolinkTo')
+				let link = e.currentTarget.dataset.link;
+				let type = e.currentTarget.dataset.type;
+				if (type == 'tabbar') {
+					uni.switchTab({
 						url: link
 					})
-				}
-			},
-			linkTosa(e) {
-				let link = e.currentTarget.dataset.link;
-				uni.navigateTo({
-					url: link
-				})
-			},
-			exchange(e) {
-				if (this.isLogin == false) {
-					this.showLogin = true;
 				} else {
-					let id = e.currentTarget.dataset.id;
 					uni.navigateTo({
-						url: '/pages/client/integral/exchange?id=' + id
+						url: link
 					})
 				}
+
 			},
 		},
 	}
@@ -308,7 +219,7 @@
 		justify-content: start;
 
 		.card {
-			margin: 10px;
+			margin: 6px;
 		}
 	}
 
@@ -319,13 +230,6 @@
 		border-radius: 0rpx 0rpx 48rpx 48rpx;
 	}
 
-	.home-main {
-		width: 100%;
-		position: relative;
-		margin-top: -156rpx;
-		padding: 0 30rpx;
-	}
-
 	.home-mendian {
 		width: 100%;
 		height: 84rpx;
@@ -333,29 +237,6 @@
 		border-radius: 42rpx;
 	}
 
-	.integral-mall-header {
-		position: relative;
-		height: 320rpx;
-	}
-
-	.integral-mall-header .bg {
-		width: 100%;
-		height: 320rpx;
-	}
-
-	.integral-mall-header .main {
-		position: absolute;
-		left: 0;
-		top: 0;
-		width: 100%;
-		height: 320rpx;
-	}
-
-	.swiper-integral {
-		height: 32rpx;
-		width: 100%;
-	}
-
 	.integral-mall-main {
 		position: relative;
 		/* margin-top: -104rpx; */
@@ -368,64 +249,6 @@
 		border-radius: 20rpx;
 	}
 
-	.integral-tuan-l {
-		width: 100%;
-		height: 280rpx;
-		background: #f2f2f2;
-		border-radius: 16rpx;
-	}
-
-
-	.integral-mall-coupon {
-		background: #FFFFFF;
-		position: relative;
-		border-radius: 16rpx;
-		overflow: hidden;
-	}
-
-	.integral-mall-coupon .top {
-		padding: 0rpx 0rpx 24rpx 0rpx;
-		border-bottom: 2rpx dashed #FEC675;
-	}
-
-	.integral-mall-coupon .y-l,
-	.integral-mall-coupon .y-r {
-		width: 20rpx;
-		height: 20rpx;
-		border-radius: 10rpx;
-		background: #F5F6FA;
-		position: absolute;
-		z-index: 2;
-		top: 284rpx;
-	}
-
-	.integral-mall-coupon .y-l {
-		left: -10rpx;
-	}
-
-	.integral-mall-coupon .y-r {
-		right: -10rpx;
-	}
-
-	.integral-mall-coupon .coupon-value {
-		width: 100%;
-	}
-
-	.integral-mall-coupon .coupon-value image {
-		width: 100%;
-	}
-
-	.integral-mall-coupon .coupon-value .num {
-		width: 100%;
-		height: 64rpx;
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		position: absolute;
-		left: 0;
-		top: 0;
-	}
-
 	.integral-mall-goods {
 		width: 100%;
 		height: 280rpx;

+ 150 - 0
pages/index/new/index.vue

@@ -0,0 +1,150 @@
+<template>
+	<view>
+		<view class="flex space" style="display:flex; flex-wrap:wrap; padding: 30upx 30upx 0px 30upx;">
+			<block v-for="(value,key) in listData" :key="key">
+				<view class="box pb10 mb15" style="width:31%; border-radius:20rpx;" @click="detail(value)">
+					<image class="integral-mall-goods" mode="aspectFill" :src="value.cover_image"></image>
+					<view class="mt8 plr10 ft14 ftw400 text-center text-over cl-main">{{value.name}}</view>
+				</view>
+			</block>
+		</view>
+		<!-- <uni-load-more :status="status" :content-text="contentText" /> -->
+		<view style="width: 100%; height: 30upx;"></view>
+		<!-- <com-footer model="tuan"></com-footer> -->
+
+	</view>
+</template>
+
+<script>
+	import uniLoadMore from '@/components/uni-load-more/uni-load-more.vue';
+	import {
+		getMiniprogramRecentvideo
+	} from '@/common/apis/index.js'
+	import cellGroup from '../../../uni_modules/uview-ui/libs/config/props/cellGroup';
+	export default {
+		components: {
+			uniLoadMore
+		},
+		data() {
+			return {
+				banners: [],
+				searchValue: '',
+				total: 0,
+				selectIndex: 0,
+				scrollTop: 0,
+				keytext: '',
+				listData: [],
+				last_id: 0,
+				reload: true,
+				status: 'more',
+				contentText: {
+					contentdown: '上拉加载更多',
+					contentrefresh: '加载中',
+					contentnomore: '没有数据了'
+				}
+			}
+		},
+		onLoad(e) {
+			if (e.selectIndex) {
+				this.selectIndex = e.selectIndex * 1
+			}
+			this.status = 'more';
+			this.getList();
+			this.banners = uni.getStorageSync("config").banner
+		},
+		onPageScroll(e) {
+			this.scrollTop = e.scrollTop;
+		},
+		onReachBottom() {
+			this.status = 'more';
+			this.getList();
+		},
+		methods: {
+			detail(value) {
+				uni.navigateTo({
+					url: '/pages/video/index?video_id=' + value.id
+				})
+			},
+			getList() {
+				getMiniprogramRecentvideo().then(res => {
+					console.log(res, 'getMiniprogramRecentvideogetMiniprogramRecentvideogetMiniprogramRecentvideo')
+					this.listData = res
+				})
+			},
+			getdata() {
+				this.last_id = 0
+				this.reload = true
+				this.getList()
+			},
+			search(res) {
+				this.listData = [];
+				this.last_id = 0;
+				this.keytext = res.value;
+				this.type = '';
+				this.getList(0)
+			},
+			cancel(res) {
+				this.keytext = '';
+				this.type = '';
+				this.getList(0)
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	.integral-mall-goods {
+		width: 100%;
+		height: 280rpx;
+		background: #F2F2F2;
+		border-radius: 16upx;
+	}
+
+	.user-not-vip {
+		width: 100%;
+		height: 80rpx;
+		background: #FDF6EC;
+		border-radius: 40rpx;
+		border: 2rpx solid #EFC381;
+		text-align: center;
+		line-height: 76rpx;
+		font-size: 24rpx;
+		color: #000000;
+		font-weight: bold;
+	}
+
+
+	.tuan-product-l {
+		width: 320rpx;
+		height: 240rpx;
+		border-radius: 16rpx;
+		background: #F2F2F2;
+	}
+
+	.tuan-product-r {
+		width: calc(100% - 320rpx);
+	}
+
+	.search-result {
+		padding-top: 10px;
+		padding-bottom: 20px;
+		text-align: center;
+	}
+
+	.search-result-text {
+		text-align: center;
+		font-size: 14px;
+		color: #666;
+	}
+
+	.example-body {
+		/* #ifndef APP-NVUE */
+		display: block;
+		/* #endif */
+		padding: 0px;
+	}
+
+	.uni-mt-10 {
+		margin-top: 10px;
+	}
+</style>

+ 657 - 0
pages/video/index.nvue

@@ -0,0 +1,657 @@
+<template>
+	<view class="content">
+		<u-navbar :title="topTitle" @leftClick="leftClick" titleStyle="color:#fff;" bgColor="#000" leftIconColor="#fff"
+			:autoBack="false">
+		</u-navbar>
+		<swiper :style="'width: '+ windowWidth +'px; height:100vh; background-color: #000;'" class="swiper"
+			:circular='false' @change="swiperChange" :current="swiperCurrent" :vertical="true" duration="300">
+			<block v-for="content in videoInfo.updated_episode_num">
+				<swiper-item :key="content">
+					<view :style="'width: '+ windowWidth +'px; height:'+heightxw+'vh;'">
+						<video autoplay :key="content" id="myVideo" :controls="controls" :loop="!isplay"
+							:enable-progress-gesture="false" :show-center-play-btn="false" :show-loading="false"
+							:show-fullscreen-btn="false" @ended="ended" @controlstoggle="controlstoggle"
+							@click="tapVides()" :style="'width: '+ windowWidth +'px; height:'+heightxw+'vh;'"
+							:src="currentVideoInfo.video_url" class="tsvideo">
+						</video>
+						<view v-if="isqp" class="userInfo">
+							<!-- 2.点赞 -->
+							<view style="opacity: 0.9; margin-top: 17px;">
+								<image v-if="currentVideoInfo.is_zan" src="@/static/aixinRed.png" @click="myLike(2)"
+									style="width: 40px; height: 40px; position: absolute; right: 6px;"></image>
+								<image v-else src="@/static/aixin.png" @click="myLike(1)"
+									style="width: 40px; height: 40px; position: absolute; right: 6px;"></image>
+								<text
+									style="color: #FFFFFF; margin-top: 5px; font-size: 14px; text-align: center; margin-top: 40px; font-weight: bold;">{{currentVideoInfo.total_zan}}</text>
+							</view>
+							<!-- 3.分享 -->
+							<!-- <view style="opacity: 0.9; margin-top: 17px;">
+							<image src="@/static/share-fill.png"
+								style="width: 40px; height: 40px; position: absolute; right: 5px;"></image>
+							<text
+								style="color: #FFFFFF; margin-top: 5px; font-size: 14px; text-align: center; font-weight: bold; margin-top: 40px;">分享</text>
+							<button open-type="share"
+								style="position: absolute; background: none; width: 100%; height: 100%;"
+								@click.stop="share"></button>
+						</view> -->
+							<!-- 4.追剧 -->
+							<view class="comment" style="opacity: 0.9; margin-top: 17px;">
+								<view v-if="videoInfo.is_binge_watch" @click="unBingewatch">
+									<image src="@/static/scRed.png"
+										style="width: 40px; height: 40px; position: absolute; right: 6px;"></image>
+									<text
+										style="color: #ff0000; margin-top: 5px; font-size: 14px; font-weight: bold; text-align: center; margin-top: 40px;">已追</text>
+								</view>
+								<view v-else @click="bingewatch">
+									<image src="@/static/sc.png"
+										style="width: 40px; height: 40px; position: absolute; right: 6px;"></image>
+									<text
+										style="color: #FFFFFF; margin-top: 5px; font-size: 14px; font-weight: bold; text-align: center; margin-top: 40px;">追剧</text>
+								</view>
+							</view>
+
+						</view>
+						<!-- 最底下的文字部分 -->
+						<view v-if="isqp" class="contentcd" @click.stop="sellxj()">
+							<text class="userName">《{{videoInfo.name}}》</text>
+							<text class="userName">更新到第{{videoInfo.updated_episode_num}}集</text>
+							<text class="userName">|</text>
+							<text class="userName">选集</text>
+						</view>
+					</view>
+				</swiper-item>
+			</block>
+		</swiper>
+		<uni-popup type="bottom" ref="select" style="z-index: 100;">
+			<view v-if="fenji==1" class="pop-my">
+				<view class="ju-top">
+					<view style="display: flex; flex-direction: column; ">
+						<view style="display: flex; flex-direction: column;">
+							<view style="display: flex; flex-direction: column;">
+								<u-tabs v-if="fenji==1" :activeStyle="activeStyle" lineColor="none"
+									:inactiveStyle="inactiveStyle" style="align-items: center; width: 100%;"
+									:list="list1" :current="current" @click="click"></u-tabs>
+								<view class="ju-top-title">
+									{{videoInfo.name}}
+								</view>
+								<view class="ju-top-update"> 已更新至{{videoInfo.updated_episode_num}}集 </view>
+							</view>
+							<u-tabs v-if="fenji==1" :activeStyle="activeStyle" lineColor="none"
+								:inactiveStyle="inactiveStyle" style="align-items: flex-start; width: 100%;"
+								:list="labelList" @click="click"></u-tabs>
+							{{labelList}}
+						</view>
+						<view class="down" @click="down">
+							<text class="down-text">收起</text>
+							<image class="down-img" src="@/static/img/index/down.png">
+							</image>
+						</view>
+					</view>
+				</view>
+				<scroll-view class="scroll-my" :scroll-y="true" :scroll-top="scrollTop">
+					<view class="ju-wrapper">
+						<block v-for="content in labelList[tabcurrent].content">
+							<view class="ju-content" :class="activeIndex ==content?'active':'' "
+								@click="playTest(content)">
+								<!-- <view :class="isShowUpdate(content)?'lock-wrapper-no':'lock-wrapper'" -->
+								<view class="lock-wrapper" v-if="isShowUpdate(content)">
+									<text class="update-title">待更新</text>
+								</view>
+								<text class="title">第{{content}}集 </text>
+								<view class="lock-wrapper" v-if="isShowVip(content)">
+									<image class="lock-img" src="@/static/shilu-login/2.png"></image>
+								</view>
+							</view>
+						</block>
+					</view>
+					<view style="width: 1px; height: 1px; margin-top: 30px;"></view>
+				</scroll-view>
+			</view>
+			<view v-if="fenji==2"
+				:style="'width: '+ windowWidth +'px;height:500px; background-color: #fff; border-top-left-radius: 10px; border-top-right-radius: 10px;'">
+			</view>
+		</uni-popup>
+	</view>
+</template>
+
+
+<script>
+	import {
+		getVideoInfo,
+		videoEpisodePlay,
+		videoEpisodeZan,
+	} from '@/common/apis/video.js';
+	import {
+		delShelf,
+		storeshelf
+	} from '@/common/apis/zju.js'
+	import configs from "@/common/config.js"
+	let audo = uni.createInnerAudioContext('myVideo')
+	export default {
+		data() {
+			return {
+				top_height: 0,
+				episode: 1,
+				swiperCurrent: 0,
+				videoContext: '',
+				currentVideoInfo: {},
+				activeStyle: {
+					color: '#f95d27',
+					fontWeight: 'bold',
+					transform: 'scale(1.05)'
+				},
+				inactiveStyle: {
+					color: '#606266',
+					transform: 'scale(1)'
+				},
+				activeIndex: 0,
+				tabcurrent: 0,
+				videoInfo: {
+					"name": "test1-112",
+					"charge_sequence": 24,
+					"charge_coin": 125,
+					"total_episode_num": 98,
+					"updated_episode_num": 24,
+					"update_type": 1
+				},
+				labelList: [],
+				list1: [{
+					name: '当前剧集',
+				}, {
+					name: '相似好剧',
+				}],
+				sharedata: {
+					type: 2,
+					strShareUrl: "",
+					strShareTitle: "分享标题",
+					strShareSummary: "分享总结",
+					strShareImageUrl: ""
+				},
+				fenji: 0,
+				controls: true,
+				windowWidth: 0,
+				windowHeight: 0,
+				current: 0,
+				isplay: true, //是否自动播放下一个视频
+				duration: 500,
+				isqp: true,
+				urls: configs.webUrl,
+				scrollTop: 0,
+				video_id: 0,
+				safeArea: 0,
+				ttuop: 0,
+				heightxw: 100,
+			};
+		},
+		computed: {
+			isShowVip(item) {
+				return (item) => {
+					return item >= this.videoInfo.charge_sequence && item <= this.videoInfo.updated_episode_num
+				}
+			},
+			isShowUpdate(item) {
+				return (item) => {
+					return item > this.videoInfo.updated_episode_num
+				}
+			},
+			topTitle() {
+				return `${this.videoInfo.name} 第${this.episode}集`
+			}
+		},
+		onReady: function(res) {
+			this.videoContext = uni.createVideoContext('myVideo')
+		},
+		mounted() {
+			this.initTabs();
+			this.initSwiperData(this.swiperCurrent + 1)
+			getVideoInfo({
+				video_id: this.video_id
+			}).then(res => {
+				// console.log(res, 'getVideoInfogetVideoInfogetVideoInfo')
+				this.videoInfo = res
+			})
+		},
+		onLoad(e) {
+			let that = this;
+			uni.getSystemInfo({
+				success(res) {
+					that.top_height = res.statusBarHeight; //data中 声明 top_height:0 
+				}
+			});
+			if (e.video_id) {
+				this.video_id = Number(e.video_id)
+			}
+			uni.getSystemInfo({
+				success: res => {
+					this.safeArea = res.safeAreaInsets.bottom;
+					if (this.safeArea > 0) {
+						this.heightxw = 97
+					}
+				}
+			})
+			// #ifdef MP-TOUTIAO
+			this.ttuop = 64
+			// #endif
+			this.windowWidth = uni.getSystemInfoSync().windowWidth
+			this.windowHeight = uni.getSystemInfoSync().windowHeight - this.safeArea - this.ttuop
+			console.log(this.windowHeight)
+		},
+		onShow() {
+
+		},
+		onShareAppMessage: function(res) {
+			// #ifdef MP-WEIXIN
+			var href = '/pages/video/index?video_id=' + this.video_id
+			console.log(res)
+			let that = this;
+			const obj = {
+				title: "发送给好友",
+				imageUrl: '',
+				path: href,
+				success: function(res) {
+					console.log(res, "转发成功")
+				},
+				fail: function(res) {
+					wx.showToast({
+						title: '发送失败',
+						icon: 'none'
+					})
+				}
+			}
+			return obj
+			// #endif
+		},
+		onBackPress() {},
+		methods: {
+			bingewatch() {
+				storeshelf(this.video_id).then(res => {
+					console.log(res, 'storeshelfstoreshelfstoreshelf')
+					this.videoInfo.is_binge_watch = !Boolean(this.videoInfo.is_binge_watch)
+					uni.showToast({
+						title: '追剧成功',
+						duration: 1000,
+						icon: 'none'
+					});
+				})
+			},
+			unBingewatch() {
+				delShelf(this.video_id).then(res => {
+					console.log(res, 'delShelfdelShelfdelShelfdelShelfdelShelf')
+					this.videoInfo.is_binge_watch = !Boolean(this.videoInfo.is_binge_watch)
+				})
+			},
+			leftClick(e) {
+				if (!this.videoInfo?.is_binge_watch) {
+					uni.showModal({
+						title: '加入追剧',
+						content: '喜欢就加入追剧吧',
+						confirmText: '加入追剧',
+						confirmColor: '#FFA500',
+						cancelText: '不用了',
+						success: (res) => {
+							if (res.confirm) {
+								this.bingewatch()
+								uni.navigateBack()
+								// 用户点击了确定按钮
+								// 执行加入追剧的逻辑
+							} else if (res.cancel) {
+								// 用户点击了取消按钮
+								// 执行取消逻辑
+								uni.navigateBack()
+							}
+						}
+					});
+				} else {
+					uni.navigateBack()
+				}
+			},
+			myLike(like) {
+				videoEpisodeZan({
+					episode_id: this.currentVideoInfo.id,
+					zan: like
+				}).then(res => {
+					console.log(res, 'VideoEpisodeZanVideoEpisodeZanVideoEpisodeZan')
+					this.$nextTick(() => {
+						this.currentVideoInfo.is_zan = !Boolean(this.currentVideoInfo.is_zan)
+						if (this.currentVideoInfo.is_zan) {
+							this.currentVideoInfo.total_zan++
+						} else {
+							this.currentVideoInfo.total_zan--
+						}
+					})
+
+				})
+			},
+			initTabs() {
+				function innit(i, num) {
+					let arr = [];
+					for (i; i <= num; i++) {
+						arr.push(i)
+					}
+					return arr
+				}
+				const pageSize = 15;
+				const total = this.videoInfo.total_episode_num;
+				const pageCount = Math.ceil(total / pageSize);
+				for (let i = 0; i < pageCount; i++) {
+					const start = i * pageSize + 1;
+					const end = i === pageCount - 1 ? total : (i + 1) * pageSize;
+					let label;
+					if (i === pageCount - 1) {
+						if (start === total) {
+							label = `${total}`
+						} else {
+							label = `${start}-${total}`
+						}
+					} else {
+						label = `${start}-${end}`
+					}
+					let index;
+					if (label.split('-')[1]) {
+						index = label.split('-')[1]
+					} else {
+						index = total
+					}
+					this.labelList.push({
+						name: label,
+						page: pageCount,
+						content: innit(start, index)
+					})
+				}
+
+			},
+			playTest(item) {
+				console.log(item)
+				if (this.isShowVip(item)) {
+					this.fenji = 2
+					this.activeIndex = ''
+				} else if (this.isShowUpdate(item)) {
+					this.activeIndex = ''
+					uni.showToast({
+						title: '剧集暂未更新',
+						duration: 1000,
+						icon: 'none'
+					});
+				} else {
+					this.activeIndex = item;
+					this.swiperCurrent = item - 1;
+					this.episode = this.swiperCurrent
+					// this.initSwiperData(item)
+					this.down();
+				}
+			},
+			click(item) {
+				this.tabcurrent = item.index
+				console.log('item', item);
+			},
+			share() {
+				var href = '/pages/video/index?video_id=' + this.video_id
+				// #ifdef H5
+				uni.setClipboardData({
+					data: this.urls + '/h5/#' + href,
+					complete() {
+						uni.showToast({
+							title: "分享连接已复制到剪贴板"
+						})
+					}
+				})
+				// #endif
+				// #ifndef H5
+				uni.share({
+					provider: "weixin",
+					scene: "WXSenceTimeline",
+					type: 0,
+					href: href,
+					title: '分享标题',
+					summary: '分享总结',
+					imageUrl: '',
+					success: function(res) {
+						console.log("success:" + JSON.stringify(res));
+					},
+					fail: function(err) {
+						console.log("fail:" + JSON.stringify(err));
+					}
+				})
+				// #endif
+			},
+			down() {
+				this.$refs.select.close();
+			},
+			sellxj() {
+				this.fenji = 1
+				this.$refs.select.open('bottom');
+				this.$nextTick(() => {
+					let num1 = (this.windowHeight / 1.6) * 0.85;
+					let num2 = num1 / 4.78;
+					this.scrollTop = num2 * Number(this.k);
+				})
+			},
+			tapVideoHover(index, pays) {
+				this.videoContext.play()
+				// this.$refs.select.open('bottom');
+			},
+			tapVides() {
+				this.isqp = !this.isqp
+			},
+			ended() {
+				//console.log('isplay----',this.isplay)
+				// 1.播放当前视频结束时触发,自动切换下一个视频
+				if (this.isplay) {
+					if (this.displayIndex < 2) {
+						this.current = this.displayIndex + 1
+					} else {
+						this.current = 0
+					}
+					this.isqp = true
+					console.log('显示swiper Index:', this.displayIndex)
+				}
+			},
+			/**
+			 * 初始一个显示的swiper数据
+			 * @originIndex  从源数据的哪个开始显示默认0,如从其他页面跳转进来,要显示第n个,这个参数就是他的下标
+			 */
+			initSwiperData(originIndex) {
+				this.isqp = false
+				videoEpisodePlay({
+					video_id: this.video_id,
+					sequence: originIndex
+				}).then(res => {
+					this.currentVideoInfo = res
+					console.log(res, 'getVideoEpisodePlaygetVideoEpisodePlay')
+				})
+			},
+			/**
+			 * swiper滑动时候
+			 */
+			swiperChange(event) {
+				const {
+					current
+				} = event.detail;
+				this.episode = current + 1;
+				this.activeIndex = this.episode;
+				this.initSwiperData(current + 1)
+			},
+			controlstoggle(e) {
+				console.log(e.detail.show);
+			},
+		},
+	};
+</script>
+
+<style lang="scss" scoped>
+	page {
+		background: #000000;
+	}
+
+	.userInfo {
+		position: absolute;
+		z-index: 99;
+		bottom: 30%;
+		right: 10px;
+		width: 100rpx;
+		text-align: center;
+		flex-direction: column;
+
+	}
+
+	.contentcd {
+		background-color: rgba(255, 255, 255, .3);
+		width: 720rpx;
+		z-index: 99;
+		position: absolute;
+		bottom: 70rpx;
+		left: 50%;
+		transform: translateX(-50%);
+		padding: 15rpx;
+		border-radius: 8px;
+		display: flex;
+		flex-direction: row;
+		justify-content: flex-start;
+		align-items: center;
+		color: #ffffff;
+		margin: 0 auto;
+	}
+
+	.userName {
+		color: #fff;
+		font-size: 30rpx;
+		color: #ffffff;
+		margin: 0 6rpx;
+	}
+
+	.tsvideo {
+		animation: showDivAni 2s 1;
+	}
+
+	@keyframes showDivAni {
+		0% {
+			opacity: 0;
+		}
+
+		100% {
+			opacity: 1;
+		}
+	}
+</style>
+
+<style lang="scss" scoped>
+	.down {
+		display: flex;
+		flex-direction: row;
+		width: 60px;
+		height: 30px;
+		margin-top: 5px;
+		position: absolute;
+		right: 0px;
+		top: 50%;
+		transform: translateY(-50%);
+
+		.down-text {
+			font-size: 12px;
+			color: #000;
+		}
+
+		.down-img {
+			width: 35rpx;
+			height: 35rpx;
+			object-fit: contain;
+		}
+	}
+
+	.ju-top {
+
+		// background-color: ;
+		.ju-top-title {
+			font-size: 16px;
+			font-weight: bold;
+			color: #000;
+			margin-top: 9px;
+			height: 22px;
+			margin-left: 20px;
+			// width: '+ (windowWidth*0.6) +' px;
+			overflow: hidden;
+		}
+
+		.ju-top-update {
+			font-size: 12px;
+			color: #000;
+			margin-top: 9px;
+			height: 22px;
+			margin-left: 20px;
+		}
+	}
+
+	.pop-my {
+		background-color: #FFFFFF;
+	}
+
+	.scroll-my {
+		height: 50vh;
+	}
+
+	.ju-wrapper {
+		display: flex;
+		flex-direction: row;
+		flex-wrap: wrap;
+		align-items: center;
+		justify-content: start;
+		width: 100%;
+		height: 100%;
+		background-color: #FFFFFF;
+		// margin: 6rpx;
+
+		.ju-content.active {
+			background-color: #ff7f02;
+		}
+
+		.ju-content {
+			flex-grow: 1;
+			position: relative;
+			border-radius: 12rpx;
+			background-color: #f6f6f6;
+			width: 31%;
+			height: 25rpx;
+			align-items: center;
+			justify-content: center;
+			padding: 45rpx 68rpx;
+			margin: 6rpx;
+
+			.lock-wrapper,
+			.lock-wrapper-no {
+				position: absolute;
+				width: 100%;
+				height: 100%;
+				border-radius: 12rpx;
+				background-color: rgba(0, 0, 0, .3);
+
+				.lock-img {
+					position: absolute;
+					left: 3rpx;
+					top: 50%;
+					transform: translateY(-50%);
+					width: 50rpx;
+					height: 50rpx;
+					margin-left: 20rpx;
+				}
+
+				.update-title {
+					width: fit-content;
+					height: fit-content;
+					border-radius: 8rpx;
+					font-size: 10px;
+					padding: 6rpx;
+					background-color: #868686;
+					color: #fff;
+				}
+			}
+
+			.lock-wrapper-no {
+				background-color: #f6f6f6;
+			}
+
+			.title {
+				font-size: 16px;
+			}
+		}
+	}
+</style>

BIN
static/icon/index/new.png


BIN
static/icon/index/phb.png


BIN
static/icon/index/phb_bg.jpg


BIN
static/icon/index/zuiju.png