liujiaxin il y a 3 mois
Parent
commit
d088e86733
64 fichiers modifiés avec 218 ajouts et 10111 suppressions
  1. 1 1
      manifest.json
  2. 28 25
      pages.json
  3. 0 572
      pages/home/live.vue
  4. 177 358
      pages/home/living.vue
  5. 3 4
      pages/list/index.vue
  6. 0 2234
      pages_no/living - 副本.vue
  7. 0 2141
      pages_no/living.vue
  8. 0 2251
      pages_no/living827.vue
  9. 0 342
      pages_no/payOrder.vue
  10. 0 2141
      pages_no/zuizao.vue
  11. BIN
      static/images/a.jpg
  12. BIN
      static/images/like.png
  13. BIN
      static/images/live/like.png
  14. BIN
      static/images/live/share.png
  15. BIN
      static/images/red_bg.png
  16. BIN
      static/images/red_head.png
  17. BIN
      static/images/red_title.png
  18. BIN
      static/images/share.png
  19. 1 1
      unpackage/dist/dev/mp-weixin/api/home.js
  20. 0 0
      unpackage/dist/dev/mp-weixin/api/live.js
  21. 1 4
      unpackage/dist/dev/mp-weixin/app.json
  22. 0 0
      unpackage/dist/dev/mp-weixin/common/assets.js
  23. 0 0
      unpackage/dist/dev/mp-weixin/common/vendor.js
  24. 1 1
      unpackage/dist/dev/mp-weixin/pages/auth/h5WxLogin.js
  25. 1 1
      unpackage/dist/dev/mp-weixin/pages/auth/loginIndex.js
  26. 0 0
      unpackage/dist/dev/mp-weixin/pages/home/live.js
  27. 0 13
      unpackage/dist/dev/mp-weixin/pages/home/live.json
  28. 0 0
      unpackage/dist/dev/mp-weixin/pages/home/live.wxml
  29. 0 1
      unpackage/dist/dev/mp-weixin/pages/home/live.wxss
  30. 0 0
      unpackage/dist/dev/mp-weixin/pages/home/living.js
  31. 0 0
      unpackage/dist/dev/mp-weixin/pages/home/living.wxml
  32. 0 0
      unpackage/dist/dev/mp-weixin/pages/home/living.wxss
  33. 0 0
      unpackage/dist/dev/mp-weixin/pages/list/index.js
  34. 1 1
      unpackage/dist/dev/mp-weixin/pages/list/index.wxml
  35. 0 0
      unpackage/dist/dev/mp-weixin/pages_no/living827.js
  36. 0 8
      unpackage/dist/dev/mp-weixin/pages_no/living827.json
  37. 0 0
      unpackage/dist/dev/mp-weixin/pages_no/living827.wxml
  38. 0 0
      unpackage/dist/dev/mp-weixin/pages_no/living827.wxss
  39. 0 0
      unpackage/dist/dev/mp-weixin/pages_no/zuizao.js
  40. 0 8
      unpackage/dist/dev/mp-weixin/pages_no/zuizao.json
  41. 0 0
      unpackage/dist/dev/mp-weixin/pages_no/zuizao.wxml
  42. 0 0
      unpackage/dist/dev/mp-weixin/pages_no/zuizao.wxss
  43. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/cart.js
  44. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/confirmCreateOrder.js
  45. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/confirmPackageOrder.js
  46. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/goods.js
  47. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/paymentOrder.js
  48. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/refundOrder.js
  49. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/store.js
  50. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/storeOrder.js
  51. 1 1
      unpackage/dist/dev/mp-weixin/pages_shop/storeOrderDelivery.js
  52. 0 0
      unpackage/dist/dev/mp-weixin/pages_shop/storeOrderRefundSubmit.js
  53. 1 1
      unpackage/dist/dev/mp-weixin/pages_shop/success.js
  54. 0 0
      unpackage/dist/dev/mp-weixin/pages_user/addAddress.js
  55. 1 1
      unpackage/dist/dev/mp-weixin/pages_user/address.js
  56. 1 1
      unpackage/dist/dev/mp-weixin/project.config.json
  57. BIN
      unpackage/dist/dev/mp-weixin/static/images/a.jpg
  58. BIN
      unpackage/dist/dev/mp-weixin/static/images/like.png
  59. BIN
      unpackage/dist/dev/mp-weixin/static/images/live/like.png
  60. BIN
      unpackage/dist/dev/mp-weixin/static/images/live/share.png
  61. BIN
      unpackage/dist/dev/mp-weixin/static/images/red_bg.png
  62. BIN
      unpackage/dist/dev/mp-weixin/static/images/red_head.png
  63. BIN
      unpackage/dist/dev/mp-weixin/static/images/red_title.png
  64. BIN
      unpackage/dist/dev/mp-weixin/static/images/share.png

+ 1 - 1
manifest.json

@@ -115,7 +115,7 @@
     "quickapp" : {},
     /* 小程序特有相关 */
     "mp-weixin" : {
-        "appid" : "wx73f85f8d62769119",
+        "appid" : "wx503cf8ab31f83dd4",
         "libVersion" : "3.4.2",
         "setting" : {
             "urlCheck" : true,

+ 28 - 25
pages.json

@@ -60,18 +60,20 @@
 				}
 			}
 		},
+		// {
+		// 	"path": "pages/home/live",
+		// 	"style": {
+		// 		"navigationBarTitleText": "",
+		// 		"navigationBarTextStyle": "black",
+		// 		"enablePullDownRefresh": false,
+		// 		"navigationStyle": "custom",
+		// 		"app-plus": {
+		// 			"bounce": "none"
+		// 		}
+		// 	}
+		// }, 
+		
 		{
-			"path": "pages/home/live",
-			"style": {
-				"navigationBarTitleText": "",
-				"navigationBarTextStyle": "black",
-				"enablePullDownRefresh": false,
-				"navigationStyle": "custom",
-				"app-plus": {
-					"bounce": "none"
-				}
-			}
-		}, {
 			"path": "pages/games/index",
 			"style": {
 				"navigationBarTitleText": "",
@@ -128,21 +130,22 @@
 					"bounce": "none"
 				}
 			}
-		},
-		{
-			"path" : "pages_no/zuizao",
-			"style" : 
-			{
-				"navigationBarTitleText" : ""
-			}
-		},
-		{
-			"path" : "pages_no/living827",
-			"style" : 
-			{
-				"navigationBarTitleText" : ""
-			}
 		}
+		// {
+		// 	"path" : "pages_no/zuizao",
+		// 	"style" : 
+		// 	{
+		// 		"navigationBarTitleText" : ""
+		// 	}
+		// }
+		// ,
+		// {
+		// 	"path" : "pages_no/living827",
+		// 	"style" : 
+		// 	{
+		// 		"navigationBarTitleText" : ""
+		// 	}
+		// }
 
 
 	],

+ 0 - 572
pages/home/live.vue

@@ -1,572 +0,0 @@
-<template>
-	<view class="live column flex-1">
-		<view class="videolist" v-if="upDown">
-			<view class="vedio">
-				<!-- <view class="p20 textscll">
-					<u-notice-bar :icon="icon" :text="text1" mode="closable" bgColor='rgba(0,0,0,0.7)' color='#fff'
-						style="border-radius: 10rpx;"></u-notice-bar>
-				</view> -->
-				<video id="myVideo" class="videotop" :src="path+livedata.videoUrl" :autoplay="autoplay"
-					:controls='false' :poster='livedata.liveImgUrl' vslide-gesture-in-fullscreen='true'
-					:show-center-play-btn="false"></video>
-			</view>
-			<!-- <view class="popup-video" v-if="!autoplay">
-				<view class="fs36 bold" v-if="livedata.status==1">——直播还未开始——</view>
-				<view class="fs36 bold" v-if="livedata.status==3">——直播已经结束——</view>
-				<view class="fs28 mtb20">了解更多,点击下方联系老师</view>
-				<view class="more" @click="showadd=!showadd">联系老师</view>
-			</view> -->
-		</view>
-		<view class="justify-between align-center bgf" style="border-bottom: #dedede solid 2rpx;">
-			<u-tabs :list="list1" @click="tabClick" inactiveStyle="color:#888"
-				itemStyle='width:120rpx;height: 80rpx;'></u-tabs>
-			<view class="justify-around flex-1 align-center">
-				<view class="reflash" @click="getliving()">刷新</view>
-				<image src='../../static/images/top.png' class="wh48" v-show="upDown" @click="upDown=!upDown"></image>
-				<image src='../../static/images/up-down.png' class="wh48" v-show="!upDown" @click="upDown=!upDown">
-				</image>
-			</view>
-		</view>
-		<view class="talkbox column flex-1 hidden" style="height: 100%;" v-if="acttab==0">
-			<!-- <u-notice-bar :icon="icon2" :text="text2" mode="closable" bgColor='rgba(254,253,235)' color='#FF5C03'
-				style=" height: 30rpx;line-height: 40rpx;"></u-notice-bar> -->
-			<scroll-view enable-flex scroll-y="true" class="talk p20 scrolly flex-1 column"
-				style="width: calc(100% - 40rpx);height: calc(100% - 40rpx);" :scroll-into-view="scrollIntoView">
-				<view class="list justify-start" v-for="(item,index) in talklist" :key="item.index"
-					:id="`list_${index}`" v-show="item.cmd=='sendMsg'">
-					<u-avatar :src="item.avatar" size='30'></u-avatar>
-					<view class=" ml16">
-						<view class="fs24">
-							<text style="color: #3fc69b;
-							transform: scale(0.8);display: inline-block; " 
-							 v-if="item.userId==userinfo.userId&&item.cmd=='sendMsg'">[ 我 ]</text>
-							 <text style="color: #c84e1e;
-							 transform: scale(0.8);display: inline-block;" v-if="item.userType==1">
-							 [ 管理员 ]</text>
-							<text>{{item.nickName}}</text>
-						</view>
-						<view class="talktext bgf p20 mt12">
-							<view class='fs24'>{{item.msg}}</view>
-						</view>
-					</view>
-				</view>
-				<view v-if="showWelcomeMessage" class="welcome-message">
-					<view class="list justify-start" v-for="(item,index) in talklist" :key="item.index"
-						:id="`list_${index}`" v-show="item.cmd=='entry'||item.cmd=='out'">
-						<view class=" ml16">
-							<view class="fs24">
-								 <text style="color: #c84e1e;
-								 transform: scale(0.8);display: inline-block;" v-if="item.userType==1">
-								 [ 管理员 ]</text>
-							</view>
-							<view class="talktext bgf p20 mt12 justify-start">
-								<text style="color: #9e5584;" class="fs24  ">{{item.nickName}} </text>
-								<view class='fs24 flex-1'>{{item.msg}}直播间</view>
-							</view>
-						</view>
-					</view>
-				</view>
-			</scroll-view>
-			<view class="pb90 mb20"></view>
-			<view class="bot_talk bgf">
-				<u-input :placeholder="placeholderText" border="none"
-					customStyle='background:#f1f7f7;padding:12rpx;padding-left:40rpx' v-model="value" shape='circle'
-					></u-input>
-					<!-- :disabled='talkdisabled'></u-input> -->
-				<view class="sent ml20" @click="sendMsg">发送</view>
-			</view>
-		</view>
-		<!-- <view class="answerbox" v-if="acttab==1">
-			问答
-		</view> -->
-		<view class="informationbox" v-if="acttab==1">
-			<view class="p20 bgf m20 radius20">
-				<view v-html="livedata.liveDesc"></view>
-				<view v-show="!livedata.liveDesc">暂无资料</view>
-			</view>
-		</view>
-		<view class="invite-member" @click="addwechat">
-			<image src="../../static/images/wechat.png" class="wh80 weimg"></image>
-			<view class="addwe">加微信</view>
-		</view>
-		<view class="">
-			<u-popup :show="showadd" @close="close" @open="open" round='20rpx' bgColor='#fffee1'>
-				<view class="addchat p20">
-					<view class="u-flex-row-reverse u-flex">
-						<u-icon name="close" size="18" @click="showadd=!showadd"></u-icon>
-					</view>
-					<view class="column align-center">
-						<view class="fs36" style="color: #ff5c03;">扫码添加助教老师</view>
-						<view class="fs28 color6">扫码添加助教老师</view>
-						<view class="p10 mt40" style="border: #ff5c03 solid 2rpx;">
-							<image :src="codeimg" class="wh180" @touchstart="longPress" @touchend="cancelLongPress">
-							</image>
-						</view>
-						<view class="color6 mt20">长按识别二维码</view>
-					</view>
-				</view>
-			</u-popup>
-		</view>
-	</view>
-</template>
-<script>
-	import {
-		getlive,
-		gettextlist
-	} from '@/api/home'
-	
-	// var wsUrl = "ws://live.ylrzcloud.com/socket/app/webSocket";
-	var wsUrl = "ws://192.168.10.170:7114/app/webSocket";
-	var pingpangTimes = null;
-	var initTimes = null;
-	var isSocketOpen = false;
-	var socket = null;
-
-	export default {
-		data() {
-			return {
-				icon: '公告:',
-				icon2: '广播:',
-				text1: '组件功能丰富多端兼容让您快速集成开箱即用',
-				text2: '丰富多端兼容让您快速集成开箱即用',
-				srcAvatar: '',
-				acttab: 0,
-				value: '',
-				talkdisabled: false, //是否禁用
-				placeholderText: "请输入内容",
-				showadd: false,
-				autoplay: true, //自动播放
-				userinfo: '', //用户信息
-				path: 'http://192.168.10.170/dev-api',
-				livedata: {},
-				bufferRate: 0, // 缓冲时间
-				playDuration: 0, //视频播放时间
-				videoContext: '',
-				thistime: uni.$u.timeFormat(new Date(), 'yyyy-mm-dd hh:MM:ss'),
-				codeimg: '',
-				userid: '4',
-				liveId: '5',
-				upDown: true, //是否视频显示隐藏
-				isLongPress: false, // 是否长按
-				timeout: null, // 计时器
-				list1: [{
-						name: '讨论'
-					},
-					// {
-					// 	name: '问答'
-					// },
-					{
-						name: '资料'
-					},
-				],
-				talklist: [],
-				scrollIntoView: '',
-				showWelcomeMessage: false,
-				messageContent: ""
-			}
-		},
-		mounted() {
-			this.initSocket()
-			var that = this;
-			uni.$on('initSocket', () => {
-				that.initSocket()
-			})
-			uni.$on('sendMsg', (item) => {
-				that.sendMsg(item)
-			})
-			uni.$on('closeWebSocket', () => {
-				that.closeWebSocket()
-			})
-			this.getEWechatSdk();
-
-			this.userinfo = JSON.parse(uni.getStorageSync("userInfo"))
-			this.getliving()
-			this.gettalklist()
-		},
-		onReady: function(res) {
-			this.videoContext = uni.createVideoContext('myVideo')
-			// console.log(this.videoContext)
-		},
-		onLoad() {
-
-		},
-		methods: {
-			gettalklist() {
-				const param = {
-					id: this.liveId
-				}
-				gettextlist(param).then(res => {
-					if (res.code == 200) {
-						this.talklist = res.data
-						// console.log(res.data);
-						this.$nextTick(() => {
-							this.scrollIntoView = `list_${this.talklist.length-1}`
-						})
-					}
-				})
-			},
-			longPress() {
-				this.timeout = setTimeout(() => {
-					this.isLongPress = true;
-					// 执行保存图片的操作
-					uni.saveImageToPhotosAlbum({
-						filePath: this.livedata.qwQrCode, // 图片的本地路径或网络路径
-						success: () => {
-							uni.showToast({
-								title: '保存成功'
-							});
-						},
-						fail: () => {
-							uni.showToast({
-								title: '保存失败',
-								icon: 'none'
-							});
-						}
-					});
-				}, 500); // 设置长按的阈值时间,这里是500毫秒
-			},
-			cancelLongPress() {
-				clearTimeout(this.timeout);
-				this.isLongPress = false;
-			},
-			getliving() {
-				this.gettalklist()
-				const param = {
-					id: this.liveId
-				}
-				getlive(param).then(res => {
-					if (res.code == 200) {
-						this.livedata = res.data
-						this.codeimg = res.data.qwQrCode
-						if (this.livedata.status == 2) {
-							this.autoplay = true
-							this.videoContext.seek(this.livedata.nowDuration)
-							// console.log(this.autoplay)
-						} else {
-							this.autoplay = false
-							this.placeholderText = "直播开始才能发言讨论"
-							this.talkdisabled = true
-						}
-						// console.log(this.autoplay)
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none',
-							duration: 2000
-						});
-					}
-				})
-			},
-			addwechat() {
-				this.showadd = !this.showadd
-			},
-			open() {
-
-			},
-			close() {
-				this.showadd = !this.showadd
-			},
-			tabClick(e) {
-				this.acttab = e.index
-				if(e.index==0){
-					this.$nextTick(() => {
-						this.gettalklist()
-					})
-				}
-			},
-			getEWechatSdk() {
-				let eWechatSdk = ''
-				if (/(Android)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'jWeixin'
-				} else if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'wx'
-				} else {
-					eWechatSdk = 'jWeixin'
-				}
-				uni.setStorageSync("wxSdk", eWechatSdk)
-			},
-			closeWebSocket() {
-				if (socket != null) {
-					uni.closeSocket();
-				}
-				clearInterval(pingpangTimes)
-			},
-			reConnect() {
-				var that = this;
-				try {
-					uni.closeSocket();
-				} catch (e) {
-
-				}
-				setTimeout(function() {
-					that.initSocket();
-				}, 10000);
-
-			},
-			initSocket() {
-				var that = this;
-				// console.log("initSocket")
-				//创建一个socket连接
-				socket = uni.connectSocket({
-					// url: wsUrl+"?userId=40486&liveId=2",
-					// url: wsUrl + "?userId=" + this.userid + "&liveId=" + 
-					// this.liveId+"&AppToken="+'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiJ9.eyJzdWIiOiI0IiwiaWF0IjoxNzQwNzIxMDQ1LCJleHAiOjE3NDEzMjU4NDV9.PgS83JTMSJgVFD6vGAhUsEPbS6Az4yMyX8wVug61TZNTB3092CtvANo-AB9ZG4NdSBLgLrf4litM3vvTk-FK0g',
-					
-					url: wsUrl + "?userId=666"+ "&liveId=777" +"&AppToken="+'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiJ9.eyJzdWIiOiI2NjYiLCJpYXQiOjE3NTE4NzQ0NzEsImV4cCI6MTc4MzQxMDQ3MX0.3uxTTb0qXygmaY9ItovMclxJCNhNEi6kFEqmfLGg4lP2PYzCPODsVjW4PjXNu6EYsl5eYyESltHWcwBnaNkilQ&signature=ff21bfb41ddd5f2e31d6f5bf32ec565aab9c518614d139fa26727468ce701237&userType=0&timestamp=666',
-					multiple: true,
-					success: res => {
-						//先确保清除了之前的心跳定时器
-						clearInterval(pingpangTimes)
-						uni.onSocketMessage((res) => {
-							const redata = JSON.parse(res.data);
-							// console.log(redata)
-							// console.log(111,this.talklist)
-							this.talklist.push(redata.data)
-							this.$nextTick(() => {
-								this.scrollIntoView = `list_${this.talklist.length-1}`
-							})
-							// console.log(222,this.talklist)
-							// console.info(redata)
-							if (redata.cmd == 'deleteId') {
-								uni.$emit('deleteId');
-							} else if (redata.cmd == 'init') {
-								uni.$emit('init', redata.data);
-							} else if (redata.cmd == 'reload') {
-								uni.$emit('reload');
-							} else if (redata.cmd == 'sendStatus') {
-								uni.$emit('sendStatus', redata.data);
-							}else if (redata.data.cmd == 'entry') {
-								this.showWelcomeMessage=true
-								uni.$emit('entry', redata.data);
-								console.log(redata.data)
-							}
-
-						})
-					},
-					error: res => {
-						uni.$emit('websocket', 0);
-						// console.log(res)
-					},
-				})
-				//监听socket打开
-				uni.onSocketOpen(() => {
-					isSocketOpen = true
-					console.log('WebSocket连接已打开!!');
-					// uni.$emit('websocket',1);
-					uni.showToast({
-						title: "插件已打开",
-						icon: 'none',
-					});
-				})
-				//监听socket关闭
-				uni.onSocketClose(() => {
-					isSocketOpen = false
-					clearInterval(pingpangTimes)
-					console.log('WebSocket连接已关闭!');
-					// uni.$emit('websocket',0);
-					uni.showToast({
-						title: "插件离线",
-						icon: 'none',
-					});
-					//重连
-					that.reConnect()
-				})
-				//监听socket错误
-				uni.onSocketError(() => {
-					isSocketOpen = false
-					clearInterval(pingpangTimes)
-					console.log('WebSocket连接打开失败');
-					// uni.$emit('websocket',0);
-					uni.showToast({
-						title: "插件离线",
-						icon: 'none',
-					});
-					uni.showModal({
-						content: '聊天连接失败是否重新尝试连接',
-						success() {
-							that.reConnect()
-						}
-					})
-				})
-			},
-			sendMsg() {
-				if (isSocketOpen) {
-					const data = {
-						liveId: this.livedata.liveId,
-						userId: this.userinfo.userId,
-						userType: 0,
-						cmd: "sendMsg",
-						msg: this.value,
-						nickName: this.userinfo.nickName,
-						avatar: this.userinfo.avatar
-					}
-					if(this.value==""){
-						uni.showToast({
-							title: "不能发送空消息",
-							icon: 'none',
-							
-						});
-					}else{
-						socket.send({
-							data: JSON.stringify(data),
-							success: () => {
-								// this.gettalklist()
-								console.log("发送成功")
-								this.value = ''
-							},
-							fail: () => {
-								console.log("发送失败")
-							}
-						})
-					}
-				}
-			},
-			
-		}
-	}
-</script>
-<style lang="scss" scoped>
-	.welcome-message {
-	  position: fixed;
-	  width: 100%;
-	  bottom: 120rpx;
-	  left: 50%;
-	  transform: translateX(-50%);
-	  color: #666;
-	  padding: 10px 20px;
-	  border-radius: 20px;
-	  animation: fadeOut 1s ease 1s forwards; /* 1秒后开始淡出 */
-	  z-index: 1000;
-	}
-	
-	@keyframes fadeOut {
-	  from { opacity: 1; }
-	  to { opacity: 0; }
-	}
-	.live {
-		height: 100%;
-		overflow: hidden;
-	}
-
-	.list {
-		width: 80%;
-		margin-bottom: 20rpx;
-		animation: xxxawdawd .2s;
-	}
-
-	@keyframes xxxawdawd {
-		from {
-			margin-top: 0rpx;
-			opacity: 0;
-		}
-
-		to {
-			margin-top: 20rpx;
-			opacity: 1;
-		}
-	}
-
-	.vedio {
-		height: 500rpx;
-		width: 100%;
-		background-color: rgba(0, 0, 0, 0.6);
-		position: relative;
-	}
-
-	.videotop {
-		width: 100%;
-		height: 100%;
-	}
-
-	.popup-video {
-		position: absolute;
-		top: 0;
-		height: 500rpx;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		justify-content: center;
-		width: 100%;
-		color: #fff;
-		background-color: rgba(0, 0, 0, 0.6);
-
-		.more {
-			background-color: #3280fe;
-			border-radius: 80rpx;
-			width: 280rpx;
-			text-align: center;
-			height: 60rpx;
-			line-height: 60rpx;
-		}
-	}
-
-	.textscll {
-		position: absolute;
-		top: 0;
-		z-index: 999;
-	}
-
-	.reflash {
-		border: 2rpx solid #888;
-		border-radius: 80rpx;
-		padding: 4rpx 16rpx;
-		color: #888;
-	}
-
-	.talktext {
-		border-radius: 8rpx;
-
-		view {
-			width: 100%;
-		}
-	}
-
-	.bot_talk {
-		width: calc(100% - 40rpx);
-		display: flex;
-		justify-content: space-between;
-		align-items: center;
-		position: fixed;
-		bottom: 0;
-		padding: 20rpx;
-
-		.sent {
-			width: 120rpx;
-			text-align: center;
-			height: 60rpx;
-			line-height: 60rpx;
-			background-color: #3280fe;
-			color: #fff;
-			border-radius: 40rpx;
-			font-size: 24rpx;
-		}
-	}
-
-	.invite-member {
-		height: 55px;
-		width: 50px;
-		position: fixed;
-		bottom: 80px;
-		right: 10px;
-		cursor: pointer;
-
-		.weimg {
-			position: relative;
-		}
-
-		.addwe {
-			position: absolute;
-			left: -7%;
-			bottom: 4rpx;
-			color: #fff;
-			background-color: #fc285c;
-			font-size: 24rpx;
-			border-radius: 20rpx;
-			padding: 4rpx 12rpx;
-		}
-	}
-
-	.addchat {
-		height: 450rpx;
-	}
-</style>

Fichier diff supprimé car celui-ci est trop grand
+ 177 - 358
pages/home/living.vue


+ 3 - 4
pages/list/index.vue

@@ -4,7 +4,7 @@
 			:down="downOption" :up="upOption">
 			<view class="list">
 				<view class="list-item" @click="goLive(item)" v-for="(item,index) in list" :key="index">
-					<image v-if="item.liveImgUrl" :src="item.liveImgUrl"></image>
+					<!-- <image v-if="item.liveImgUrl" :src="item.liveImgUrl"></image> -->
 					<!-- 直播流 -->
 					<video v-if=" item.liveType == 1 && item.flvHlsUrl" :id="'myVideo_' + item.liveId"
 						:src="item.flvHlsUrl" :autoplay="false" muted  :controls="false" object-fit="contain"
@@ -259,13 +259,13 @@
 
 				let data = {
 					pageSize: pageSize,
-					page: pageNum,
+					pageNum: pageNum,
 				}
 
 				liveList(data).then(res => {
 					if (res.code == 200) {
 						let curPageData = res.rows || [];
-						console.log("curPageData在这里>>>>", curPageData)
+						// console.log("curPageData在这里>>>>", res)
 						let totalSize = res.total || 0;
 
 						// 预处理数据,添加状态字段
@@ -282,7 +282,6 @@
 						}
 
 						this.list = this.list.concat(curPageData);
-						console.log("list在这里>>>>", list)
 						// DOM更新后初始化视频观察器
 						this.$nextTick(() => {
 							this.initAllVideoObservers();

+ 0 - 2234
pages_no/living - 副本.vue

@@ -1,2234 +0,0 @@
-<template>
-	<view class="swiper-wrapper">
-		<swiper class="swiper-container" :current="currentSwiperIndex" :circular="false" vertical
-			@change="onSwiperChange" :style="{height: '100vh'}" :duration="300">
-			<swiper-item v-for="(liveItem, index) in list" :key="liveItem.liveId">
-				<view class="container" :class="{active: currentSwiperIndex === index}">
-					<!-- 原有直播间内容结构保持不变 -->
-					<view class="blackbg"></view>
-					<view class="content">
-						<!-- 页面内容 -->
-						<view style=" position: fixed;top: 0;z-index: 5;" class="content-top">
-							<view class="u-flex-y-center">
-								<image @click="goBack" style="width: 60rpx;height: 64rpx;margin-right: 26rpx;"
-									src="@/static/images/live/return.png"></image>
-								<view class=" align-center"
-									style="padding: 6rpx 4rpx;height: 64rpx;background: rgba(0,0,0,0.5);border-radius: 32rpx;">
-									<u-avatar :src="liveItem.liveImgUrl||$img.logo" size="32"></u-avatar>
-									<view class="colorf" style="margin-left: 8rpx;">
-										<view>{{liveItem.liveName?truncateString(liveItem.liveName,5):"未命名"}}</view>
-										<view style="font-size: 16rpx;">
-											{{ liveItem.liveViewData?.follow || liveItem.liveViewData?.follow === 0 ? liveItem.liveViewData.follow : 0 }}位粉丝
-										</view>
-									</view>
-									<view v-if="liveItem.isFollow" @click="onFollow(liveItem)" class="follow-btn ml20">
-										关注</view>
-									<view v-else @click="onFollow(liveItem)" class="follow-btn ml20">已关注</view>
-								</view>
-							</view>
-							<view class="u-flex-end align-center" @click="showadd=!showadd">
-								<image class="w52 h52 mr4" v-for="(item,viewerIndex) in liveItem.filteredViewers"
-									:key="viewerIndex" style="border-radius: 26rpx;" :src="item.avatar||$img.logo">
-								</image>
-								<view class="sum">{{liveItem.liveUserTotal||0}}</view>
-							</view>
-						</view>
-
-						<!-- 页面内容 -->
-						<view style=" position: fixed;top:100rpx;left: 0rpx; z-index: 5;" class="content-top">
-							<view class="u-flex-y-center">
-								<image @click="onRed(liveItem)" v-if="liveItem.redInfo?.redStatus==1"
-									style="width: 70rpx;height: 70rpx;" src="@/static/images/hongbao.png"></image>
-							</view>
-						</view>
-
-						<!-- 右边的 -->
-						<view :class=" liveItem.showType==1 ? 'siderow-group' : 'side-group'">
-							<view class="side-item">
-								<image @click="onLike(liveItem)" src="/static/images/live/like.png"></image>
-								<view>{{liveItem.liveViewData?.like||0}}</view>
-							</view>
-							<view class="side-item">
-								<image @click="goStore(liveItem)" src="/static/images/live/shop.png"></image>
-								<view>店铺</view>
-							</view>
-
-							<view class="side-item">
-								<button open-type="share">
-									<image src="/static/images/live/share.png" mode="widthFix"></image>
-								</button>
-								<view>分享</view>
-							</view>
-						</view>
-
-						<view class="shop-prompt u-flex-y-center"
-							v-if="liveItem.showPurchasePrompt&&liveItem.orderUser?.count">
-							<image class="w32 h32 mr8" src="/static/images/live/shopping.png"></image>
-							<text> {{liveItem.orderUser.userName ? maskString(liveItem.orderUser.userName) : ''}} 等
-								{{liveItem.orderUser.count || 0}}
-								人正在去购买</text>
-						</view>
-
-						<!-- object-fit:fill; -->
-						<view class="videolist " style="margin: auto 0">
-							<view class="video" style="height:100vh">
-								<!-- 修改video组件以支持HLS -->
-								<!-- showType 1 横屏   2 竖屏 -->
-								<video v-if="liveItem.livingUrl" :id="'myVideo_' + liveItem.liveId"
-									:class="liveItem.showType == 1 ? 'video_row' : 'videotop'" :src="liveItem.livingUrl"
-									:autoplay="currentSwiperIndex === index" :controls='false' object-fit='contain'
-									:custom-cache="false" :enable-progress-gesture="false"
-									vslide-gesture-in-fullscreen='true' :show-center-play-btn="false"
-									:http-cache="false" @error="videoError">
-								</video>
-
-								<video v-if="liveItem.videoUrl"
-									:class="liveItem.showType == 1 ? 'video_row' : 'videotop'" :src="liveItem.videoUrl"
-									:autoplay="currentSwiperIndex === index" :controls='false' object-fit='contain'
-									:custom-cache="false" :enable-progress-gesture="false"
-									vslide-gesture-in-fullscreen='true' :show-center-play-btn="false"
-									:http-cache="false" loop @error="videoError">
-								</video>
-
-								<!-- 加载提示 -->
-								<view v-if="liveItem.loading" class="loading-tip">
-									<u-loading mode="circle" color="#ffffff" size="36"></u-loading>
-									<text class="loading-text">加载中...</text>
-								</view>
-							</view>
-						</view>
-						<view class="pb40  mt90" style="position: fixed;bottom: 0;">
-							<view class="w100 h300 mt20">
-								<scroll-view enable-flex scroll-y="true" class="talk p20 scrolly flex-1 column"
-									style="width: calc(100% - 40rpx);height: calc(100% - 40rpx);"
-									:scroll-into-view="liveItem.scrollIntoView">
-									<view>
-										<view class="list justify-start" v-for="(item,talkIndex) in liveItem.talklist"
-											:key="talkIndex" v-show="item.cmd=='announcement'">
-											<view class="talk-list ml16 justify-start">
-												<view class="fs24">
-													<text class='fs24 colorf'>
-														{{item.msg}}直播间{{liveItem.messageContent}}</text>
-												</view>
-											</view>
-										</view>
-									</view>
-
-									<view class="list justify-start" v-for="(item,talkIndex) in liveItem.talklist"
-										:key="talkIndex" :id="`list_${talkIndex}`"
-										v-show="item.cmd!='red'&&item.cmd!='out'&&item.cmd!='entry'">
-										<view class="talk-list ml16 justify-start">
-											<view class="fs24">
-												<text style="color: #FFDA73;">{{item.nickName}}:</text>
-												<text class='fs24 colorf'>{{item.msg}}</text>
-											</view>
-										</view>
-									</view>
-									<view v-if="liveItem.showWelcomeMessage" class="welcome-message">
-										<view class="list justify-start" v-for="(item,talkIndex) in liveItem.talklist"
-											:key="talkIndex" v-show="item.cmd=='entry'||item.cmd=='out'">
-											<view class="talk-list ml16 justify-start">
-												<view class="fs24">
-													<text style="color: #ff89d6;">{{item.nickName}} </text>
-													<text class='fs24 colorf'>
-														{{item.msg}}直播间{{liveItem.messageContent}}</text>
-												</view>
-											</view>
-										</view>
-									</view>
-								</scroll-view>
-							</view>
-
-							<view class="justify-between p24">
-								<view class="u-flex-y-center"
-									style="background:rgba(157, 157, 157, 0.8);padding:18rpx 14rpx 18rpx 32rpx;width: 526rpx;box-sizing:border-box;border-radius:36rpx;">
-									<u-input :placeholder="liveItem.placeholderText" border="none"
-										customStyle='font-size:24rpx;' v-model="liveItem.value" shape='circle'
-										color='#fff' placeholderStyle='color:#e7e7e7' class="ml20"
-										@keydown.enter="sendMsg(liveItem)" @confirm="sendMsg(liveItem)">
-									</u-input>
-								</view>
-								<view class="justify-between mr30  align-center">
-									<view class="icon-bg ml20" @click="liveItem.shopping=!liveItem.shopping">
-										<image src="/static/images/shopping.png" class="w48 h48"></image>
-									</view>
-									<view class="icon-bg ml20" @click="liveItem.showziliao=!liveItem.showziliao">
-										<image src="/static/images/more-icon.png" class="w48 h48"></image>
-									</view>
-								</view>
-							</view>
-						</view>
-					</view>
-
-					<!-- 弹窗组件保持不变 -->
-					<u-popup :show="showadd" @close="close" @open="openViews" round='20rpx' bgColor='#ffffff'>
-						<view class="view-box">
-							<view class="t-c fs30">在线观众</view>
-							<scroll-view scroll-y class="scroll-content" :style="{height: scrollHeight + 'px'}"
-								@scrolltolower="handleScrollToLower">
-								<view class="fs24 u-flex-y-center mb20" v-for="(item,index) in liveViewers"
-									:key="index">
-									<view
-										:style="{color: index === 0 ? '#FF3B30' : index === 1 ? '#FF9500' : index === 2 ? '#FFCC00' :  '#8E8E93',fontWeight: index < 3 ? 'bold' : 'normal',width: '50rpx'}"
-										class="mr10">{{index+1}}</view>
-									<u-avatar :src="item.avatar||$img.logo" size="32"></u-avatar>
-									<text class="ml16">{{item.nickName||"未命名"}}</text>
-								</view>
-								<view class="no-more" v-if="viewNoMoreData && liveViewers.length > 0">
-									<text>没有更多了</text>
-								</view>
-							</scroll-view>
-						</view>
-					</u-popup>
-
-					<u-popup :show="shopping" @close="closeShop" @open="openShop" round='20rpx' bgColor='f3f5f9'>
-						<view class="shoppop">
-							<view class="shoppop-top">
-								<u-avatar :src="store.logoUrl" size="36" class="ml16"></u-avatar>
-								<view class="search-input u-flex-y-center">
-									<image style="width: 24rpx;height: 24rpx;margin-right: 16rpx;"
-										src="@/static/images/search.png">
-									</image>
-									<input placeholder="请搜索商品" v-model="inputInfo" @input="handleSearchInput" />
-								</view>
-								<view class="t-c search-top" style="margin-right: 48rpx;">
-									<image @click="onStoreCollect" v-if="store.isFavorite"
-										style="width: 32rpx;height: 32rpx;" src="@/static/images/collect_select.png">
-									</image>
-									<image v-else @click="onStoreCollect" style="width: 32rpx;height: 32rpx;"
-										src="@/static/images/collect.png"></image>
-									<view>收藏</view>
-								</view>
-								<view class="t-c search-top" @click="goOrderList">
-									<image style="width: 32rpx;height: 32rpx;" src="@/static/images/order.png"></image>
-									<view>订单</view>
-								</view>
-							</view>
-
-							<scroll-view enable-flex scroll-y class="shop-list" :style="{ height: boxHeight + 'px' }">
-								<view class="list-item " v-for="(item,index) in products" :key="index">
-									<view class="goods-img">
-										<image :src="item.imgUrl" mode="widthFix"></image>
-										<view class="goods-label">{{index+1}}</view>
-									</view>
-									<view class="goods-right">
-										<view class="goods-title">{{item.productName}}</view>
-										<view class="goods-people">{{item.sales}} 人已购</view>
-										<view class="goods-shop">
-											<text class="nummber"><text
-													style="font-size: 20rpx;font-weight: 600;">¥</text><text
-													style="font-size: 36rpx;font-weight: bold;">{{Math.trunc(item.price)}}</text>.{{getPureDecimal(item.price)?getPureDecimal(item.price):'00'}}/日</text>
-											<view class="btn-group  u-flex-y-center">
-												<view class="collect-btn">
-													<image v-if="item.isFavorite" @click="onGoodsCollect(item)"
-														style="width: 32rpx;height: 32rpx;"
-														src="/static/images/collect_select.png">
-													</image>
-													<image v-else @click="onGoodsCollect(item)"
-														style="width: 32rpx;height: 32rpx;"
-														src="/static/images/collect.png">
-													</image>
-												</view>
-												<view v-if="item.status==1" class="shop-btn"
-													@click="goShop(item.productId,item.goodsId)">去购买
-												</view>
-												<view v-else-if="item.status==0" @click="goShop(item.productId)"
-													class="shop-btn">
-													已下架</view>
-											</view>
-										</view>
-									</view>
-								</view>
-							</scroll-view>
-						</view>
-					</u-popup>
-				</view>
-			</swiper-item>
-		</swiper>
-	</view>
-</template>
-
-<script>
-	import Hls from 'hls.js';
-	import CryptoJS from 'crypto-js'
-	import {
-		liveList
-	} from '@/api/list'
-	import {
-		liveRed, // 点击领红包
-		liveDataLike, // 点赞
-		collectStore, // 店铺收藏/取消收藏
-		collectGoods, // 商品收藏/取消收藏
-		store, // 查询店铺
-		follow, // 关注/取消关注
-		watchUserList, //获取直播间用户(展示在线用户)
-		liveMsg, //获取最近聊天记录
-		// 小黄车
-		liveStore, //店铺展示,
-		// liveGoodsDetail, //商品详情,
-		liveOrderUser, //正在购买
-		getLiveInfo, //获取直播间信息接口
-		getLiveViewData //直播间点赞、关注、在线人数数据
-	} from '@/api/live'
-	import {
-		liveOrderList, // 订单列表
-	} from '@/api/order'
-
-	import parse from '../../uni_modules/uview-plus/libs/config/props/parse';
-	import {
-		LiveWS
-	} from '@/utils/liveWS.js'
-	import {
-		getlive,
-		// gettextlist,
-		getAnswerlist,
-		submitAnswer
-	} from '@/api/home'
-	// var wsUrl = "ws://192.168.10.166:7114/app/webSocket";
-
-	// var wsUrl = "ws://192.168.10.166:7114/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.125:7114/app/webSocket"; //涂小龙
-	var wsUrl = "wss://live.test.ylrztop.com/ws/live-api/app/webSocket"; //余红奇
-	var wsUrl = "ws://192.168.10.166:7114/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.125:7114/app/webSocket"; //涂小龙
-	// var wsUrl = "ws://live.test.ylrztop.com/prod-api/app/webSocket"; //余红奇
-	// var wsUrl = "ws://nd383294.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://v56c9b8e.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.170:7114/app/webSocket"; //陈果
-	// var wsUrl = "ws://live.ylrzcloud.com/socket/app/webSocket";
-	var pingpangTimes = null;
-	var initTimes = null;
-	var isSocketOpen = false;
-	var socket = null;
-
-	export default {
-		data() {
-			return {
-				socketInstances: {}, // 存储每个直播间的WebSocket实例
-				currentSwiperIndex: 0,
-				preloadCount: 2, // 预加载前后各2个直播间
-				maxSocketConnections: 5, // 最大连接数限制
-				activeSockets: 0, // 当前活跃连接数
-
-
-				list: [], // 直播间列表
-				preloading: false, // 预加载状态
-
-
-				liveUserTotal: null,
-				viewPageSize: 10, // 每页数量
-				viewPageNum: 1, // 当前页码
-				viewLoading: false, // 是否正在加载
-				viewNoMoreData: false, // 是否没有更多数据
-				scrollHeight: 0,
-				scrollTimer: null, // 滚动防抖定时器
-
-
-				socketInstance: null, // 统一管理 socket 实例
-				reconnectCount: 0,
-				maxReconnectAttempts: 3,
-				isManualClose: false, // 标记是否手动关闭
-
-				showRed: true,
-				redInfo: {},
-				inputInfo: '',
-				searchTimer: null,
-				storeId: null,
-				reconnectTimer: null,
-				isCollect: false,
-				showPurchasePrompt: false,
-				purchasePromptTimer: null,
-				prevOrderCount: 0, // 用于记录上一次的购买人数
-				videoUrl: null,
-				showType: 1, //横屏1 竖屏2
-				boxHeight: 300, //小黄车高度
-				isFollow: true,
-				liveViewData: {},
-				liveViewers: [], //观众
-				likeName: 0,
-				hlsPlayer: null, // HLS播放器实例,
-				livingUrl: "",
-				products: {},
-				store: {},
-				orderUser: {}, //正在购买
-				userType: 0,
-				timestamp: '',
-				liveId: null,
-				// userId: uni.getStorageSync("userInfo.userId"),
-				placeholderText: '说点什么...',
-				isZoom: false, //点赞按钮控制是否放大
-				userinfo: '', //用户信息
-				// path: 'http://192.168.10.166/dev-api', //余红奇
-				// path: 'http://v56c9b8e.natappfree.cc', //余红奇
-				// path: 'live.test.ylrztop.com/prod-api', //余红奇
-				// path: 'http://192.168.10.170/dev-api', //陈果
-				value: '',
-				talkdisabled: false, //输入框是否禁用
-				autoplay: false, //视频自动播放
-				showadd: false,
-				talklist: [],
-				scrollIntoView: '',
-				videoContext: '',
-				thistime: uni.$u.timeFormat(new Date(), 'yyyy-mm-dd hh:MM:ss'),
-				showWelcomeMessage: false,
-				isSubmit: false,
-				messageContent: "",
-				showziliao: false,
-				isScreen: true,
-				shopping: false, //小黄车弹窗
-				scrollTop: 0, //弹幕
-				old: {
-					scrollTop: 0
-				},
-				livedata: {}, //直播间点赞、关注、在线人数数据
-
-			};
-		},
-
-
-		onLoad(options) {
-			const userInfoStr = uni.getStorageSync("userInfo");
-			if (userInfoStr) {
-				try {
-					this.userinfo = JSON.parse(userInfoStr);
-				} catch (e) {
-					console.error("解析用户信息失败:", e);
-					// 处理错误情况,如跳转到登录页
-				}
-			} else {
-				console.error("未找到用户信息");
-				// 处理未登录情况
-			}
-			// 初始化直播间列表
-			this.initLiveList(options);
-			if (options.liveId) {
-				this.liveId = options.liveId; // 仅当 liveId 变化时更新
-			}
-			const platform = uni.getSystemInfoSync().platform;
-			if (['mp-weixin', 'mp-alipay', 'mp-baidu', 'mp-toutiao'].includes(platform)) {
-				// 确保 API 存在再调用
-				if (uni.showShareMenu) {
-					uni.showShareMenu({
-						withShareTicket: true, // 可选参数,根据需求配置
-						success: () => {
-							console.log('分享菜单显示成功');
-						},
-						fail: (err) => {
-							console.error('分享菜单显示失败:', err);
-						}
-					});
-				} else {
-					console.warn('当前平台不支持 uni.showShareMenu');
-				}
-			} else {
-				console.log('当前平台无需显示分享菜单');
-			}
-		},
-		onShareAppMessage() {
-			return {
-				// title: this.product.title,
-				title: this.livedata.liveName,
-				path: '/pages/home/index',
-				imageUrl: this.products.image,
-				success(res) {
-					console.log("分享成功", res);
-				},
-				fail(err) {
-					console.error("分享失败", err);
-				}
-			};
-		},
-		computed: {
-			filteredViewers() {
-				if (!this.liveViewers) {
-					return
-				} else {
-					return this.liveViewers.slice(0, 3);
-				}
-
-			}
-		},
-		mounted() {
-			// this.getLiveMsg() // 获取最近聊天记录
-			// this.onLike()
-			this.getliveViewData() ////直播间点赞、关注、在线人数数据
-
-			// this.intervalId = setInterval(() => {
-			// 	this.getliveViewData();
-			// }, 60 * 1000);
-			// this.getLiveinformation() // 获取直播间信息接口
-			this.getliveOrder() //正在购买
-			// this.getliveStore() // 获取小黄车 店铺展示
-			// this.getliveGoods() // 获取小黄车 商品详情
-			this.getliveUser() // 获取直播间用户
-			this.initTime()
-			// this.initWebSocket()
-			this.initSocket()
-			var that = this;
-			uni.$on('initSocket', () => {
-				that.initSocket()
-			})
-			uni.$on('sendMsg', (item) => {
-				that.sendMsg(item)
-			})
-			uni.$on('closeWebSocket', () => {
-				that.closeWebSocket()
-			})
-			this.getEWechatSdk();
-
-			this.getliving() //hls
-			// this.gettalklist()
-			// this.getAnswerlists()
-
-		},
-
-		onHide() {
-			clearInterval(this.intervalId); // 页面隐藏时清理
-		},
-		onUnload() {
-			// 标记为手动关闭,避免重连
-			this.isManualClose = true;
-			// 关闭所有WebSocket连接
-			this.closeAllWebSockets();
-
-			// 移除所有全局事件监听
-			this.removeAllEventListeners();
-
-			// 清理定时器
-			this.clearAllTimers();
-
-			// 销毁HLS播放器
-			if (this.hlsPlayer) {
-				this.hlsPlayer.destroy();
-				this.hlsPlayer = null;
-			}
-		},
-		watch: {
-			// 监听orderUser.count的变化
-			'orderUser.count': {
-				handler(newVal, oldVal) {
-					if (newVal !== this.prevOrderCount) {
-						this.prevOrderCount = newVal;
-						this.showPurchaseMessage();
-					}
-				},
-				immediate: true
-			}
-		},
-		methods: {// 添加连接状态检查方法
-checkConnectionStatus(liveId) {
-  if (!this.socketInstances[liveId]) return false;
-  
-  const socketInstance = this.socketInstances[liveId].instance;
-  return socketInstance && socketInstance.readyState === WebSocket.OPEN;
-},
-			closeAllWebSockets() {
-				this.isManualClose = true;
-
-				// 关闭所有连接
-				Object.keys(this.socketInstances).forEach(liveId => {
-					try {
-						if (this.socketInstances[liveId] && this.socketInstances[liveId].instance) {
-							this.socketInstances[liveId].instance.close({
-								code: 1000,
-								reason: '页面关闭'
-							});
-							console.log(`直播间 ${liveId} WebSocket 已关闭`);
-						}
-					} catch (e) {
-						console.error(`关闭直播间 ${liveId} WebSocket 时出错:`, e);
-					}
-				});
-
-				this.socketInstances = {};
-				isSocketOpen = false;
-			}, // 新增:移除所有全局事件监听器
-			removeAllEventListeners() {
-				uni.$off('initSocket');
-				uni.$off('sendMsg');
-				uni.$off('closeWebSocket');
-				uni.$off('refreshOrder');
-				// 可以根据实际情况添加其他需要移除的事件
-			}, // 新增:清理所有定时器
-			clearAllTimers() {
-				if (this.intervalId) {
-					clearInterval(this.intervalId);
-					this.intervalId = null;
-				}
-
-				if (this.pingpangTimes) {
-					clearInterval(this.pingpangTimes);
-					this.pingpangTimes = null;
-				}
-
-				if (this.reconnectTimer) {
-					clearTimeout(this.reconnectTimer);
-					this.reconnectTimer = null;
-				}
-
-				if (this.scrollTimer) {
-					clearTimeout(this.scrollTimer);
-					this.scrollTimer = null;
-				}
-
-				if (this.searchTimer) {
-					clearTimeout(this.searchTimer);
-					this.searchTimer = null;
-				}
-
-				if (this.purchasePromptTimer) {
-					clearTimeout(this.purchasePromptTimer);
-					this.purchasePromptTimer = null;
-				}
-			},
-			// 初始化当前直播间数据
-			async initCurrentLiveData() {
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (!currentLive) return;
-
-				try {
-					// 并行加载必要数据
-					await Promise.all([
-						this.getLiveMsg(currentLive),
-						this.getliveViewData(currentLive),
-						this.getliving(currentLive),
-						this.initSocket(currentLive) // 初始化WebSocket连接
-					]);
-
-					currentLive.loaded = true;
-				} catch (error) {
-					console.error("初始化直播间数据失败:", error);
-				} finally {
-					currentLive.loading = false;
-				}
-			},
-
-			// 初始化直播间列表
-			async initLiveList(options) {
-				try {
-					await this.getList(); // 先加载直播间列表
-
-					if (this.list.length === 0) {
-						console.error("直播间列表为空,无法初始化");
-						return;
-					}
-
-					// 设置初始直播间索引
-					if (options.liveId) {
-						const index = this.list.findIndex(item => item.liveId == options.liveId);
-						this.currentSwiperIndex = index !== -1 ? index : 0;
-					} else {
-						this.currentSwiperIndex = 0;
-					}
-
-					// 获取当前直播间的liveItem
-					const currentLive = this.list[this.currentSwiperIndex];
-					if (currentLive) {
-						this.liveId = currentLive.liveId;
-						// 初始化当前直播间数据
-						await this.initCurrentLiveData();
-					}
-
-				} catch (error) {
-					console.error("初始化失败:", error);
-				}
-			},
-			// 预加载策略优化 - 只预加载数据,不创建WebSocket连接
-			async preloadNearbyLives() {
-				if (this.preloading || this.list.length === 0) return;
-
-				this.preloading = true;
-				const currentIndex = this.currentSwiperIndex;
-
-				// 只预加载前后各1个直播间,减少资源消耗
-				const preloadIndexes = [];
-				if (currentIndex > 0) preloadIndexes.push(currentIndex - 1);
-				if (currentIndex < this.list.length - 1) preloadIndexes.push(currentIndex + 1);
-
-				for (let i = 0; i < preloadIndexes.length; i++) {
-					const index = preloadIndexes[i];
-					const liveItem = this.list[index];
-
-					if (!liveItem || liveItem.loaded || liveItem.loading) continue;
-
-					liveItem.loading = true;
-					try {
-						// 只预加载必要数据,不创建WebSocket连接
-						await Promise.all([
-							this.getLiveMsg(liveItem),
-							this.getliveViewData(liveItem),
-							this.getliving(liveItem)
-						]);
-						liveItem.loaded = true;
-					} catch (error) {
-						console.error(`预加载直播间 ${index} 失败:`, error);
-					} finally {
-						liveItem.loading = false;
-					}
-				}
-
-				this.preloading = false;
-			},
-
-			// Swiper切换事件
-			async onSwiperChange(e) {
-			  const newIndex = e.detail.current;
-			  const oldIndex = this.currentSwiperIndex;
-			
-			  // 先暂停旧直播间的视频
-			  const oldLiveItem = this.list[oldIndex];
-			  if (oldLiveItem) {
-			    this.pauseVideo(oldLiveItem);
-			  }
-			
-			  // 更新当前索引
-			  this.currentSwiperIndex = newIndex;
-			  const currentLive = this.list[newIndex];
-			  if (!currentLive) return;
-			
-			  this.liveId = currentLive.liveId;
-			
-			  // 延迟关闭旧连接,避免竞争条件
-			  setTimeout(() => {
-			    if (oldLiveItem && oldLiveItem.liveId) {
-			      this.closeWebSocket(oldLiveItem.liveId);
-			    }
-			  }, 100);
-			
-			  // 初始化当前直播间数据
-			  await this.initCurrentLiveData();
-			},
-			// 关闭最旧的WebSocket连接
-			closeOldestSocket() {
-				if (Object.keys(this.socketInstances).length === 0) return;
-
-				// 找到最早创建的连接
-				let oldestLiveId = null;
-				let oldestTimestamp = Infinity;
-
-				Object.entries(this.socketInstances).forEach(([liveId, socketItem]) => {
-					if (socketItem.createTime < oldestTimestamp &&
-						liveId !== this.liveId) { // 不要关闭当前直播间的连接
-						oldestTimestamp = socketItem.createTime;
-						oldestLiveId = liveId;
-					}
-				});
-
-				if (oldestLiveId) {
-					this.closeWebSocket(oldestLiveId);
-				}
-			},
-			// 获取直播间列表
-			async getList() {
-				const data = {
-					page: 1,
-					page_size: 20
-				};
-				try {
-					const res = await liveList(data);
-					if (res.code === 200) {
-						this.list = res.rows.map(item => ({
-							...item,
-							talklist: [],
-							loading: false,
-							loaded: false,
-							// 其他初始化字段...
-						}));
-						console.log("直播间列表加载成功,数量:", this.list.length); // 确认数量是否 > 0
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: "none"
-						});
-						this.list = []; // 接口失败时清空列表,避免后续错误
-					}
-				} catch (error) {
-					console.error("获取直播间列表失败:", error);
-					this.list = []; // 异常时清空列表
-				}
-			},
-			// 播放视频
-			playVideo(liveItem) {
-				if (!liveItem) {
-					console.error('播放失败:直播间数据不存在');
-					return;
-				}
-				// 检查视频源是否存在
-				if (!liveItem.livingUrl && !liveItem.videoUrl) {
-					console.error('播放失败:无视频源', liveItem);
-					// 尝试重新加载视频源
-					liveItem.loading = true;
-					this.getliving(liveItem).then(() => {
-						liveItem.loading = false;
-						this.$nextTick(() => this.playVideo(liveItem)); // 重新尝试播放
-					});
-					return;
-				}
-
-				this.$nextTick(() => {
-					try {
-						const videoId = `myVideo_${liveItem.liveId}`;
-						const videoContext = uni.createVideoContext(videoId, this);
-						if (videoContext) {
-							videoContext.play();
-						} else {
-							console.error('未找到视频组件', videoId);
-						}
-					} catch (error) {
-						console.error("播放视频失败:", error);
-					}
-				});
-			},
-			// 预加载相邻直播间
-			async preloadNearbyLives() {
-				if (this.preloading || this.list.length === 0) return;
-
-				this.preloading = true;
-				const currentIndex = this.currentSwiperIndex;
-
-				// 计算需要预加载的索引范围
-				const startIndex = Math.max(0, currentIndex - this.preloadCount);
-				const endIndex = Math.min(this.list.length - 1, currentIndex + this.preloadCount);
-
-				for (let i = startIndex; i <= endIndex; i++) {
-					// 跳过当前直播间和已加载的直播间
-					if (i === currentIndex || this.list[i].loaded || this.list[i].loading) continue;
-
-					this.list[i].loading = true;
-					try {
-						// 仅预加载必要数据,不创建WebSocket连接
-						await Promise.all([
-							this.getLiveMsg(this.list[i]),
-							this.getliveViewData(this.list[i]),
-							this.getliving(this.list[i])
-						]);
-						this.list[i].loaded = true;
-					} catch (error) {
-						console.error(`预加载直播间 ${i} 失败:`, error);
-					} finally {
-						this.list[i].loading = false;
-					}
-				}
-
-				this.preloading = false;
-			},
-			// 初始化直播间数据
-			initLiveData() {
-				// 重置数据
-				this.resetLiveData();
-
-				// 初始化直播间特定数据
-				this.getLiveMsg();
-				this.getliveViewData();
-				this.getliveOrder();
-				this.getliving();
-				this.initSocket();
-				// 设置定时器
-				this.intervalId = setInterval(() => {
-					this.getliveViewData();
-				}, 60 * 1000);
-			},
-
-
-			openViews() {
-				// 计算scroll-view高度
-				this.$nextTick(() => {
-					const query = uni.createSelectorQuery().in(this);
-					query.select('.view-box').boundingClientRect(data => {
-						if (data) {
-							// 减去标题和底部固定区域的高度
-							this.scrollHeight = data.height - 80 - 120; // 80是标题高度,120是底部高度
-						}
-					}).exec();
-				});
-			},
-
-			// 重置直播间数据
-			resetLiveData() {
-				// 保留不需要重置的数据(如用户信息等)
-				const keepData = {
-					userinfo: this.userinfo,
-					list: this.list,
-					currentSwiperIndex: this.currentSwiperIndex
-				};
-
-				// 重置其他直播间特定数据
-				this.liveUserTotal = null;
-				this.liveViewData = {};
-				this.liveViewers = [];
-				this.livingUrl = "";
-				this.videoUrl = null;
-				this.products = {};
-				this.store = {};
-				this.orderUser = {};
-				this.talklist = [];
-				this.livedata = {};
-				this.isFollow = true;
-
-				// 恢复需要保留的数据
-				Object.assign(this, keepData);
-			},
-
-			// 获取直播间用户
-			async getliveUser(isLoadMore = false) {
-				// 强制使用当前 liveId,避免使用旧值
-				const currentLiveId = this.liveId;
-				if (!currentLiveId) return;
-
-				if (this.viewLoading || this.viewNoMoreData) return;
-				this.viewLoading = true;
-
-				try {
-					const res = await watchUserList(currentLiveId, this.viewPageSize, this.viewPageNum, false);
-					if (res.code === 200) {
-						// 若请求期间已切换直播间,忽略旧数据
-						if (this.liveId !== currentLiveId) return;
-
-						this.liveUserTotal = res.total;
-						if (res.rows.length === 0) {
-							this.viewNoMoreData = true;
-							return;
-						}
-
-						this.liveViewers = isLoadMore ? [...this.liveViewers, ...res.rows] :
-							res.rows; // 首次加载/切换直播间时重置数据
-						this.viewPageNum++;
-					}
-				} catch (error) {
-					console.error('获取观众列表失败:', error);
-				} finally {
-					this.viewLoading = false;
-				}
-			},
-			// 滚动到底部触发
-			handleScrollToLower() {
-				// 清除上一次未执行的定时器,避免重复请求
-				if (this.scrollTimer) {
-					clearTimeout(this.scrollTimer);
-				}
-
-				// 延迟0.5秒(500毫秒)执行接口请求
-				this.scrollTimer = setTimeout(() => {
-					this.getliveUser(true); // 加载更多数据
-				}, 1000); // 延迟时间:500毫秒
-			},
-
-			// 修改其他方法,增加liveItem参数
-			async getLiveMsg(liveItem) {
-				// 强化校验:确保 liveItem 存在且包含 liveId
-				if (!liveItem || !liveItem.liveId) {
-					console.error('getLiveMsg 错误:无效的 liveItem', {
-						liveItem: liveItem,
-						currentIndex: this.currentSwiperIndex,
-						listLength: this.list.length
-					});
-					return; // 直接返回,不执行后续逻辑
-				}
-
-				try {
-					const res = await liveMsg(liveItem.liveId, 30, 1);
-					if (res.code == 200) {
-						// 确保使用响应式更新
-						this.$set(liveItem, 'talklist', [...res.rows]);
-						this.$nextTick(() => {
-							this.$set(liveItem, 'scrollIntoView', `list_${liveItem.talklist.length-1}`);
-						});
-					}
-				} catch (error) {
-					console.error("获取聊天记录失败:", error);
-				}
-			},
-			// 暂停视频
-			pauseVideo(liveItem) {
-				if (!liveItem.livingUrl && !liveItem.videoUrl) return;
-
-				try {
-					const videoId = `myVideo_${liveItem.liveId}`;
-					const videoContext = uni.createVideoContext(videoId, this);
-					if (videoContext) {
-						videoContext.pause();
-					}
-				} catch (error) {
-					console.error("暂停视频失败:", error);
-				}
-			},
-			// 点击红包
-			onRed() {
-				console.log("点了")
-
-				if (!this.liveId) return;
-				console.log("点了this.liveId", this.liveId)
-				if (!this.redInfo?.redId) return;
-				console.log("点了this.redInfo?.redId", this.redInfo.redId)
-				console.log("点了this.userinfo.userId", this.userinfo.userId)
-				let data = {
-					liveId: this.liveId,
-					userId: this.userinfo.userId,
-					redId: this.redInfo.redId,
-				}
-				liveRed(data).then(res => {
-						if (res.code == 200) {} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			handleSearchInput() {
-				// 使用防抖优化性能,避免频繁请求
-				clearTimeout(this.searchTimer);
-				this.searchTimer = setTimeout(() => {
-					this.queryCollect();
-				}, 500); // 500毫秒延迟
-			},
-			// 显示购买提示信息
-			showPurchaseMessage() {
-				// 清除之前的定时器
-				if (this.purchasePromptTimer) {
-					clearTimeout(this.purchasePromptTimer);
-				}
-
-				// 显示提示
-				this.showPurchasePrompt = true;
-
-				// 2秒后自动隐藏
-				this.purchasePromptTimer = setTimeout(() => {
-					this.showPurchasePrompt = false;
-				}, 2000);
-			},
-			truncateString(str, maxLength) {
-				return str.length > maxLength ? str.slice(0, maxLength) + '...' : str;
-			},
-			goStore() {
-				console.log("带过去storeId", this.storeId)
-				uni.navigateTo({
-					url: '/pages_shop/store?liveId=' + this.liveId + "&storeId=" + this.storeId
-				})
-			},
-			// 去订单列表
-			goOrderList() {
-				uni.navigateTo({
-					url: "/pages_shop/order"
-				})
-			},
-
-			// 初始化HLS播放器
-			initHlsPlayer() {
-				if (Hls.isSupported() && this.livingUrl) {
-					const video = document.getElementById('myVideo');
-					if (video) {
-						this.hlsPlayer = new Hls();
-						this.hlsPlayer.loadSource(this.livingUrl);
-						this.hlsPlayer.attachMedia(video);
-						this.hlsPlayer.on(Hls.Events.MANIFEST_PARSED, () => {
-							video.play();
-						});
-					}
-				}
-			},
-
-			// 视频错误处理
-			videoError(e) {
-				console.error('视频播放错误:', e.detail.errMsg);
-				// 尝试重新加载或切换到备用流
-				if (this.livingUrl) {
-					setTimeout(() => {
-						this.videoContext.play();
-					}, 2000);
-				}
-			},
-
-			// 修改获取直播信息方法
-			async getliving(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-
-				console.log("获取直播信息:", liveItem.liveId);
-				const param = {
-					id: liveItem.liveId
-				};
-
-				try {
-					const res = await getlive(param);
-					if (res.code !== 200) {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-						return;
-					}
-
-					// 强制更新视频源(覆盖旧值)
-					if (res.data.liveType === 2) {
-						// 回放视频
-						this.$set(liveItem, 'videoUrl', res.data.videoUrl);
-						this.$set(liveItem, 'livingUrl', ''); // 清空直播流
-					} else if (res.data.liveType === 1) {
-						// 直播流
-						this.$set(liveItem, 'livingUrl', res.data.flvHlsUrl);
-						this.$set(liveItem, 'videoUrl', ''); // 清空回放视频
-					} else {
-						// 未开播
-						this.$set(liveItem, 'livingUrl', '');
-						this.$set(liveItem, 'videoUrl', '');
-					}
-
-					// 更新其他直播信息
-					this.$set(liveItem, 'showType', res.data.showType);
-					this.$set(liveItem, 'storeId', res.storeId);
-					this.$set(liveItem, 'autoplay', res.data.liveType !== 0); // 未开播不自动播放
-
-				} catch (err) {
-					console.error("获取直播信息失败:", err);
-					uni.showToast({
-						title: "获取直播信息失败",
-						icon: 'none'
-					});
-				}
-			}, // 设置视频播放
-			setupVideoPlayback(liveItem, liveData) {
-				if (!liveItem.livingUrl) return;
-
-				// H5 平台:使用 HLS.js 处理 .m3u8 流
-				// #ifdef H5
-				if (liveItem.livingUrl.includes('.m3u8')) {
-					this.initHlsPlayer(liveItem);
-					return;
-				}
-				// #endif
-
-				// 小程序/App 平台:直接使用 video 组件
-				const videoId = `myVideo_${liveItem.liveId}`;
-				const videoContext = uni.createVideoContext(videoId, this);
-
-				if (liveData.liveType === 1) {
-					// 回放:跳转到指定位置
-					videoContext.seek(liveData.nowDuration || 0);
-				} else {
-					// 直播:直接播放
-					videoContext.play();
-				}
-			},
-			maskString(str, maskChar = '*') {
-				// 新增:如果str是undefined或null,直接返回空字符串
-				if (!str) return '';
-				// 确保str是字符串(如果是数字等类型,先转为字符串)
-				const strVal = String(str);
-				return strVal.split('').map((char, index) => (index === 0 ? char : maskChar)).join('');
-			},
-
-			getPureDecimal(num, precision = 6) {
-				const decimalPart = Math.abs(num).toFixed(precision).split('.')[1];
-				return decimalPart?.replace(/0+$/, '') || ''; // 移除末尾多余的0
-			},
-
-			// 返回上一个页面并关闭WebSocket
-			goBack() {
-				// 暂停当前视频
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (currentLive) {
-					this.pauseVideo(currentLive);
-				}
-
-				// 关闭所有WebSocket连接
-				this.closeWebSocket();
-
-				// 导航返回
-				const pages = getCurrentPages();
-				if (pages.length > 1) {
-					uni.navigateBack();
-				} else {
-					uni.switchTab({
-						url: '/pages/list/index'
-					});
-				}
-			},
-			// 修改其他需要liveItem参数的方法
-			async getliveViewData(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-
-				try {
-					const res = await getLiveViewData(liveItem.liveId);
-					if (res.code == 200) {
-						liveItem.liveViewData = res;
-					}
-				} catch (error) {
-					console.error("获取直播间数据失败:", error);
-				}
-			},
-			//正在购买
-			async getliveOrder() {
-				const currentLiveId = this.liveId;
-				if (!currentLiveId) return;
-
-				try {
-					const res = await liveOrderUser(currentLiveId);
-					if (res.code === 200) {
-						// 绑定到当前 liveItem
-						const currentLive = this.list[this.currentSwiperIndex];
-						if (currentLive) {
-							this.$set(currentLive, 'orderUser', res);
-							this.orderUser = res; // 同步全局变量
-						}
-					}
-				} catch (error) {
-					console.error('获取正在购买用户失败:', error);
-				}
-			},
-			// 获取直播间信息接口
-			getLiveinformation() {
-				if (!this.liveId) return;
-				getLiveInfo(this.liveId).then(res => {
-						if (res.code == 200) {
-							console.log("获取直播间信息接口>>>>", res)
-							this.livingUrl = res.livingUrl
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-
-
-			// 修改点赞方法
-			async onLike(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-				try {
-					const res = await liveDataLike(liveItem.liveId);
-					if (res.code === 200 && liveItem.liveViewData) {
-						liveItem.liveViewData.like++; // 只更新当前直播间的点赞数
-					}
-				} catch (error) {
-					console.error('点赞失败:', error);
-				}
-			},
-			// 去购买,跳商品详情
-			goShop(productId, goodsId) {
-				uni.navigateTo({
-					url: '/pages_shop/goods?productId=' + productId + '&liveId=' + this.liveId + '&goodsId=' +
-						goodsId + '&storeId=' + this.storeId
-				})
-			},
-
-			// 查询店铺
-			async queryCollect() {
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (!currentLive || !currentLive.liveId) return;
-
-				const {
-					storeId
-				} = currentLive;
-				if (!storeId) return;
-				try {
-					const res = await store(currentLive.storeId, currentLive.inputInfo);
-					if (res.code === 200) {
-						// 数据绑定到当前 liveItem,避免全局污染
-						this.$set(currentLive, 'products', res.data.goodsList);
-						this.$set(currentLive, 'store', res.data);
-						// 同步更新全局变量(供弹窗使用)
-						this.products = res.data.goodsList;
-						this.store = res.data;
-					}
-				} catch (error) {
-					console.error('获取小黄车商品失败:', error);
-				}
-			},
-
-			// 店铺收藏
-			onStoreCollect() {
-				if (!this.storeId) return;
-				collectStore(this.storeId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							this.store.isFavorite = !this.store.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 商品收藏
-			onGoodsCollect(item) {
-				if (!item || item.length === 0 || !item.goodsId) {
-					return;
-				}
-				collectGoods(item.goodsId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							item.isFavorite = !item.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 关注
-			async onFollow(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-
-				try {
-					const res = await follow(liveItem.liveId);
-					liveItem.isFollow = !liveItem.isFollow;
-					uni.showToast({
-						title: res.msg,
-						icon: 'none'
-					});
-				} catch (error) {
-					console.error("关注操作失败:", error);
-				}
-			},
-			// 时间戳
-			initTime() {
-				const now = new Date();
-				this.timestamp = now.getTime(); // 例如:'2023-04-01 12:00:00'
-			},
-			// initWebSocket() {
-			//       const liveWS = new LiveWS('ws://your-server.com', 123, 456);
-
-			//       // 从 URL 中解析 timestamp
-			//       const urlParams = new URL(liveWS.url).searchParams;
-			//       this.timestamp = urlParams.get('timestamp');
-			//       // console.log('Timestamp:', timestamp);
-			//     },
-
-			// 弹幕滚动
-			lowerChat: function(e) {
-				console.log(e)
-			},
-			scroll: function(e) {
-				console.log(e)
-				this.old.scrollTop = e.detail.scrollTop
-			},
-
-
-			loadmore() {
-				// for (let i = 0; i < 30; i++) {
-				//   this.indexList.push({
-				//     url: this.shopList[uni.$u.random(0, this.shopList.length - 1)],
-				//   });
-				// }
-			},
-
-			openShop() {
-
-			},
-			openViews() {
-				this.$nextTick(() => {
-					const query = uni.createSelectorQuery().in(this);
-					query.select('.view-box').boundingClientRect(data => {
-						if (data) {
-							this.scrollHeight = data.height - 80 - 120;
-						}
-					}).exec();
-				});
-			},
-			close() {
-				this.showadd = !this.showadd
-			},
-			closes() {
-				this.showziliao = !this.showziliao
-			},
-			closest() {
-				this.showAnswer = !this.showAnswer
-			},
-			closestred() {
-				this.showAnswerred = !this.showAnswerred
-			},
-			closeanswer() {
-				this.answerbtn = !this.answerbtn
-			},
-			// 关闭小黄车
-			closeShop() {
-				this.shopping = !this.shopping
-			},
-			// 关闭红包
-			closeRed() {
-				this.showRed = !this.showRed
-			},
-			// 触摸结束
-			handleTouchEnd() {
-				this.isZoom = false; // 恢复原状
-			},
-			getEWechatSdk() {
-				// 只在H5平台执行
-				// #ifdef H5
-				let eWechatSdk = '';
-				if (/(Android)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'jWeixin';
-				} else if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'wx';
-				} else {
-					eWechatSdk = 'jWeixin';
-				}
-				uni.setStorageSync("wxSdk", eWechatSdk);
-				// #endif
-			},
-			// 关闭WebSocket连接
-			closeWebSocket(liveId = null) {
-			     if (liveId) {
-			         if (this.socketInstances[liveId]) {
-			           try {
-			             const socketInstance = this.socketInstances[liveId].instance;
-			             if (socketInstance && socketInstance.readyState === WebSocket.OPEN) {
-			               socketInstance.close({
-			                 code: 1000,
-			                 reason: '切换直播间'
-			               });
-			             }
-			             // 确保从管理对象中移除
-			             delete this.socketInstances[liveId];
-			             this.activeSockets = Math.max(0, this.activeSockets - 1);
-			           } catch (e) {
-			             console.error(`关闭直播间 ${liveId} WebSocket时出错:`, e);
-			           }
-			         }
-			       } else {
-			        // 关闭所有连接
-			        console.log('关闭所有WebSocket连接');
-			        Object.keys(this.socketInstances).forEach(id => {
-			          if (this.socketInstances[id] && this.socketInstances[id].instance) {
-			            try {
-			              this.socketInstances[id].instance.close({
-			                code: 1000,
-			                reason: '页面关闭'
-			              });
-			            } catch (e) {
-			              console.error(`关闭直播间 ${id} WebSocket时出错:`, e);
-			            }
-			          }
-			        });
-			        this.socketInstances = {};
-			        this.activeSockets = 0;
-			      }
-			      
-			      console.log(`关闭后活跃连接数: ${this.activeSockets}`);
-			    },
-			reConnect() {
-				var that = this;
-				try {
-					uni.closeSocket();
-				} catch (e) {
-
-				}
-				setTimeout(function() {
-					that.initSocket();
-				}, 10000);
-
-			},
-			startHeartbeat() {
-				clearInterval(this.pingpangTimes);
-
-				this.pingpangTimes = setInterval(() => {
-					if (!isSocketOpen) return;
-
-					const pingData = {
-						cmd: 'ping',
-						timestamp: Date.now()
-					};
-					uni.sendSocketMessage({
-						data: JSON.stringify(pingData),
-						success: () => console.debug('心跳发送成功'),
-						fail: (err) => {
-							console.error('心跳发送失败:', err);
-							this.scheduleReconnect();
-						}
-					});
-				}, 30000); // 30秒心跳间隔
-			},
-			// 初始化WebSocket连接
-			initSocket(liveItem) {
-			      if (!liveItem || !liveItem.liveId) return;
-			      
-			      // 确保用户信息已获取
-			      if (!this.userinfo || !this.userinfo.userId) {
-			        console.error("用户信息未就绪,无法建立WebSocket连接");
-			        setTimeout(() => this.initSocket(liveItem), 1000);
-			        return;
-			      }
-			      
-			      const liveId = liveItem.liveId;
-			      
-			      // 如果已经存在连接,先关闭
-			      if (this.socketInstances[liveId]) {
-			        console.log(`直播间 ${liveId} 已存在连接,先关闭`);
-			        this.closeWebSocket(liveId);
-			      }
-			      
-			      // 检查连接数限制
-			      if (this.activeSockets >= this.maxSocketConnections) {
-			        console.warn('已达到WebSocket连接数限制,关闭最旧的连接');
-			        this.closeOldestSocket();
-			      }
-			      
-			      // 生成签名
-			      const signature = CryptoJS.HmacSHA256(
-			        `${liveId}${this.userinfo.userId}${this.userType}${this.timestamp}`,
-			        this.timestamp.toString()
-			      ).toString(CryptoJS.enc.Hex);
-			      
-			      // 创建WebSocket连接
-			      try {
-			        console.log(`创建直播间 ${liveId} 的WebSocket连接`);
-			        const socketTask = uni.connectSocket({
-			          url: `${wsUrl}?userId=${this.userinfo.userId}&liveId=${liveId}&userType=${this.userType}&timestamp=${this.timestamp}&signature=${signature}`,
-			          success: () => {
-			            console.log(`直播间 ${liveId} WebSocket连接创建成功`);
-			            this.socketInstances[liveId] = {
-			              instance: socketTask,
-			              isOpen: false,
-			              liveItem: liveItem,
-			              createTime: Date.now() // 记录创建时间
-			            };
-			            this.activeSockets++;
-			            console.log(`当前活跃连接数: ${this.activeSockets}`);
-			            this.setupSocketListeners(liveId);
-			          },
-			          fail: (err) => {
-			            console.error('WebSocket连接失败:', err);
-			            this.scheduleReconnect(liveItem);
-			          }
-			        });
-			      } catch (e) {
-			        console.error('创建WebSocket异常:', e);
-			        this.scheduleReconnect(liveItem);
-			      }
-			    },
-
-			// 设置 WebSocket 监听器
-			setupSocketListeners(liveId) {
-				 if (!this.socketInstances[liveId] || !this.socketInstances[liveId].instance) {
-				    console.error(`设置监听器失败: 直播间 ${liveId} 的连接不存在或已关闭`);
-				    return;
-				  }
-			      const socketItem = this.socketInstances[liveId];
-			      if (!socketItem || !socketItem.instance) {
-			        console.error(`设置监听器失败: 直播间 ${liveId} 的连接不存在`);
-			        return;
-			      }
-			
-			      const socketInstance = socketItem.instance;
-			
-			      socketInstance.onOpen(() => {
-			        socketItem.isOpen = true;
-			        this.reconnectCount = 0;
-			        console.log(`直播间 ${liveId} WebSocket连接成功`);
-			        this.startHeartbeat(liveId);
-			      });
-			
-			      socketInstance.onClose(() => {
-			        socketItem.isOpen = false;
-			        console.log(`直播间 ${liveId} WebSocket连接关闭`);
-			        
-			        // 连接关闭时更新计数
-			        if (this.socketInstances[liveId]) {
-			          this.activeSockets = Math.max(0, this.activeSockets - 1);
-			          delete this.socketInstances[liveId];
-			          console.log(`连接关闭后活跃连接数: ${this.activeSockets}`);
-			        }
-			        
-			        if (!this.isManualClose) {
-			          this.scheduleReconnect(liveId);
-			        }
-			      });
-			
-			      socketInstance.onError((err) => {
-			        console.error(`直播间 ${liveId} WebSocket错误:`, err);
-			        
-			        // 错误时也更新计数
-			        if (this.socketInstances[liveId]) {
-			          this.activeSockets = Math.max(0, this.activeSockets - 1);
-			          delete this.socketInstances[liveId];
-			          console.log(`连接错误后活跃连接数: ${this.activeSockets}`);
-			        }
-			        
-			        this.scheduleReconnect(liveId);
-			      });
-			
-			      socketInstance.onMessage((res) => {
-			        try {
-			          const messageData = JSON.parse(res.data);
-			          this.handleSocketMessage(messageData, socketItem.liveItem);
-			        } catch (e) {
-			          console.error('解析消息失败:', e);
-			        }
-			      });
-			    },
-			// 处理Socket消息
-			handleSocketMessage(message, liveItem) {
-				if (!liveItem || !messageData) return;
-				// 将消息添加到当前直播间的聊天列表
-				if (messageData.cmd === 'sendMsg') {
-					c
-				}
-				if (message.cmd == 'red') {
-					// 领红包
-					liveItem.redInfo = JSON.parse(message.data);
-				} else if (message.cmd == 'sendRedPacketQuestion') {
-					const list = JSON.parse(message.data);
-					// 处理红包答题逻辑
-				} else if (message.cmd == 'entry') {
-					liveItem.showWelcomeMessage = true;
-				} else if (redata.data.cmd == 'live_start') {
-					// 直播开始
-				} else if (redata.data.cmd == 'live_end') {
-					// 直播结束
-				} else if (redata.data.cmd == 'deleteId') {
-					uni.$emit('deleteId');
-				} else if (redata.data.cmd == 'sendRedPacketQuestion') {
-					const list = JSON.parse(redata.data.data)
-					liveItem.redanswerAll = [...liveItem.redanswerAll, ...list]
-					if (liveItem.redanswerAll[1].randomAmount !== null) {
-						liveItem.redanswertips = JSON.parse(liveItem.redanswerAll[0]
-							.randomAmount)
-					}
-
-				}
-			},checkSocketConnections() {
-      console.log('=== WebSocket连接状态检查 ===');
-      console.log(`活跃连接数: ${this.activeSockets}`);
-      
-      Object.entries(this.socketInstances).forEach(([liveId, socketItem]) => {
-        const state = socketItem.instance ? socketItem.instance.readyState : 'UNKNOWN';
-        const stateText = {
-          0: 'CONNECTING',
-          1: 'OPEN',
-          2: 'CLOSING',
-          3: 'CLOSED'
-        }[state] || 'UNKNOWN';
-        
-        console.log(`直播间 ${liveId}: 状态=${stateText}, 创建时间=${new Date(socketItem.createTime).toLocaleTimeString()}`);
-      });
-      
-      console.log('=== 检查结束 ===');
-    },
-			scheduleReconnect() {
-				if (this.isManualClose || this.reconnectCount >= this.maxReconnectAttempts) return;
-
-				this.reconnectCount++;
-				const delay = Math.min(3000 * this.reconnectCount, 30000);
-
-				console.log(`将在 ${delay}ms 后重连 (尝试 ${this.reconnectCount}/${this.maxReconnectAttempts})`);
-
-				this.reconnectTimer = setTimeout(() => {
-					this.initSocket();
-				}, delay);
-			},
-			sendMsg(liveItem) {
-				 if (!liveItem || !liveItem.liveId) return;
-				
-				  const liveId = liveItem.liveId;
-				  
-				  // 使用新的连接状态检查方法
-				  if (!this.checkConnectionStatus(liveId)) {
-				    uni.showToast({
-				      title: "连接未建立,请稍后重试",
-				      icon: 'none'
-				    });
-				    // 尝试重新连接
-				    this.initSocket(liveItem);
-				    return;
-				  }
-
-				if (!liveItem.value.trim()) {
-					uni.showToast({
-						title: "不能发送空消息",
-						icon: 'none'
-					});
-					return;
-				}
-
-				const data = {
-					liveId: liveId,
-					userId: this.userinfo.userId,
-					userType: 0,
-					cmd: "sendMsg",
-					msg: liveItem.value,
-					nickName: this.userinfo.nickName,
-					avatar: this.userinfo.avatar
-				};
-
-				socketItem.instance.send({
-					data: JSON.stringify(data),
-					success: () => {
-						console.log("消息发送成功");
-						liveItem.value = ''; // 清空输入框
-					},
-					fail: (err) => {
-						console.error("消息发送失败:", err);
-						uni.showToast({
-							title: "发送失败,请重试",
-							icon: 'none'
-						});
-					}
-				});
-			},
-		}
-	};
-</script>
-
-<style scoped lang="scss">
-	.swiper-wrapper {
-		position: relative;
-		width: 100%;
-		height: 100vh;
-		overflow: hidden;
-		background-color: #000000;
-	}
-
-	.swiper-container {
-		width: 100%;
-		height: 100vh;
-	}
-
-	.container {
-		width: 100%;
-		height: 100%;
-		position: relative;
-
-		// 添加渐变过渡效果
-		transition: opacity 0.3s ease;
-
-		&.active {
-			opacity: 1;
-		}
-
-		// 非活动项半透明显示
-		// &:not(.active) {
-		// 	opacity: 0.7;
-		// }
-	}
-
-	.loading-tip {
-		position: absolute;
-		top: 50%;
-		left: 50%;
-		transform: translate(-50%, -50%);
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		justify-content: center;
-		z-index: 10;
-
-		.loading-text {
-			color: #ffffff;
-			font-size: 28rpx;
-			margin-top: 20rpx;
-		}
-	}
-
-	.loading-more,
-	.no-more {
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		padding: 20rpx 0;
-		color: #999;
-		font-size: 24rpx;
-	}
-
-	.loading-more {
-		flex-direction: column;
-	}
-
-	.preload-indicator {
-		position: absolute;
-		top: 50%;
-		right: 30rpx;
-		transform: translateY(-50%);
-		z-index: 100;
-		background: rgba(0, 0, 0, 0.5);
-		border-radius: 50%;
-		padding: 16rpx;
-	}
-
-	/* button自带样式清除 */
-	.student-orther-icon button::after {
-		border: none !important;
-		padding: 0 !important;
-		margin: 0 !important;
-	}
-
-	.student-orther-icon button {
-		background-color: transparent !important;
-		padding: 0 !important;
-		line-height: inherit !important;
-		margin: 0 !important;
-		width: auto !important;
-		font-weight: 500 !important;
-		border-radius: none !important;
-	}
-
-	.welcome-message {
-		position: fixed;
-		width: 100%;
-		bottom: 460rpx;
-		left: 50%;
-		transform: translateX(-50%);
-		color: white;
-		padding: 10px 20px;
-		border-radius: 20px;
-		animation: fadeOut 1s ease 1s forwards;
-		z-index: 1000;
-	}
-
-	@keyframes fadeOut {
-		from {
-			opacity: 1;
-		}
-
-		to {
-			opacity: 0;
-		}
-	}
-
-	// .container {
-	// 	position: relative;
-	// 	width: 100%;
-	// 	height: 100vh;
-	// 	overflow: hidden;
-	// }
-
-	// .talktext {
-	// 	border-radius: 8rpx;
-	// 	background-color: rgba(255, 255, 255, 0.1);
-
-	// 	view {
-	// 		width: 100%;
-	// 	}
-	// }
-
-	.talk-list {
-		border-radius: 30rpx;
-		background-color: rgba(33, 33, 33, 0.5);
-		padding: 10rpx 30rpx;
-	}
-
-	// .zoom-button-active {
-	// 	transform: scale(1.5);
-	// }
-
-	// .background-image {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 0;
-	// }
-
-	// .background-images {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 6;
-	// }
-
-	// .blackbg {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: 0;
-	// 	width: 100%;
-	// 	height: 100%;
-	// 	background: rgba(0, 0, 0, 0.7);
-	// 	object-fit: cover;
-	// 	filter: blur(10px);
-	// 	z-index: 1;
-	// }
-
-	.content {
-		position: relative;
-		z-index: 2;
-		height: 100%;
-		width: 100%;
-		top: 0;
-		left: 0;
-		display: flex;
-		flex-direction: column;
-		justify-content: space-between;
-
-		.content-top {
-			width: 100%;
-			margin-top: 150rpx;
-			display: flex;
-			align-items: center;
-			justify-content: space-between;
-			padding: 0 24rpx;
-			box-sizing: border-box;
-
-			.sum {
-				width: 80rpx;
-				height: 52rpx;
-				background: rgba(0, 0, 0, 0.5);
-				border-radius: 26rpx 26rpx 26rpx 26rpx;
-				font-size: 24rpx;
-				color: #FFFFFF;
-				text-align: center;
-				line-height: 52rpx;
-
-			}
-		}
-
-		.follow-btn {
-			padding: 8rpx 16rpx;
-			background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-			border-radius: 26rpx;
-			font-weight: 500;
-			font-size: 26rpx;
-			color: #FFFFFF;
-		}
-	}
-
-	.videolist {
-		position: relative;
-	}
-
-	.video {
-		height: 100vh;
-		/* 占屏幕高度的80% */
-		width: 100%;
-		background-color: rgba(57, 57, 57, 0.4);
-	}
-
-	.videotop {
-		width: 100%;
-		height: 100%;
-	}
-
-	.video_row {
-		width: 100%;
-		max-height: 500rpx;
-		overflow: hidden;
-		margin-top: 360rpx;
-	}
-
-	.popup-video {
-		position: absolute;
-		top: 30%;
-		height: 500rpx;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		justify-content: center;
-		width: 100%;
-		color: #fff;
-		z-index: 9;
-
-		.more {
-			background-color: #3280fe;
-			border-radius: 80rpx;
-			width: 280rpx;
-			text-align: center;
-			height: 60rpx;
-			line-height: 60rpx;
-		}
-	}
-
-	.icon-bg {
-		background-color: rgba(157, 157, 157, 0.8);
-		border-radius: 50%;
-		width: 72rpx;
-		height: 72rpx;
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		transition: transform 0.2s ease;
-	}
-
-	.list {
-		width: 80%;
-		margin-bottom: 20rpx;
-		animation: xxxawdawd .2s;
-	}
-
-	@keyframes xxxawdawd {
-		from {
-			margin-top: 0rpx;
-			opacity: 0;
-		}
-
-		to {
-			margin-top: 20rpx;
-			opacity: 1;
-		}
-	}
-
-	.shop-prompt {
-		position: absolute;
-		bottom: 600rpx;
-		left: 24rpx;
-		padding: 6rpx 20rpx;
-		background: rgba(230, 154, 34, 0.7);
-		border-radius: 24rpx;
-		z-index: 9;
-		font-weight: 500;
-		font-size: 26rpx;
-		color: #FFFFFF;
-		transition: opacity 0.3s ease;
-	}
-
-	.siderow-group {
-		position: absolute;
-		top: 56%;
-		right: 50rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-	}
-
-	.side-group {
-		position: absolute;
-		// top: 30%;
-		top: 56%;
-		right: 50rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-
-
-	}
-
-	.red-box {
-		.button {
-			margin: 0 auto;
-			width: 80%;
-			line-height: 88rpx;
-			height: 88rpx;
-			background: linear-gradient(90deg, #FF5701 0%, #FFB501 100%);
-			box-shadow: 0rpx 8rpx 8rpx 0rpx rgba(238, 124, 80, 0.2);
-			border-radius: 44rpx 44rpx 44rpx 44rpx;
-			font-weight: 600;
-			font-size: 32rpx;
-			color: #FFFFFF;
-			text-align: center;
-		}
-	}
-
-	.view-box {
-		position: relative;
-		height: 40vh;
-		/* 设置弹出层高度为视窗高度的70% */
-		padding: 40rpx 0rpx 120rpx;
-		box-sizing: border-box;
-		display: flex;
-		flex-direction: column;
-
-		.scroll-content {
-			flex: 1;
-			overflow-y: auto;
-			padding: 0 40rpx;
-		}
-
-		.bottom {
-			padding: 20rpx 40rpx;
-			position: absolute;
-			bottom: 0;
-			width: 100%;
-			box-shadow: 0rpx -4rpx 10rpx 0rpx rgba(195, 195, 195, 0.3);
-			background: #fff;
-		}
-	}
-
-	.shoppop {
-		padding: 22rpx 16rpx;
-
-		.shoppop-top {
-			display: flex;
-			justify-content: space-between;
-			align-items: center;
-			padding: 0 16rpx 22rpx;
-
-			.search-input {
-				width: 414rpx;
-				height: 76rpx;
-				background: #FFFFFF;
-				border-radius: 36rpx;
-				margin-left: 20rpx;
-				padding: 0 32rpx;
-				box-sizing: border-box;
-				font-size: 24rpx;
-				margin-right: 24rpx;
-
-			}
-
-			.search-top {
-				font-size: 18rpx;
-				color: #222222;
-			}
-		}
-
-
-		.shop-list {
-			overflow: hidden;
-
-			.list-item {
-				display: flex;
-				align-items: center;
-				padding: 20rpx 16rpx;
-				background: #FFFFFF;
-				border-radius: 16rpx;
-				margin-bottom: 16rpx;
-
-				.goods-img {
-					width: 200rpx;
-					height: 200rpx;
-					border-radius: 16rpx;
-					overflow: hidden;
-					position: relative;
-					margin-right: 24rpx;
-
-					image {
-						width: 100%;
-						height: 100%;
-					}
-
-					.goods-label {
-						position: absolute;
-						top: 0;
-						width: 64rpx;
-						height: 40rpx;
-						background: rgba(0, 0, 0, 0.5);
-						border-radius: 16rpx 0rpx 16rpx 0rpx;
-						text-align: center;
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #FFFFFF;
-					}
-				}
-
-				.goods-right {
-					flex: 1;
-
-					.goods-title {
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #000000;
-
-					}
-
-					.goods-details {
-						font-size: 24rpx;
-						color: #999999;
-						margin: 10rpx 0 20rpx;
-					}
-
-					.goods-people {
-						font-size: 22rpx;
-						color: #E69A22;
-						height: 56rpx;
-					}
-
-					.goods-shop {
-						display: flex;
-						justify-content: space-between;
-
-						.nummber {
-							color: #FF5C03;
-							font-size: 22rpx;
-							font-weight: 500;
-						}
-
-						.btn-group {
-							text-align: center;
-							line-height: 56rpx;
-
-							.collect-btn {
-								width: 72rpx;
-								background: #F5F7FA;
-								border-radius: 8rpx 0rpx 0rpx 8rpx;
-
-							}
-
-							.shop-btn {
-								width: 152rpx;
-								background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-								border-radius: 0rpx 8rpx 8rpx 0rpx;
-								font-weight: 500;
-								font-size: 26rpx;
-								color: #FFFFFF;
-
-							}
-						}
-					}
-				}
-			}
-		}
-	}
-
-	:deep(.u-list-item) {
-		width: 100%;
-		display: flex;
-		align-items: center;
-	}
-
-	:deep(.u-safe-area-inset-bottom) {
-		padding-bottom: 0
-	}
-</style>

+ 0 - 2141
pages_no/living.vue

@@ -1,2141 +0,0 @@
-<template>
-	<view class="container">
-		<!-- <view class="popup-video " v-if="!autoplay">
-			<view class="fs36 bold" v-if="livedata.status==1">——直播还未开始——</view>
-			<view class="fs36 bold" v-if="livedata.status==3">——直播已经结束——</view>
-			<view class="fs28 mtb20">了解更多,点击下方联系老师</view>
-			<view class="more" @click="showadd=!showadd">联系老师</view>
-		</view> -->
-
-		<!-- <image :src="livedata.liveImgUrl"
-	 :class="livedata.status!=2?'background-images':'background-image'"></image> -->
-		<view class="blackbg"></view>
-		<view class="content">
-			<!-- 页面内容 -->
-			<view style=" position: fixed;top: 0;z-index: 5;" class="content-top">
-				<view class="u-flex-y-center">
-					<image @click="goBack" style="width: 60rpx;height: 64rpx;margin-right: 26rpx;"
-						src="@/static/images/live/return.png"></image>
-					<view class=" align-center"
-						style="padding: 6rpx 4rpx;height: 64rpx;background: rgba(0,0,0,0.5);border-radius: 32rpx;">
-						<u-avatar :src="livedata.liveImgUrl||$img.logo" size="32"></u-avatar>
-						<view class="colorf" style="margin-left: 8rpx;">
-							<view>{{livedata.liveName?truncateString(livedata.liveName,5):"未命名"}}</view>
-							<view style="font-size: 16rpx;">
-								{{ liveViewData.follow || liveViewData.follow === 0 ? liveViewData.follow : 0 }}位粉丝
-							</view>
-						</view>
-						<view v-if="isFollow" @click="onFollow" class="follow-btn ml20">关注</view>
-						<view v-else @click="onFollow" class="follow-btn ml20">已关注</view>
-					</view>
-				</view>
-				<view class="u-flex-end align-center" @click="showadd=!showadd">
-					<image class="w52 h52 mr4" v-for="(item,index) in filteredViewers" :key="index"
-						style="border-radius: 26rpx;" :src="item.avatar||$img.logo"></image>
-					<view class="sum">{{liveUserTotal||0}}</view>
-				</view>
-			</view>
-
-			<!-- 页面内容 -->
-			<view style=" position: fixed;top:100rpx;left: 0rpx; z-index: 5;" class="content-top">
-				<view class="u-flex-y-center">
-					<image @click="onRed" v-if="redInfo?.redStatus==1" style="width: 70rpx;height: 70rpx;"
-						src="@/static/images/hongbao.png"></image>
-				</view>
-
-			</view>
-
-			<!-- 右边的 -->
-			<view :class=" showType==1 ? 'siderow-group' : 'side-group'">
-				<view class="side-item">
-					<image @click="onLike" src="/static/images/live/like.png"></image>
-					<view>{{liveViewData.like||0}}</view>
-				</view>
-				<view class="side-item">
-					<image @click="goStore()" src="/static/images/live/shop.png"></image>
-					<view>店铺</view>
-				</view>
-
-				<view class="side-item">
-					<button open-type="share">
-						<image src="/static/images/live/share.png" mode="widthFix"></image>
-					</button>
-					<view>分享</view>
-				</view>
-
-			</view>
-
-			<view class="shop-prompt u-flex-y-center" v-if="showPurchasePrompt&&orderUser?.count">
-				<image class="w32 h32 mr8" src="/static/images/live/shopping.png"></image>
-				<text> {{orderUser.userName ? maskString(orderUser.userName) : ''}} 等 {{orderUser.count || 0}}
-					人正在去购买</text>
-			</view>
-
-			<!-- object-fit:fill; -->
-			<view class="videolist " style="margin: auto 0">
-				<!-- <view class="video" :style="{height:isScreen?'100vh':''}"> -->
-				<view class="video" style="height:100vh">
-					<!-- 修改video组件以支持HLS -->
-					<!-- showType 1 横屏   2 竖屏 -->
-					<video v-if="livingUrl" id="myVideo" :class="showType == 1 ? 'video_row' : 'videotop'"
-						:src="livingUrl" :autoplay="autoplay" :controls='false' object-fit='contain'
-						:custom-cache="false" :enable-progress-gesture="false" vslide-gesture-in-fullscreen='true'
-						:show-center-play-btn="false" :http-cache="false" @error="videoError">
-					</video>
-
-					<video v-if="videoUrl" :class="showType == 1 ? 'video_row' : 'videotop'" :src="videoUrl"
-						:autoplay="autoplay" :controls='false' object-fit='contain' :custom-cache="false"
-						:enable-progress-gesture="false" vslide-gesture-in-fullscreen='true'
-						:show-center-play-btn="false" :http-cache="false" loop @error="videoError">
-					</video>
-				</view>
-			</view>
-			<view class="pb40  mt90" style="position: fixed;bottom: 0;">
-				<view class="w100 h300 mt20">
-					<scroll-view enable-flex scroll-y="true" class="talk p20 scrolly flex-1 column"
-						style="width: calc(100% - 40rpx);height: calc(100% - 40rpx);"
-						:scroll-into-view="scrollIntoView">
-						<view>
-							<view class="list justify-start" v-for="(item,index) in talklist" :key="index"
-								 v-show="item.cmd=='announcement'">
-								<view class="talk-list ml16 justify-start">
-									<view class="fs24">
-										<text class='fs24 colorf'> {{item.msg}}直播间{{messageContent}}</text>
-									</view>
-								</view>
-							</view>
-						</view>
-
-
-						<view class="list justify-start" v-for="(item,index) in talklist" :key="index"
-							:id="`list_${index}`" v-show="item.cmd!='red'&&item.cmd!='out'&&item.cmd!='entry'">
-							<view class="talk-list ml16 justify-start">
-								<view class="fs24">
-									<!-- <text style="color: #3fc69b;transform: scale(0.8);display: inline-block; "v-if="item.userId==userinfo.userId&&item.cmd=='sendMsg'">我</text> -->
-									<!-- <text style="color: #c84e1e;transform: scale(0.8);display: inline-block;" v-if="item.userType==1">[ 管理员 ]</text> -->
-									<text style="color: #FFDA73;">{{item.nickName}}:</text>
-									<text class='fs24 colorf'>{{item.msg}}</text>
-								</view>
-							</view>
-						</view>
-						<view v-if="showWelcomeMessage" class="welcome-message">
-							<view class="list justify-start" v-for="(item,index) in talklist" :key="index"
-								 v-show="item.cmd=='entry'||item.cmd=='out'">
-								<view class="talk-list ml16 justify-start">
-									<view class="fs24">
-										<text style="color: #ff89d6;">{{item.nickName}} </text>
-										<text class='fs24 colorf'> {{item.msg}}直播间{{messageContent}}</text>
-									</view>
-								</view>
-							</view>
-						</view>
-					</scroll-view>
-				</view>
-
-				<view class="justify-between p24">
-					<view class="u-flex-y-center"
-						style="background:rgba(157, 157, 157, 0.8);padding:18rpx 14rpx 18rpx 32rpx;width: 526rpx;box-sizing:border-box;border-radius:36rpx;">
-						<u-input :placeholder="placeholderText" border="none" customStyle='font-size:24rpx;'
-							v-model="value" shape='circle' color='#fff' placeholderStyle='color:#e7e7e7' class="ml20"
-							@keydown.enter="sendMsg" @confirm="sendMsg">
-						</u-input>
-						<!-- <image @click="sendMsg" class="w44 h44" src="@/static/images/live/like.png"></image> -->
-					</view>
-					<!-- :disabled='talkdisabled' ></u-input> -->
-					<!-- <view @click="sendMsg" class="colorf center ml10 fs24">发送</view> -->
-					<view class="justify-between mr30  align-center">
-						<!-- <view class="icon-bg ml20" @click="answerbtn=!answerbtn">
-							<image src="/static/images/redbag.png" class="w40 h40"></image>
-						</view> -->
-						<view class="icon-bg ml20" @click="shopping=!shopping">
-							<image src="/static/images/shopping.png" class="w48 h48"></image>
-						</view>
-						<view class="icon-bg ml20" @click="showziliao=!showziliao">
-							<image src="/static/images/more-icon.png" class="w48 h48"></image>
-						</view>
-						<!-- <view class="icon-bg ml20" :class="{ 'zoom-button-active': isZoom }"
-							@touchstart="handleTouchStart" @touchend="handleTouchEnd">
-							<image src="/static/images/dianzan.png" class="w40 h40"></image>
-						</view> -->
-					</view>
-				</view>
-			</view>
-		</view>
-
-		<!-- <u-popup :show="showadd" @close="close" @open="open" round='20rpx' bgColor='#fffee1'>
-			<view class="addchat p20">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="showadd=!showadd"></u-icon>
-				</view>
-				<view class="column align-center">
-					<view class="fs36" style="color: #ff5c03;">扫码添加助教老师</view>
-					<view class="fs28 color6">扫码添加助教老师</view>
-					<view class="p10 mt40" style="border: #ff5c03 solid 2rpx;">
-						<image :src="codeimg" class="wh180" @touchstart="longPress" @touchend="cancelLongPress">
-						</image>
-					</view>
-					<view class="color6 mt20">长按识别二维码</view>
-				</view>
-			</view>
-		</u-popup> -->
-		<u-popup :show="showadd" @close="close" @open="openViews" round='20rpx' bgColor='#ffffff'>
-			<view class="view-box">
-				<view class="t-c fs30">在线观众</view>
-				<scroll-view scroll-y class="scroll-content" :style="{height: scrollHeight + 'px'}"
-					@scrolltolower="handleScrollToLower">
-					<view class="fs24 u-flex-y-center mb20" v-for="(item,index) in liveViewers" :key="index">
-						<view
-							:style="{color: index === 0 ? '#FF3B30' : index === 1 ? '#FF9500' : index === 2 ? '#FFCC00' :  '#8E8E93',fontWeight: index < 3 ? 'bold' : 'normal',width: '50rpx'}"
-							class="mr10">{{index+1}}</view>
-						<u-avatar :src="item.avatar||$img.logo" size="32"></u-avatar>
-						<text class="ml16">{{item.nickName||"未命名"}}</text>
-					</view>
-					<!-- <view class="loading-more" v-if="viewLoading">
-					    <u-loading mode="circle"></u-loading>
-					    <text>加载中...</text>
-					  </view> -->
-					<view class="no-more" v-if="viewNoMoreData && liveViewers.length > 0">
-						<text>没有更多了</text>
-					</view>
-				</scroll-view>
-				<view class="fs24 u-flex-y-center bottom">
-					<view class="mr10" style="width:50rpx">我</view>
-					<u-avatar :src="livedata.liveImgUrl||$img.logo" size="32"></u-avatar>
-					<text class="ml16">{{livedata.liveName||"未命名"}}</text>
-				</view>
-
-			</view>
-		</u-popup>
-		<!-- <u-popup :show="showziliao" @close="closes" round='20' bgColor='#fffee1'>
-			<view class="addchat p20 bgf" style="border-radius: 20rpx;">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="showziliao=!showziliao"></u-icon>
-				</view>
-				<view class="column align-center h400">
-					<view class="fs36 " style="color: #ff5c03;">资料</view>
-					<view v-html="livedata.liveDesc"></view>
-				</view>
-			</view>
-		</u-popup> -->
-
-
-
-		<!-- 抽奖 -->
-		<!-- <u-popup :show="answerbtn" @close="closeanswer" round='40rpx' bgColor='#fff'>
-			<view class=" p20 bgf" style="border-radius: 40rpx;height: fit-content;">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="answerbtn=!answerbtn"></u-icon>
-				</view>
-				<view class="column align-center h400">
-					<view class="fs36 " style="color: #000000;font-weight: bold;">答题获取红包/积分奖励</view>
-					<view class="answerpop" @click="noredanswer">
-						<view class="color6 w350 fs24">
-							边玩边学,解锁你的知识巅峰!
-						</view>
-						<view class="answera">答题挑战</view>
-					</view>
-					<view class="answerpop">
-
-						<view class="color6 fs24" v-if='redanswertips&&redanswertips.length>0'>
-							🔥 <text style="color: #ff5c03;" class="fs30 bold">{{redanswertips[1].probability}}</text>
-							%用户首抽得
-							<text style="color: #ff5c03;" class="fs40 bold">{{redanswertips[1].maxAmount}}</text>元
-						</view>
-						<view v-else class="color6 w350 fs24">
-							随机奖励
-						</view>
-						<view class="answera" @click="redbagAnswer">
-							<image src="/static/images/baganswer.png"></image>
-							<view> 获得红包</view>
-						</view>
-					</view>
-				</view>
-			</view>
-		</u-popup> -->
-
-
-		<!-- <u-popup :show="showAnswer" @close="closest" round='40' bgColor='#fffee1' mode="center">
-			<view class="answerbox p20 bgf">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="closest"></u-icon>
-				</view>
-				<view class="column align-center ">
-					<view v-if="answerlist.type==1" style="width: 100%;">
-						<view class="mb40" style="text-align: center;">
-							<text class="color9 fs24">(单选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue[0]== item.label?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-					</view>
-					<view v-if="answerlist.type==2" style="width: 100%;">
-						<view class="mb40 " style="text-align: center;">
-							<text class="color9 fs24">(多选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue.includes(item.label)?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-						<view class=" submitbtn" @click="submitAnswers">确认</view>
-					</view>
-					<view class="fs24 mtb20 " style="color: #717171;">
-						{{answerfrist+1}}/{{Answerlistall}}
-					</view>
-				</view>
-			</view>
-		</u-popup> -->
-
-
-		<!-- 	<u-popup :show="showAnswerred" @close="closestred" round='40' bgColor='#fffee1' mode="center">
-			<view class="answerbox p20 bgf">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="closestred"></u-icon>
-				</view>
-				<view class="column align-center ">
-					<view v-if="answerlist.type==1" style="width: 100%;">
-						<view class="mb40" style="text-align: center;">
-							<text class="color9 fs24">(单选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue[0]== item.label?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-					</view>
-					<view v-if="answerlist.type==2" style="width: 100%;">
-						<view class="mb40 " style="text-align: center;">
-							<text class="color9 fs24">(多选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue.includes(item.label)?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-						<view class=" submitbtn" @click="submitAnswers">确认</view>
-					</view>
-					<view class="fs24 mtb20 " style="color: #717171;">
-						{{answerfrist+1}}/{{Answerlistall}}
-					</view>
-				</view>
-			</view>
-		</u-popup> -->
-
-		<!-- 小黄车弹窗 -->
-		<u-popup :show="shopping" @close="closeShop" @open="openShop" round='20rpx' bgColor='#f3f5f9'>
-			<view class="shoppop">
-				<view class="shoppop-top">
-					<u-avatar :src="store.logoUrl" size="36" class="ml16"></u-avatar>
-					<view class="search-input u-flex-y-center">
-						<image style="width: 24rpx;height: 24rpx;margin-right: 16rpx;" src="@/static/images/search.png">
-						</image>
-						<input placeholder="请搜索商品" v-model="inputInfo" @input="handleSearchInput" />
-					</view>
-					<view class="t-c search-top" style="margin-right: 48rpx;">
-						<image @click="onStoreCollect" v-if="store.isFavorite" style="width: 32rpx;height: 32rpx;"
-							src="@/static/images/collect_select.png"></image>
-						<image v-else @click="onStoreCollect" style="width: 32rpx;height: 32rpx;"
-							src="@/static/images/collect.png"></image>
-						<view>收藏</view>
-					</view>
-					<view class="t-c search-top" @click="goOrderList">
-						<image style="width: 32rpx;height: 32rpx;" src="@/static/images/order.png"></image>
-						<view>订单</view>
-					</view>
-				</view>
-
-				<scroll-view enable-flex scroll-y class="shop-list" :style="{ height: boxHeight + 'px' }">
-					<view class="list-item " v-for="(item,index) in products" :key="index">
-						<view class="goods-img">
-							<image :src="item.imgUrl" mode="widthFix"></image>
-							<view class="goods-label">{{index+1}}</view>
-						</view>
-						<view class="goods-right">
-							<view class="goods-title">{{item.productName}}</view>
-							<!-- <view class="goods-details">{{item.productIntroduce}}</view> -->
-							<view class="goods-people">{{item.sales}} 人已购</view>
-							<view class="goods-shop">
-								<text class="nummber"><text style="font-size: 20rpx;font-weight: 600;">¥</text><text
-										style="font-size: 36rpx;font-weight: bold;">{{Math.trunc(item.price)}}</text>.{{getPureDecimal(item.price)?getPureDecimal(item.price):'00'}}/日</text>
-								<view class="btn-group  u-flex-y-center">
-									<view class="collect-btn">
-										<image v-if="item.isFavorite" @click="onGoodsCollect(item)"
-											style="width: 32rpx;height: 32rpx;" src="/static/images/collect_select.png">
-										</image>
-										<image v-else @click="onGoodsCollect(item)" style="width: 32rpx;height: 32rpx;"
-											src="/static/images/collect.png">
-										</image>
-									</view>
-									<view v-if="item.status==1" class="shop-btn"
-										@click="goShop(item.productId,item.goodsId)">去购买
-									</view>
-									<view v-else-if="item.status==0" @click="goShop(item.productId)" class="shop-btn">
-										已下架</view>
-								</view>
-							</view>
-						</view>
-					</view>
-				</scroll-view>
-			</view>
-		</u-popup>
-		<!-- 红包 -->
-		<!-- <u-popup :show="showRed" mode="center" @close="closeRed" round='20rpx' @open="openRed" bgColor='#ff3833'>
-			<view class="red-box" style="width: 500rpx;height: 500rpx; ">
-				<view class="button">立即领取</view>
-			</view>
-		</u-popup> -->
-	</view>
-</template>
-
-<script>
-	import Hls from 'hls.js';
-	import CryptoJS from 'crypto-js'
-	import {
-		liveList
-	} from '@/api/list'
-	import {
-		liveRed, // 点击领红包
-		liveDataLike, // 点赞
-		collectStore, // 店铺收藏/取消收藏
-		collectGoods, // 商品收藏/取消收藏
-		store, // 查询店铺
-		follow, // 关注/取消关注
-		watchUserList, //获取直播间用户(展示在线用户)
-		liveMsg, //获取最近聊天记录
-		// 小黄车
-		liveStore, //店铺展示,
-		// liveGoodsDetail, //商品详情,
-		liveOrderUser, //正在购买
-		getLiveInfo, //获取直播间信息接口
-		getLiveViewData //直播间点赞、关注、在线人数数据
-	} from '@/api/live'
-	import {
-		liveOrderList, // 订单列表
-	} from '@/api/order'
-
-	import parse from '../../uni_modules/uview-plus/libs/config/props/parse';
-	import {
-		LiveWS
-	} from '@/utils/liveWS.js'
-	import {
-		getlive,
-		// gettextlist,
-		getAnswerlist,
-		submitAnswer
-	} from '@/api/home'
-	// var wsUrl = "ws://192.168.10.166:7114/app/webSocket";
-
-	// var wsUrl = "ws://192.168.10.166:7114/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.125:7114/app/webSocket"; //涂小龙
-	var wsUrl = "wss://live.test.ylrztop.com/ws/live-api/app/webSocket"; //余红奇
-	// var wsUrl = "ws://nd383294.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://v56c9b8e.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.170:7114/app/webSocket"; //陈果
-	// var wsUrl = "ws://live.ylrzcloud.com/socket/app/webSocket";
-	var pingpangTimes = null;
-	var initTimes = null;
-	var isSocketOpen = false;
-	var socket = null;
-
-	export default {
-		data() {
-			return {
-				liveUserTotal: null,
-				viewPageSize: 10, // 每页数量
-				viewPageNum: 1, // 当前页码
-				viewLoading: false, // 是否正在加载
-				viewNoMoreData: false, // 是否没有更多数据
-				scrollHeight: 0,
-				scrollTimer: null, // 滚动防抖定时器
-
-
-				socketInstance: null, // 统一管理 socket 实例
-				reconnectCount: 0,
-				maxReconnectAttempts: 3,
-				isManualClose: false, // 标记是否手动关闭
-
-				showRed: true,
-				redInfo: {},
-				inputInfo: '',
-				searchTimer: null,
-				storeId: null,
-				reconnectCount: 0,
-				maxReconnectAttempts: 3,
-				reconnectTimer: null,
-				isCollect: false,
-				showPurchasePrompt: false,
-				purchasePromptTimer: null,
-				prevOrderCount: 0, // 用于记录上一次的购买人数
-				videoUrl: null,
-				showType: 1, //横屏1 竖屏2
-				boxHeight: 300, //小黄车高度
-				isFollow: true,
-				liveViewData: {},
-				liveViewers: [], //观众
-				likeName: 0,
-				hlsPlayer: null, // HLS播放器实例,
-				livingUrl: "",
-				products: {},
-				store: {},
-				orderUser: {}, //正在购买
-				userType: 0,
-				timestamp: '',
-				liveId: null,
-				// userId: uni.getStorageSync("userInfo.userId"),
-				codeimg: '',
-				placeholderText: '说点什么...',
-				isZoom: false, //点赞按钮控制是否放大
-				userinfo: '', //用户信息
-				// path: 'http://192.168.10.166/dev-api', //余红奇
-				// path: 'http://v56c9b8e.natappfree.cc', //余红奇
-				// path: 'live.test.ylrztop.com/prod-api', //余红奇
-				// path: 'http://192.168.10.170/dev-api', //陈果
-				value: '',
-				talkdisabled: false, //输入框是否禁用
-				autoplay: false, //视频自动播放
-				showadd: false,
-				talklist: [],
-				scrollIntoView: '',
-				bufferRate: 0, //视频缓冲时间
-				playDuration: 0, //视频播放时间
-				videoContext: '',
-				thistime: uni.$u.timeFormat(new Date(), 'yyyy-mm-dd hh:MM:ss'),
-				upDown: true, //是否视频显示隐藏
-				isLongPress: false, // 是否长按
-				timeout: null, // 计时器
-				showWelcomeMessage: false,
-				isSubmit: false,
-				messageContent: "",
-				showziliao: false,
-				isScreen: true,
-				showAnswer: false, //展示答题
-				Answerlistall: {}, //所有题目
-				answerlist: {}, //当前题目
-				answerfrist: 0, //当前选择
-				checkboxValue: [], //多选数据
-				checkboxFormValue: "", //多选数据
-				allAnswerLists: [], // 新增:存储所有题目列表
-				showAnswerred: false, //展示红包答题
-				answerbtn: false, //答题按钮弹窗
-				redallAnswerLists: [], //储存所有红包答题列表
-				redanswerAll: [], //红包当前题目
-				redanswerList: [], //红包答题列表
-				redanswertips: [], //红包答题提示
-				shopping: false, //小黄车弹窗
-				scrollTop: 0, //弹幕
-				old: {
-					scrollTop: 0
-				},
-				livedata: {}, //直播间点赞、关注、在线人数数据
-
-			};
-		},
-
-
-		onLoad(options) {
-			this.userinfo = JSON.parse(uni.getStorageSync("userInfo"))
-			if (options.liveId) {
-				this.liveId = options.liveId; // 仅当 liveId 变化时更新
-			}
-			uni.showShareMenu({
-				withShareTicket: true
-			});
-		},
-		onShareAppMessage() {
-			return {
-				// title: this.product.title,
-				title: this.livedata.liveName,
-				path: '/pages/home/index',
-				imageUrl: this.products.image,
-				success(res) {
-					console.log("分享成功", res);
-				},
-				fail(err) {
-					console.error("分享失败", err);
-				}
-			};
-		},
-		computed: {
-			filteredViewers() {
-				if (!this.liveViewers) {
-					return
-				} else {
-					return this.liveViewers.slice(0, 3);
-				}
-
-			}
-		},
-		mounted() {
-			this.getLiveMsg() // 获取最近聊天记录
-			// this.onLike()
-			this.getliveViewData() ////直播间点赞、关注、在线人数数据
-
-			// this.intervalId = setInterval(() => {
-			// 	this.getliveViewData();
-			// }, 60 * 1000);
-			// this.getLiveinformation() // 获取直播间信息接口
-			this.getliveOrder() //正在购买
-			// this.getliveStore() // 获取小黄车 店铺展示
-			// this.getliveGoods() // 获取小黄车 商品详情
-			this.getliveUser() // 获取直播间用户
-			this.initTime()
-			// this.initWebSocket()
-			this.initSocket()
-			var that = this;
-			uni.$on('initSocket', () => {
-				that.initSocket()
-			})
-			uni.$on('sendMsg', (item) => {
-				that.sendMsg(item)
-			})
-			uni.$on('closeWebSocket', () => {
-				that.closeWebSocket()
-			})
-			this.getEWechatSdk();
-
-			this.getliving() //hls
-			// this.gettalklist()
-			// this.getAnswerlists()
-
-		},
-		onReady: function(res) {
-			this.videoContext = uni.createVideoContext('myVideo')
-			// console.log(this.videoContext)
-		},
-		onHide() {
-			clearInterval(this.intervalId); // 页面隐藏时清理
-		},
-		onUnload() {
-			this.closeWebSocket();
-			uni.$off('refreshOrder');
-			clearInterval(this.intervalId);
-
-			if (this.hlsPlayer) {
-				this.hlsPlayer.destroy(); // 清理 HLS 播放器
-			}
-			if (this.pingpangTimes) {
-				clearInterval(this.pingpangTimes); // 清除心跳定时器
-			}
-
-		},
-		watch: {
-			// 监听orderUser.count的变化
-			'orderUser.count': {
-				handler(newVal, oldVal) {
-					if (newVal !== this.prevOrderCount) {
-						this.prevOrderCount = newVal;
-						this.showPurchaseMessage();
-					}
-				},
-				immediate: true
-			}
-		},
-		methods: {
-			// 获取直播间列表
-			getList() {
-				const data = {
-					page: 1,
-					page_size: 10,
-				};
-				uni.showLoading({
-					title: "处理中..."
-				});
-				liveList(data)
-					.then(res => {
-						if (res.code == 200) {
-							this.list = res.rows; // 直接赋值给 this.list
-							console.log("list>>", this.list); // ✅ 打印已定义的 this.list
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					})
-					.catch(rej => {
-						console.log("请求失败:", JSON.stringify(rej));
-					})
-					.finally(() => {
-						uni.hideLoading();
-					});
-			},
-			openViews() {
-				// 计算scroll-view高度
-				this.$nextTick(() => {
-					const query = uni.createSelectorQuery().in(this);
-					query.select('.view-box').boundingClientRect(data => {
-						if (data) {
-							// 减去标题和底部固定区域的高度
-							this.scrollHeight = data.height - 80 - 120; // 80是标题高度,120是底部高度
-						}
-					}).exec();
-				});
-			},
-
-
-			// 获取直播间用户
-			async getliveUser(isLoadMore = false) {
-				if (this.viewLoading || this.viewNoMoreData) return;
-
-				this.viewLoading = true;
-
-				try {
-					const res = await watchUserList(this.liveId, this.viewPageSize, this.viewPageNum, false);
-
-					if (res.code == 200) {
-						this.liveUserTotal = res.total
-						if (res.rows.length === 0) {
-							this.viewNoMoreData = true;
-							if (this.viewPageNum > 1) {
-								uni.showToast({
-									title: '没有更多数据了',
-									icon: 'none'
-								});
-							}
-							return;
-						}
-
-						if (isLoadMore) {
-							// 加载更多时追加数据
-							this.liveViewers = [...this.liveViewers, ...res.rows];
-						} else {
-							// 首次加载或刷新
-							this.liveViewers = res.rows;
-						}
-
-						// 只有成功获取数据后才增加页码
-						this.viewPageNum++;
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-					}
-				} catch (error) {
-					console.error('获取观众列表失败:', error);
-					uni.showToast({
-						title: '获取数据失败',
-						icon: 'none'
-					});
-				} finally {
-					this.viewLoading = false;
-				}
-			},
-			// 滚动到底部触发
-			handleScrollToLower() {
-				// 清除上一次未执行的定时器,避免重复请求
-				if (this.scrollTimer) {
-					clearTimeout(this.scrollTimer);
-				}
-
-				// 延迟0.5秒(500毫秒)执行接口请求
-				this.scrollTimer = setTimeout(() => {
-					this.getliveUser(true); // 加载更多数据
-				}, 1000); // 延迟时间:500毫秒
-			},
-			// gettalklist() {
-			// 	if (!this.liveId) return;
-			// 	const param = {
-			// 		id: this.liveId
-			// 	}
-			// 	gettextlist(param).then(res => {
-			// 		if (res.code == 200) {
-			// 			this.talklist = res.data
-			// 			// console.log(res.data);
-			// 			this.$nextTick(() => {
-			// 				this.scrollIntoView = `list_${this.talklist.length-1}`
-			// 			})
-			// 		}
-			// 	})
-			// },
-			// 获取最近聊天记录
-			getLiveMsg() {
-				if (!this.liveId) return;
-				let pageSize = 30
-				let pageNum = 1
-				liveMsg(this.liveId, pageSize, pageNum).then(res => {
-					if (res.code == 200) {
-						// 使用Vue.set或直接赋值确保响应式更新
-						this.talklist = [...res.rows] // 使用展开运算符创建新数组
-						console.log("获取最近聊天记录>>", this.talklist)
-						this.$nextTick(() => {
-							this.scrollIntoView = `list_${this.talklist.length-1}`
-							console.log('应该滚动到:', this.scrollIntoView)
-						})
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-					}
-				});
-			},
-			// 点击红包
-			onRed() {
-				console.log("点了")
-
-				if (!this.liveId) return;
-				console.log("点了this.liveId", this.liveId)
-				if (!this.redInfo?.redId) return;
-				console.log("点了this.redInfo?.redId", this.redInfo.redId)
-				console.log("点了this.userinfo.userId", this.userinfo.userId)
-				let data = {
-					liveId: this.liveId,
-					userId: this.userinfo.userId,
-					redId: this.redInfo.redId,
-				}
-				liveRed(data).then(res => {
-						if (res.code == 200) {} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			handleSearchInput() {
-				// 使用防抖优化性能,避免频繁请求
-				clearTimeout(this.searchTimer);
-				this.searchTimer = setTimeout(() => {
-					this.queryCollect();
-				}, 500); // 500毫秒延迟
-			},
-			// 显示购买提示信息
-			showPurchaseMessage() {
-				// 清除之前的定时器
-				if (this.purchasePromptTimer) {
-					clearTimeout(this.purchasePromptTimer);
-				}
-
-				// 显示提示
-				this.showPurchasePrompt = true;
-
-				// 2秒后自动隐藏
-				this.purchasePromptTimer = setTimeout(() => {
-					this.showPurchasePrompt = false;
-				}, 2000);
-			},
-			truncateString(str, maxLength) {
-				return str.length > maxLength ? str.slice(0, maxLength) + '...' : str;
-			},
-			goStore() {
-				console.log("带过去storeId", this.storeId)
-				uni.navigateTo({
-					url: '/pages_shop/store?liveId=' + this.liveId + "&storeId=" + this.storeId
-				})
-			},
-			// 去订单列表
-			goOrderList() {
-				uni.navigateTo({
-					url: "/pages_shop/order"
-				})
-			},
-
-			// 初始化HLS播放器
-			initHlsPlayer() {
-				if (Hls.isSupported() && this.livingUrl) {
-					const video = document.getElementById('myVideo');
-					if (video) {
-						this.hlsPlayer = new Hls();
-						this.hlsPlayer.loadSource(this.livingUrl);
-						this.hlsPlayer.attachMedia(video);
-						this.hlsPlayer.on(Hls.Events.MANIFEST_PARSED, () => {
-							video.play();
-						});
-					}
-				}
-			},
-
-			// 视频错误处理
-			videoError(e) {
-				console.error('视频播放错误:', e.detail.errMsg);
-				// 尝试重新加载或切换到备用流
-				if (this.livingUrl) {
-					setTimeout(() => {
-						this.videoContext.play();
-					}, 2000);
-				}
-			},
-
-			getliving() {
-				if (!this.liveId) return;
-				console.log("获取直播信息");
-				const param = {
-					id: this.liveId
-				};
-
-				getlive(param).then(res => {
-					if (res.code !== 200) {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none',
-							duration: 2000
-						});
-						return;
-					}
-
-					this.livedata = res.data;
-					this.showType = res.data.showType;
-					this.storeId = res.storeId
-					this.queryCollect() //查询店铺
-					console.log("横屏1或竖屏2", this.showType)
-					// 1. 根据直播类型设置播放地址
-					if (res.data.liveType === 2) {
-						// 回放视频
-						this.videoUrl = res.data.videoUrl;
-						this.autoplay = true;
-						// this.placeholderText = "观看回放中";
-						this.placeholderText = "说点什么...";
-						this.talkdisabled = false;
-					} else if (res.data.liveType === 1) {
-						// 直播流
-						this.livingUrl = res.data.flvHlsUrl;
-						this.autoplay = true;
-						this.placeholderText = "说点什么...";
-						this.talkdisabled = false;
-					} else {
-						// 未开播
-						this.livingUrl = "";
-						this.autoplay = false;
-						this.placeholderText = "直播未开始,暂时无法发言";
-						this.talkdisabled = true;
-						return;
-					}
-
-					// 2. 根据不同平台处理播放逻辑
-					this.$nextTick(() => {
-						if (!this.livingUrl) return;
-
-						// H5 平台:使用 HLS.js 处理 .m3u8 流
-						// #ifdef H5
-						if (this.livingUrl.includes('.m3u8')) {
-							this.initHlsPlayer();
-							return;
-						}
-						// #endif
-
-						// 小程序/App 平台:直接使用 video 组件
-						if (!this.videoContext) {
-							this.videoContext = uni.createVideoContext('myVideo', this);
-						}
-
-						if (res.data.liveType === 1) {
-							// 回放:跳转到指定位置
-							this.videoContext.seek(res.data.nowDuration || 0);
-						} else {
-							// 直播:直接播放
-							this.videoContext.play();
-						}
-					});
-				}).catch(err => {
-					console.error("获取直播信息失败:", err);
-					uni.showToast({
-						title: "获取直播信息失败",
-						icon: 'none'
-					});
-				});
-			},
-			maskString(str, maskChar = '*') {
-				// 新增:如果str是undefined或null,直接返回空字符串
-				if (!str) return '';
-				// 确保str是字符串(如果是数字等类型,先转为字符串)
-				const strVal = String(str);
-				return strVal.split('').map((char, index) => (index === 0 ? char : maskChar)).join('');
-			},
-
-			getPureDecimal(num, precision = 6) {
-				const decimalPart = Math.abs(num).toFixed(precision).split('.')[1];
-				return decimalPart?.replace(/0+$/, '') || ''; // 移除末尾多余的0
-			},
-
-			// 返回上一个页面并关闭WebSocket
-			goBack() {
-				const pages = getCurrentPages();
-				// 如果页面栈长度大于1,说明有上一页可以返回
-				this.closeWebSocket();
-				if (pages.length > 1) {
-					uni.navigateBack();
-				} else {
-					// 如果没有上一页,跳转到默认页面(比如首页)
-					uni.switchTab({
-						url: '/pages/list/index' // 替换为你的首页路径
-					});
-
-				}
-
-			},
-
-			//直播间点赞、关注、在线人数数据
-			getliveViewData() {
-				if (!this.liveId) return;
-				getLiveViewData(this.liveId).then(res => {
-						if (res.code == 200) {
-							// console.log("直播间点赞、关注、在线人数数据>>>>", res)
-							this.liveViewData = res
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			//正在购买
-			getliveOrder() {
-				if (!this.liveId) return;
-				liveOrderUser(this.liveId).then(res => {
-						if (res.code == 200) {
-							console.log("正在购买>>>>", res)
-							this.orderUser = res
-
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			//小黄车 店铺展示
-			// getliveStore() {
-			// 	if (!this.liveId) return;
-			// 	let data = {
-			// 		pageSize: 10,
-			// 		page: 1
-			// 	}
-			// 	liveStore(this.liveId, data).then(res => {
-			// 			if (res.code == 200) {
-			// 				console.log("小黄车 店铺展示>>>>", res)
-			// 				this.products = res.data
-			// 				this.queryCollect()
-			// 			} else {
-			// 				uni.showToast({
-			// 					title: res.msg,
-			// 					icon: 'none'
-			// 				});
-			// 			}
-			// 		},
-			// 		rej => {}
-			// 	);
-			// },
-			// 获取直播间信息接口
-			getLiveinformation() {
-				if (!this.liveId) return;
-				getLiveInfo(this.liveId).then(res => {
-						if (res.code == 200) {
-							console.log("获取直播间信息接口>>>>", res)
-							this.livingUrl = res.livingUrl
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-
-
-			// 点赞
-			onLike() {
-				if (!this.liveId) return;
-				liveDataLike(this.liveId).then(res => {
-						if (res.code == 200) {
-							if (res.like) {
-								this.liveViewData.like++
-							} else {
-								uni.showToast({
-									title: res.msg,
-									icon: 'none'
-								});
-							}
-
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-
-			},
-			// 去购买,跳商品详情
-			goShop(productId, goodsId) {
-				uni.navigateTo({
-					url: '/pages_shop/goods?productId=' + productId + '&liveId=' + this.liveId + '&goodsId=' +
-						goodsId + '&storeId=' + this.storeId
-				})
-			},
-
-			// 查询店铺
-			queryCollect() {
-				if (!this.storeId) return;
-				store(this.storeId, this.inputInfo).then(res => {
-						if (res.code == 200) {
-							console.log("查询店铺>>", res)
-							this.products = res.data.goodsList
-							this.store = res.data
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 店铺收藏
-			onStoreCollect() {
-				if (!this.storeId) return;
-				collectStore(this.storeId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							this.store.isFavorite = !this.store.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 商品收藏
-			onGoodsCollect(item) {
-				if (!item || item.length === 0 || !item.goodsId) {
-					return;
-				}
-				collectGoods(item.goodsId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							item.isFavorite = !item.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 关注
-			onFollow() {
-				if (!this.liveId) return;
-				follow(this.liveId).then(res => {
-						this.isFollow = !this.isFollow
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-					},
-					rej => {}
-				);
-			},
-			// 时间戳
-			initTime() {
-				const now = new Date();
-				this.timestamp = now.getTime(); // 例如:'2023-04-01 12:00:00'
-			},
-			// initWebSocket() {
-			//       const liveWS = new LiveWS('ws://your-server.com', 123, 456);
-
-			//       // 从 URL 中解析 timestamp
-			//       const urlParams = new URL(liveWS.url).searchParams;
-			//       this.timestamp = urlParams.get('timestamp');
-			//       // console.log('Timestamp:', timestamp);
-			//     },
-
-			// 弹幕滚动
-			lowerChat: function(e) {
-				console.log(e)
-			},
-			scroll: function(e) {
-				console.log(e)
-				this.old.scrollTop = e.detail.scrollTop
-			},
-
-
-			loadmore() {
-				// for (let i = 0; i < 30; i++) {
-				//   this.indexList.push({
-				//     url: this.shopList[uni.$u.random(0, this.shopList.length - 1)],
-				//   });
-				// }
-			},
-
-			// 弹幕
-			scrollchat() {
-				// this.loadmore();
-			},
-
-
-			noredanswer() {
-				if (this.Answerlistall > 0) {
-					this.showAnswer = !this.this.showAnswer
-				} else {
-					uni.showToast({
-						title: '暂无题目',
-						icon: 'none',
-					});
-				}
-			},
-			redbagAnswer() {
-				this.showAnswerred = !this.showAnswerred
-				this.answerbtn = !this.answerbtn
-
-			},
-			submitAnswers() {
-				if (this.isSubmit) return;
-				this.isSubmit = true;
-				const data = {
-					questionId: this.answerlist.id,
-					answer: this.checkboxFormValue
-				}
-				submitAnswer(data).then(res => {
-					if (res.code == 200) {
-
-						uni.showToast({
-							title: res.msg,
-							icon: 'none',
-						});
-					}
-					// 本地切换下一题
-					if (this.answerfrist < this.Answerlistall - 1) {
-						this.answerfrist++;
-						this.answerlist = this.allAnswerLists[this.answerfrist];
-						this.answerlist.content = JSON.parse(this.answerlist.content);
-					} else {
-						uni.showToast({
-							title: '已是最后一题',
-							icon: 'none'
-						});
-						this.showAnswer = false; // 自动关闭弹窗
-					}
-					this.checkboxValue = []
-					this.checkboxFormValue = "";
-					uni.showToast({
-						title: res.msg,
-						icon: 'none'
-					});
-				}).finally(e => {
-					this.isSubmit = false;
-				})
-			},
-			// handleCheckboxSelect(value) {
-			// 	const index = this.checkboxValue.indexOf(value)
-			// 	console.log(value)
-			// 	if (this.answerlist.type == 1) {
-			// 		this.checkboxValue = [value]
-			// 		this.checkboxFormValue = this.checkboxValue.join(',')
-			// 		setTimeout(() => {
-			// 		      uni.showToast({
-			// 		        title: '准备下一题',
-			// 		        icon: 'none',
-			// 		        duration: 2000
-			// 		      });
-			// 		    }, 1000);
-			// 		this.submitAnswers()
-			// 		console.log(this.checkboxValue)
-			// 	} else if (this.answerlist.type == 2) {
-			// 		if (index > -1) {
-			// 			this.checkboxValue.splice(index, 1)
-			// 			this.checkboxFormValue = this.checkboxValue.join(',')
-			// 		} else {
-			// 			this.checkboxValue.push(value)
-			// 			this.checkboxFormValue = this.checkboxValue.join(',')
-			// 		}
-			// 		console.log(this.checkboxFormValue)
-			// 	}
-			// },
-			getAnswerlists() {
-				if (!this.liveId) return;
-				const data = {
-					liveId: this.liveId
-				}
-				getAnswerlist(data).then(res => {
-					if (res.code == 200) {
-						if (res.data.length > 0) {
-							this.allAnswerLists = res.data; // 存储所有题目
-							this.Answerlistall = res.data.length;
-							if (this.allAnswerLists.length > 0) {
-								this.answerlist = this.allAnswerLists[0];
-								this.answerlist.content = JSON.parse(this.allAnswerLists[0].content);
-							}
-							this.showAnswer = true
-						} else {
-							this.showAnswer = false
-						}
-
-					}
-				})
-			},
-
-			openShop() {
-
-			},
-			openViews() {
-
-			},
-			close() {
-				this.showadd = !this.showadd
-			},
-			closes() {
-				this.showziliao = !this.showziliao
-			},
-			closest() {
-				this.showAnswer = !this.showAnswer
-			},
-			closestred() {
-				this.showAnswerred = !this.showAnswerred
-			},
-			closeanswer() {
-				this.answerbtn = !this.answerbtn
-			},
-			// 关闭小黄车
-			closeShop() {
-				this.shopping = !this.shopping
-			},
-			// 关闭红包
-			closeRed() {
-				this.showRed = !this.showRed
-			},
-			// longPress() {
-			// 	this.timeout = setTimeout(() => {
-			// 		this.isLongPress = true;
-			// 		// 执行保存图片的操作
-			// 		uni.saveImageToPhotosAlbum({
-			// 			filePath: this.livedata.qwQrCode, // 图片的本地路径或网络路径
-			// 			success: () => {
-			// 				uni.showToast({
-			// 					title: '保存成功'
-			// 				});
-			// 			},
-			// 			fail: () => {
-			// 				uni.showToast({
-			// 					title: '',
-			// 					icon: 'none'
-			// 				});
-			// 			}
-			// 		});
-			// 	}, 500); // 设置长按的阈值时间,这里是500毫秒
-			// },
-			// cancelLongPress() {
-			// 	clearTimeout(this.timeout);
-			// 	this.isLongPress = false;
-			// },
-			// 触摸开始
-			handleTouchStart() {
-				this.isZoom = true; // 触发放大效果
-			},
-			// 触摸结束
-			handleTouchEnd() {
-				this.isZoom = false; // 恢复原状
-			},
-			getEWechatSdk() {
-				// 只在H5平台执行
-				// #ifdef H5
-				let eWechatSdk = '';
-				if (/(Android)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'jWeixin';
-				} else if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'wx';
-				} else {
-					eWechatSdk = 'jWeixin';
-				}
-				uni.setStorageSync("wxSdk", eWechatSdk);
-				// #endif
-			},
-			closeWebSocket() {
-				this.isManualClose = true;
-
-				// 清除所有定时器
-				clearInterval(this.pingpangTimes);
-				clearTimeout(this.reconnectTimer);
-
-				// 关闭 WebSocket 连接
-				if (this.socketInstance) {
-					try {
-						uni.closeSocket();
-						console.log('WebSocket 已安全关闭');
-					} catch (e) {
-						console.error('关闭 WebSocket 时出错:', e);
-					}
-					this.socketInstance = null;
-				}
-				isSocketOpen = false;
-			},
-			reConnect() {
-				var that = this;
-				try {
-					uni.closeSocket();
-				} catch (e) {
-
-				}
-				setTimeout(function() {
-					that.initSocket();
-				}, 10000);
-
-			},
-			startHeartbeat() {
-				clearInterval(this.pingpangTimes);
-
-				this.pingpangTimes = setInterval(() => {
-					if (!isSocketOpen) return;
-
-					const pingData = {
-						cmd: 'ping',
-						timestamp: Date.now()
-					};
-					uni.sendSocketMessage({
-						data: JSON.stringify(pingData),
-						success: () => console.debug('心跳发送成功'),
-						fail: (err) => {
-							console.error('心跳发送失败:', err);
-							this.scheduleReconnect();
-						}
-					});
-				}, 30000); // 30秒心跳间隔
-			},
-			initSocket() {
-				// 防止重复创建
-				if (isSocketOpen || this.reconnectCount >= this.maxReconnectAttempts) {
-					return;
-				}
-
-				this.closeWebSocket(); // 确保先关闭旧连接
-				this.isManualClose = false;
-
-				// 参数校验
-				if (!this.liveId) {
-					return;
-				}
-
-				// 生成签名
-				const signature = CryptoJS.HmacSHA256(
-					`${this.liveId}${this.userinfo.userId}${this.userType}${this.timestamp}`,
-					this.timestamp.toString()
-				).toString(CryptoJS.enc.Hex);
-
-				// 创建连接
-				try {
-					this.socketInstance = uni.connectSocket({
-						url: `${wsUrl}?userId=${this.userinfo.userId}&liveId=${this.liveId}&userType=${this.userType}&timestamp=${this.timestamp}&signature=${signature}`,
-						success: () => {
-							// 事件监听统一管理
-							this.setupSocketListeners();
-						},
-						fail: (err) => {
-							console.error('WebSocket 连接失败:', err);
-							this.scheduleReconnect();
-						}
-					});
-				} catch (e) {
-					console.error('创建 WebSocket 异常:', e);
-					this.scheduleReconnect();
-				}
-			},
-
-			// 设置 WebSocket 监听器
-			setupSocketListeners() {
-				uni.onSocketOpen(() => {
-					isSocketOpen = true;
-					this.reconnectCount = 0;
-					console.log('WebSocket 连接成功');
-					this.startHeartbeat();
-				});
-
-				uni.onSocketClose(() => {
-					isSocketOpen = false;
-					console.log('WebSocket 连接关闭');
-					if (!this.isManualClose) {
-						this.scheduleReconnect();
-					}
-				});
-
-				uni.onSocketError((err) => {
-					isSocketOpen = false;
-					console.error('WebSocket 错误:', err);
-					if (!this.isManualClose) {
-						this.scheduleReconnect();
-					}
-				});
-
-				uni.onSocketMessage((res) => {
-					try {
-						const redata = JSON.parse(res.data);
-						this.talklist.push(redata.data);
-						this.$nextTick(() => {
-							this.scrollIntoView = `list_${this.talklist.length - 1}`; // 最后一项的id
-						});
-						if (redata.data.cmd == 'deleteId') {
-							uni.$emit('deleteId');
-						}
-
-						// else if (redata.data.cmd == 'init') {
-						// 	uni.$emit('init', redata.data);
-						// } else if (redata.data.cmd == 'reload') {
-						// 	uni.$emit('reload');
-						// }
-						else if (redata.data.cmd == 'red') {
-							// 领红包
-							this.redInfo = JSON.parse(redata.data.data)
-							console.log(" 领红包1redata.data>>", redata.data)
-							console.log(" 领红包2redata.data.data>>", redata.data.data)
-							console.log(" 领红包3this.redInfo>>", this.redInfo)
-							console.log(" 领红包4this.redInfo.redId>>", this.redInfo.redId)
-							// let redId= this.redInfo.redId
-							// this.redInfo.redNum=redata.data.redNum
-							// this.redInfo.redStatus=redata.data.redStatus
-							// this.redInfo.duration=redata.data.duration
-
-						} else if (redata.data.cmd == 'sendRedPacketQuestion') {
-							const list = JSON.parse(redata.data.data)
-							this.redanswerAll = [...this.redanswerAll, ...list]
-							if (this.redanswerAll[1].randomAmount !== null) {
-								this.redanswertips = JSON.parse(this.redanswerAll[0]
-									.randomAmount)
-							}
-							console.log(this.redanswertips)
-							console.log(this.redanswerAll)
-						} else if (redata.data.cmd == 'entry') {
-							this.showWelcomeMessage = true
-							// setTimeout(() => {
-							// 	this.showWelcomeMessage = false;
-							//   }, 1000);
-							uni.$emit('entry', redata.data);
-						} else if (redata.data.cmd == 'live_start') {
-              // 直播开始
-						} else if (redata.data.cmd == 'live_end') {
-              // 直播结束
-						}
-					} catch (e) {
-						console.error('解析消息失败:', e);
-					}
-				})
-			},
-			scheduleReconnect() {
-				if (this.isManualClose || this.reconnectCount >= this.maxReconnectAttempts) return;
-
-				this.reconnectCount++;
-				const delay = Math.min(3000 * this.reconnectCount, 30000);
-
-				console.log(`将在 ${delay}ms 后重连 (尝试 ${this.reconnectCount}/${this.maxReconnectAttempts})`);
-
-				this.reconnectTimer = setTimeout(() => {
-					this.initSocket();
-				}, delay);
-			},
-			sendMsg() {
-				if (!isSocketOpen) {
-					uni.showToast({
-						title: "连接未建立,请稍后再试",
-						icon: 'none'
-					});
-					return;
-				}
-
-				if (!this.socketInstance) {
-					uni.showToast({
-						title: "连接异常",
-						icon: 'none'
-					});
-					return;
-				}
-
-				const data = {
-					liveId: this.liveId,
-					userId: this.userinfo.userId,
-					userType: 0,
-					cmd: "sendMsg",
-					msg: this.value,
-					nickName: this.userinfo.nickName,
-					avatar: this.userinfo.avatar
-				};
-
-				if (!this.value.trim()) { // 优化空消息判断
-					uni.showToast({
-						title: "不能发送空消息",
-						icon: 'none'
-					});
-					return;
-				}
-
-				// 使用正确的实例 this.socketInstance 发送消息
-				this.socketInstance.send({
-					data: JSON.stringify(data),
-					success: () => {
-						console.log("发送成功");
-						this.value = ''; // 清空输入框
-					},
-					fail: (err) => {
-						console.error("发送失败:", err);
-						uni.showToast({
-							title: "发送失败,请重试",
-							icon: 'none'
-						});
-					}
-				});
-			},
-		},
-	};
-</script>
-
-<style scoped lang="scss">
-	.loading-more,
-	.no-more {
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		padding: 20rpx 0;
-		color: #999;
-		font-size: 24rpx;
-	}
-
-	.loading-more {
-		flex-direction: column;
-	}
-
-	/* button自带样式清除 */
-	.student-orther-icon button::after {
-		border: none !important;
-		padding: 0 !important;
-		margin: 0 !important;
-	}
-
-	.student-orther-icon button {
-		background-color: transparent !important;
-		padding: 0 !important;
-		line-height: inherit !important;
-		margin: 0 !important;
-		width: auto !important;
-		font-weight: 500 !important;
-		border-radius: none !important;
-	}
-
-	// 抽奖
-	// .answerpop {
-	// 	background: linear-gradient(to right, #fff7f8, #fee1e2);
-	// 	margin-top: 30rpx;
-	// 	padding: 10rpx 20rpx;
-	// 	width: calc(100% - 40rpx);
-	// 	border-radius: 20rpx;
-	// 	display: flex;
-	// 	align-items: center;
-	// 	justify-content: space-between;
-	// 	box-shadow: 2px 2px 4px 0 rgba(255, 124, 126, 0.1);
-
-	// 	.answera {
-	// 		display: flex;
-	// 		justify-content: center;
-	// 		background-color: #fff;
-	// 		padding: 20rpx 0;
-	// 		width: 35%;
-	// 		border-radius: 40rpx;
-	// 		align-items: center;
-	// 		margin: 10rpx 0;
-	// 		box-shadow: 2px 2px 4px 0 rgba(72, 72, 72, 0.1);
-
-	// 		image {
-	// 			width: 40rpx;
-	// 			height: 40rpx;
-	// 			margin-right: 10rpx;
-	// 		}
-	// 	}
-	// }
-
-	// .submitbtn {
-	// 	width: 260rpx;
-	// 	margin: 0 auto;
-	// 	text-align: center;
-	// 	border-radius: 80rpx;
-	// 	padding: 20rpx 0;
-	// 	color: #fff;
-	// 	background-color: #ff5c03;
-	// }
-
-	// .itemanswer {
-	// 	padding: 20rpx 20rpx;
-	// 	text-align: center;
-	// 	border-radius: 80rpx;
-	// 	border: 2rpx solid #dddddd;
-	// 	margin: 12rpx 0;
-	// 	color: #555;
-	// 	width: calc(100% - 40rpx);
-	// }
-
-	// .answeract {
-	// 	background-color: rgba(0, 202, 166, 1);
-	// 	color: #fff;
-	// }
-
-	// .answerbox {
-	// 	width: 600rpx;
-	// 	border-radius: 20rpx;
-	// }
-
-	.welcome-message {
-		position: fixed;
-		width: 100%;
-		bottom: 460rpx;
-		left: 50%;
-		transform: translateX(-50%);
-		color: white;
-		padding: 10px 20px;
-		border-radius: 20px;
-		animation: fadeOut 1s ease 1s forwards;
-		z-index: 1000;
-	}
-
-	@keyframes fadeOut {
-		from {
-			opacity: 1;
-		}
-
-		to {
-			opacity: 0;
-		}
-	}
-
-	// .container {
-	// 	position: relative;
-	// 	width: 100%;
-	// 	height: 100vh;
-	// 	overflow: hidden;
-	// }
-
-	// .talktext {
-	// 	border-radius: 8rpx;
-	// 	background-color: rgba(255, 255, 255, 0.1);
-
-	// 	view {
-	// 		width: 100%;
-	// 	}
-	// }
-
-	.talk-list {
-		border-radius: 30rpx;
-		background-color: rgba(33, 33, 33, 0.5);
-		padding: 10rpx 30rpx;
-	}
-
-	// .zoom-button-active {
-	// 	transform: scale(1.5);
-	// }
-
-	// .background-image {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 0;
-	// }
-
-	// .background-images {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 6;
-	// }
-
-	// .blackbg {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: 0;
-	// 	width: 100%;
-	// 	height: 100%;
-	// 	background: rgba(0, 0, 0, 0.7);
-	// 	object-fit: cover;
-	// 	filter: blur(10px);
-	// 	z-index: 1;
-	// }
-
-	.content {
-		position: relative;
-		z-index: 2;
-		height: 100%;
-		width: 100%;
-		top: 0;
-		left: 0;
-		display: flex;
-		flex-direction: column;
-		justify-content: space-between;
-
-		.content-top {
-			width: 100%;
-			margin-top: 150rpx;
-			display: flex;
-			align-items: center;
-			justify-content: space-between;
-			padding: 0 24rpx;
-			box-sizing: border-box;
-
-			.sum {
-				width: 80rpx;
-				height: 52rpx;
-				background: rgba(0, 0, 0, 0.5);
-				border-radius: 26rpx 26rpx 26rpx 26rpx;
-				font-size: 24rpx;
-				color: #FFFFFF;
-				text-align: center;
-				line-height: 52rpx;
-
-			}
-		}
-
-		.follow-btn {
-			padding: 8rpx 16rpx;
-			background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-			border-radius: 26rpx;
-			font-weight: 500;
-			font-size: 26rpx;
-			color: #FFFFFF;
-		}
-	}
-
-	.videolist {
-		position: relative;
-	}
-
-	.video {
-		height: 100vh;
-		/* 占屏幕高度的80% */
-		width: 100%;
-		background-color: rgba(0, 0, 0, 0.8);
-	}
-
-	.videotop {
-		width: 100%;
-		height: 100%;
-	}
-
-	.video_row {
-		width: 100%;
-		max-height: 500rpx;
-		overflow: hidden;
-		margin-top: 360rpx;
-	}
-
-	.popup-video {
-		position: absolute;
-		top: 30%;
-		height: 500rpx;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		justify-content: center;
-		width: 100%;
-		color: #fff;
-		z-index: 9;
-
-		.more {
-			background-color: #3280fe;
-			border-radius: 80rpx;
-			width: 280rpx;
-			text-align: center;
-			height: 60rpx;
-			line-height: 60rpx;
-		}
-	}
-
-	.icon-bg {
-		background-color: rgba(157, 157, 157, 0.8);
-		border-radius: 50%;
-		width: 72rpx;
-		height: 72rpx;
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		transition: transform 0.2s ease;
-	}
-
-	.list {
-		width: 80%;
-		margin-bottom: 20rpx;
-		animation: xxxawdawd .2s;
-	}
-
-	@keyframes xxxawdawd {
-		from {
-			margin-top: 0rpx;
-			opacity: 0;
-		}
-
-		to {
-			margin-top: 20rpx;
-			opacity: 1;
-		}
-	}
-
-	.shop-prompt {
-		position: absolute;
-		bottom: 600rpx;
-		left: 24rpx;
-		padding: 6rpx 20rpx;
-		background: rgba(230, 154, 34, 0.7);
-		border-radius: 24rpx;
-		z-index: 9;
-		font-weight: 500;
-		font-size: 26rpx;
-		color: #FFFFFF;
-		transition: opacity 0.3s ease;
-	}
-
-	.siderow-group {
-		position: absolute;
-		top: 56%;
-		right: 50rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-	}
-
-	.side-group {
-		position: absolute;
-		// top: 30%;
-		top: 56%;
-		right: 50rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-
-
-	}
-
-	.red-box {
-		.button {
-			margin: 0 auto;
-			width: 80%;
-			line-height: 88rpx;
-			height: 88rpx;
-			background: linear-gradient(90deg, #FF5701 0%, #FFB501 100%);
-			box-shadow: 0rpx 8rpx 8rpx 0rpx rgba(238, 124, 80, 0.2);
-			border-radius: 44rpx 44rpx 44rpx 44rpx;
-			font-weight: 600;
-			font-size: 32rpx;
-			color: #FFFFFF;
-			text-align: center;
-		}
-	}
-
-	.view-box {
-		position: relative;
-		height: 40vh;
-		/* 设置弹出层高度为视窗高度的70% */
-		padding: 40rpx 0rpx 120rpx;
-		box-sizing: border-box;
-		display: flex;
-		flex-direction: column;
-
-		.scroll-content {
-			flex: 1;
-			overflow-y: auto;
-			padding: 0 40rpx;
-		}
-
-		.bottom {
-			padding: 20rpx 40rpx;
-			position: absolute;
-			bottom: 0;
-			width: 100%;
-			box-shadow: 0rpx -4rpx 10rpx 0rpx rgba(195, 195, 195, 0.3);
-			background: #fff;
-		}
-	}
-
-	.shoppop {
-		padding: 22rpx 16rpx;
-
-		.shoppop-top {
-			display: flex;
-			justify-content: space-between;
-			align-items: center;
-			padding: 0 16rpx 22rpx;
-
-			.search-input {
-				width: 414rpx;
-				height: 76rpx;
-				background: #FFFFFF;
-				border-radius: 36rpx;
-				margin-left: 20rpx;
-				padding: 0 32rpx;
-				box-sizing: border-box;
-				font-size: 24rpx;
-				margin-right: 24rpx;
-
-			}
-
-			.search-top {
-				font-size: 18rpx;
-				color: #222222;
-			}
-		}
-
-
-		.shop-list {
-			overflow: hidden;
-
-			.list-item {
-				display: flex;
-				align-items: center;
-				padding: 20rpx 16rpx;
-				background: #FFFFFF;
-				border-radius: 16rpx;
-				margin-bottom: 16rpx;
-
-				.goods-img {
-					width: 200rpx;
-					height: 200rpx;
-					border-radius: 16rpx;
-					overflow: hidden;
-					position: relative;
-					margin-right: 24rpx;
-
-					image {
-						width: 100%;
-						height: 100%;
-					}
-
-					.goods-label {
-						position: absolute;
-						top: 0;
-						width: 64rpx;
-						height: 40rpx;
-						background: rgba(0, 0, 0, 0.5);
-						border-radius: 16rpx 0rpx 16rpx 0rpx;
-						text-align: center;
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #FFFFFF;
-					}
-				}
-
-				.goods-right {
-					flex: 1;
-
-					.goods-title {
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #000000;
-
-					}
-
-					.goods-details {
-						font-size: 24rpx;
-						color: #999999;
-						margin: 10rpx 0 20rpx;
-					}
-
-					.goods-people {
-						font-size: 22rpx;
-						color: #E69A22;
-						height: 56rpx;
-					}
-
-					.goods-shop {
-						display: flex;
-						justify-content: space-between;
-
-						.nummber {
-							color: #FF5C03;
-							font-size: 22rpx;
-							font-weight: 500;
-						}
-
-						.btn-group {
-							text-align: center;
-							line-height: 56rpx;
-
-							.collect-btn {
-								width: 72rpx;
-								background: #F5F7FA;
-								border-radius: 8rpx 0rpx 0rpx 8rpx;
-
-							}
-
-							.shop-btn {
-								width: 152rpx;
-								background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-								border-radius: 0rpx 8rpx 8rpx 0rpx;
-								font-weight: 500;
-								font-size: 26rpx;
-								color: #FFFFFF;
-
-							}
-						}
-					}
-				}
-			}
-		}
-	}
-
-	:deep(.u-list-item) {
-		width: 100%;
-		display: flex;
-		align-items: center;
-	}
-
-	:deep(.u-safe-area-inset-bottom) {
-		padding-bottom: 0
-	}
-</style>

+ 0 - 2251
pages_no/living827.vue

@@ -1,2251 +0,0 @@
-<template>
-	<view class="swiper-wrapper">
-		<swiper class="swiper-container" :current="currentSwiperIndex" :circular="false" vertical
-			@change="onSwiperChange" :style="{height: '100vh'}" :duration="swiperDuration">
-			<swiper-item v-for="(liveItem, index) in list" :key="liveItem.liveId">
-				<view class="container" :class="{active: currentSwiperIndex === index}">
-					<view class="blackbg"></view>
-					<view class="content">
-						<!-- 页面内容 -->
-						<view style=" position: fixed;top: 0;z-index: 5;" class="content-top">
-							<view class="u-flex-y-center">
-								<image @click="goBack" style="width: 60rpx;height: 64rpx;margin-right: 26rpx;"
-									src="@/static/images/live/return.png"></image>
-								<view class=" align-center"
-									style="padding: 6rpx 4rpx;height: 64rpx;background: rgba(0,0,0,0.5);border-radius: 32rpx;">
-									<u-avatar :src="liveItem.liveImgUrl||$img.logo" size="32"></u-avatar>
-									<view class="colorf ml10 mr6">
-										<view>{{liveItem.liveName?truncateString(liveItem.liveName,5):"未命名"}}</view>
-									</view>
-								</view>
-							</view>
-							<view class="u-flex-end align-center" @click="showadd=!showadd" style="margin-top: 100rpx;">
-								<image class="w52 h52 mr4" v-for="(item,viewerIndex) in filteredViewers"
-									:key="viewerIndex" style="border-radius: 26rpx;" :src="item.avatar||$img.logo">
-								</image>
-								<view class="sum">{{liveUserTotal||0}}</view>
-							</view>
-						</view>
-
-						<!-- 页面内容 -->
-						<view style=" position: fixed;top:120rpx;left: 0rpx; z-index: 5;" class="content-top">
-							<view class="u-flex-y-center">
-								<image @click="onRed(liveItem)" v-if="liveItem.redInfo?.redStatus==1"
-									style="width: 70rpx;height: 70rpx;" src="@/static/images/hongbao.png"></image>
-							</view>
-						</view>
-
-						<!-- 右边的 -->
-						<view :class=" liveItem.showType==1 ? 'siderow-group' : 'side-group'">
-							<view class="side-item">
-								<image @click="onLike(liveItem)" src="/static/images/live/like.png"></image>
-								<view>{{liveItem.liveViewData?.like||0}}</view>
-							</view>
-							<view class="side-item">
-								<image @click="goStore(liveItem)" src="/static/images/live/shop.png"></image>
-								<view>店铺</view>
-							</view>
-
-							<view class="side-item">
-								<button open-type="share">
-									<image src="/static/images/live/share.png" mode="widthFix"></image>
-								</button>
-								<view>分享</view>
-							</view>
-						</view>
-
-						<view class="shop-prompt u-flex-y-center" v-if="showPurchasePrompt&&orderUser?.count">
-							<image class="w32 h32 mr8" src="/static/images/live/shopping.png"></image>
-							<text> {{orderUser.userName ? maskString(orderUser.userName) : ''}} 等
-								{{orderUser.count || 0}}
-								人正在去购买</text>
-						</view>
-
-						<view class="videolist " style="margin: auto 0">
-							<view class="video" style="height:100vh">
-								<!-- 修改video组件以支持HLS -->
-								<!-- showType 1 横屏   2 竖屏 -->
-								<video v-if="liveItem.livingUrl" :id="'myVideo_' + liveItem.liveId"
-									:class="liveItem.showType == 1 ? 'video_row' : 'videotop'" :src="liveItem.livingUrl"
-									:autoplay="currentSwiperIndex === index" :controls='false' object-fit='contain'
-									:custom-cache="false" :enable-progress-gesture="false"
-									vslide-gesture-in-fullscreen='true' :show-center-play-btn="false"
-									:http-cache="false" @error="videoError">
-								</video>
-
-								<video v-if="liveItem.videoUrl"
-									:class="liveItem.showType == 1 ? 'video_row' : 'videotop'" :src="liveItem.videoUrl"
-									:autoplay="currentSwiperIndex === index" :controls='false' object-fit='contain'
-									:custom-cache="false" :enable-progress-gesture="false"
-									vslide-gesture-in-fullscreen='true' :show-center-play-btn="false"
-									:http-cache="false" loop @error="videoError">
-								</video>
-
-								<!-- 加载提示 -->
-								<view v-if="liveItem.loading" class="loading-tip">
-									<u-loading mode="circle" color="#ffffff" size="36"></u-loading>
-									<text class="loading-text">加载中...</text>
-								</view>
-							</view>
-						</view>
-						<view class="pb40  mt90" style="position: fixed;bottom: 0;width: 100%;">
-							<view class="w100 h300 mt20">
-								<scroll-view enable-flex scroll-y="true" class="talk p20 scrolly flex-1 column"
-									style="width: calc(100% - 40rpx);height: calc(100% - 40rpx);"
-									:scroll-into-view="liveItem.scrollIntoView">
-									<view>
-										<view class="list justify-start" v-for="(item,talkIndex) in liveItem.talklist"
-											:key="talkIndex" v-show="item.cmd=='announcement'">
-											<view class="talk-list ml16 justify-start">
-												<view class="fs24">
-													<text class='fs24 colorf'>
-														{{item.msg}}直播间{{liveItem.messageContent}}</text>
-												</view>
-											</view>
-										</view>
-									</view>
-
-									<view class="list justify-start" v-for="(item,talkIndex) in liveItem.talklist"
-										:key="talkIndex" :id="`list_${talkIndex}`"
-										v-show="item.cmd!='red'&&item.cmd!='out'&&item.cmd!='entry'">
-										<view class="talk-list ml16 justify-start">
-											<view class="fs24">
-												<text style="color: #FFDA73;">{{item.nickName}}:</text>
-												<text class='fs24 colorf'>{{item.msg}}</text>
-											</view>
-										</view>
-									</view>
-									<view v-if="liveItem.showWelcomeMessage" class="welcome-message">
-										<view class="list justify-start" v-for="(item,talkIndex) in liveItem.talklist"
-											:key="talkIndex" v-show="item.cmd=='entry'||item.cmd=='out'">
-											<view class="talk-list ml16 justify-start">
-												<view class="fs24">
-													<text style="color: #ff89d6;">{{item.nickName}} </text>
-													<!-- <text class='fs24 colorf'>
-														{{item.msg}}直播间{{liveItem.messageContent}}</text> -->
-													<text class='fs24 colorf'>
-														{{item.msg}}直播间{{liveItem.messageContent}}</text>
-												</view>
-											</view>
-										</view>
-									</view>
-								</scroll-view>
-							</view>
-
-							<view class="justify-between p24">
-								<view class="u-flex-y-center"
-									style="background:rgba(157, 157, 157, 0.8);padding:10rpx 14rpx 10rpx 32rpx;width: 566rpx;box-sizing:border-box;border-radius:36rpx;">
-									<u-input :placeholder="liveItem.placeholderText" border="none"
-										customStyle='font-size:24rpx;' v-model="liveItem.value" shape='circle'
-										color='#fff' placeholderStyle='color:#e7e7e7' class="ml20"
-										>
-										<!-- @confirm="sendMsg(liveItem)" -->
-									</u-input>
-									<view class="send" @click="sendMsg(liveItem)">发送</view>
-								</view>
-								<view class="justify-between mr15  align-center">
-									<view class="icon-bg ml20" @click="openCart(liveItem)">
-										<image src="/static/images/shopping.png" class="w48 h48"></image>
-									</view>
-									<!-- <view class="icon-bg ml20" @click="liveItem.showziliao=!liveItem.showziliao">
-										<image src="/static/images/more-icon.png" class="w48 h48"></image>
-									</view> -->
-								</view>
-							</view>
-						</view>
-					</view>
-
-					<!-- 弹窗组件保持不变 -->
-					<u-popup :show="showadd" @close="close" @open="openViews" round='20rpx' bgColor='#ffffff'>
-						<view class="view-box">
-							<view class="t-c fs30">在线观众</view>
-							<scroll-view scroll-y class="scroll-content" :style="{height: scrollHeight + 'px'}"
-								@scrolltolower="handleScrollToLower">
-								<view class="fs24 u-flex-y-center mb20" v-for="(item,index) in liveViewers"
-									:key="index">
-									<view
-										:style="{color: index === 0 ? '#FF3B30' : index === 1 ? '#FF9500' : index === 2 ? '#FFCC00' :  '#8E8E93',fontWeight: index < 3 ? 'bold' : 'normal',width: '50rpx'}"
-										class="mr10">{{index+1}}</view>
-									<u-avatar :src="item.avatar||$img.logo" size="32"></u-avatar>
-									<text class="ml16">{{item.nickName||"未命名"}}</text>
-								</view>
-								<view class="no-more" v-if="viewNoMoreData && liveViewers.length > 0">
-									<text>没有更多了</text>
-								</view>
-							</scroll-view>
-							<!-- <view class="fs24 u-flex-y-center bottom">
-								<view class="mr10" style="width:50rpx">我</view>
-								<u-avatar :src="livedata.liveImgUrl||$img.logo" size="32"></u-avatar>
-								<text class="ml16">{{livedata.liveName||"未命名"}}</text>
-							</view> -->
-						</view>
-					</u-popup>
-
-					<u-popup :show="liveItem.shopping" @close="closeShop" @open="openShop" round='20rpx'
-						bgColor='f3f5f9'>
-						<view class="shoppop">
-							<view class="shoppop-top">
-								<u-avatar :src="store.logoUrl" size="36" class="ml16"></u-avatar>
-								<view class="search-input u-flex-y-center">
-									<image style="width: 24rpx;margin-right: 16rpx;" src="@/static/images/search.png"
-										mode="widthFix">
-									</image>
-									<input placeholder="请搜索商品" v-model="liveItem.inputInfo"
-										@input="handleSearchInput" />
-								</view>
-								<view class="t-c search-top" style="margin-right: 48rpx;">
-									<image @click="onStoreCollect(liveItem)" v-if="store.isFavorite"
-										style="width:40rpx;height: 40rpx;" src="@/static/images/collect_select.png">
-									</image>
-									<image v-else @click="onStoreCollect(liveItem)" style="width: 32rpx;height: 32rpx;"
-										src="@/static/images/collect.png"></image>
-									<view>收藏</view>
-								</view>
-								<view class="t-c search-top" @click="goOrderList(liveItem)">
-									<image style="width: 40rpx;height: 40rpx;" src="@/static/images/order.png"></image>
-									<view>订单</view>
-								</view>
-							</view>
-
-							<scroll-view enable-flex scroll-y class="shop-list" :style="{ height: boxHeight + 'px' }">
-								<view class="list-item " v-for="(item,index) in products" :key="index">
-									<view class="goods-img">
-										<image :src="item.imgUrl" mode="widthFix"></image>
-										<view class="goods-label">{{index+1}}</view>
-									</view>
-									<view class="goods-right">
-										<view class="goods-title">{{item.productName}}</view>
-										<view class="goods-people">{{item.sales}} 人已购</view>
-										<view class="goods-shop">
-											<text class="nummber"><text
-													style="font-size: 20rpx;font-weight: 600;">¥</text><text
-													style="font-size: 36rpx;font-weight: bold;">{{Math.trunc(item.price)}}</text>.{{getPureDecimal(item.price)?getPureDecimal(item.price):'00'}}/日</text>
-											<view class="btn-group  u-flex-y-center">
-												<view class="collect-btn">
-													<image v-if="item.isFavorite" @click="onGoodsCollect(item)"
-														style="width: 32rpx;height: 32rpx;"
-														src="/static/images/collect_select.png">
-													</image>
-													<image v-else @click="onGoodsCollect(item)"
-														style="width: 32rpx;height: 32rpx;"
-														src="/static/images/collect.png">
-													</image>
-												</view>
-												<view v-if="item.status==1" class="shop-btn"
-													@click="goShop(item.productId,item.goodsId)">去购买
-												</view>
-												<view v-else-if="item.status==0" @click="goShop(item.productId)"
-													class="shop-btn">
-													已下架</view>
-											</view>
-										</view>
-									</view>
-								</view>
-							</scroll-view>
-						</view>
-					</u-popup>
-				</view>
-			</swiper-item>
-		</swiper>
-	</view>
-</template>
-
-<script>
-	import Hls from 'hls.js';
-	import CryptoJS from 'crypto-js'
-	import {
-		liveList
-	} from '@/api/list'
-	import {
-		liveRed, // 点击领红包
-		liveDataLike, // 点赞
-		collectStore, // 店铺收藏/取消收藏
-		collectGoods, // 商品收藏/取消收藏
-		store, // 查询店铺
-		// follow, // 关注/取消关注
-		watchUserList, //获取直播间用户(展示在线用户)
-		liveMsg, //获取最近聊天记录
-		// 小黄车
-		liveStore, //店铺展示,
-		// liveGoodsDetail, //商品详情,
-		liveOrderUser, //正在购买
-		getLiveInfo, //获取直播间信息接口
-		getLiveViewData //直播间点赞、关注、在线人数数据
-	} from '@/api/live'
-	import {
-		liveOrderList, // 订单列表
-	} from '@/api/order'
-
-	import parse from '/uni_modules/uview-plus/libs/config/props/parse';
-	import {
-		LiveWS
-	} from '@/utils/liveWS.js'
-	import {
-		getlive,
-		// gettextlist,
-		getAnswerlist,
-		submitAnswer
-	} from '@/api/home'
-
-	// var wsUrl = "ws://192.168.10.166:7114/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.125:7114/app/webSocket"; //涂小龙
-	var wsUrl = "wss://live.test.ylrztop.com/ws/live-api/app/webSocket"; //余红奇
-	// var wsUrl = "ws://live.test.ylrztop.com/prod-api/app/webSocket"; //余红奇
-	// var wsUrl = "ws://nd383294.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://v56c9b8e.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.170:7114/app/webSocket"; //陈果
-	// var wsUrl = "ws://live.ylrzcloud.com/socket/app/webSocket";
-	var pingpangTimes = null;
-	var initTimes = null;
-	var isSocketOpen = false;
-	var socket = null;
-
-	export default {
-		data() {
-			return {
-				connectingLiveId: null, // 记录正在连接的直播间ID
-				swiperDuration: 0, // 初始化为0,首次加载无动画
-				videoRetryCounts: {}, // 记录每个直播间的视频重试次数,格式: { liveId: 次数 }
-
-
-				socketInstances: {}, // 改为对象存储多个socket实例
-				currentSwiperIndex: 0, // 当前swiper索引
-				list: [], // 直播间列表
-				preloading: false, // 预加载状态
-
-
-				liveUserTotal: null,
-				viewPageSize: 10, // 每页数量
-				viewPageNum: 1, // 当前页码
-				viewLoading: false, // 是否正在加载
-				viewNoMoreData: false, // 是否没有更多数据
-				scrollHeight: 0,
-				scrollTimer: null, // 滚动防抖定时器
-
-
-				socketInstance: null, // 统一管理 socket 实例
-				reconnectCount: 0,
-				maxReconnectAttempts: 3,
-				isManualClose: false, // 标记是否手动关闭
-
-				showRed: true,
-				// redInfo: {},
-				// inputInfo: '',
-				searchTimer: null,
-				// storeId: null,
-				reconnectTimer: null,
-				isCollect: false,
-				showPurchasePrompt: false,
-				purchasePromptTimer: null,
-				prevOrderCount: 0, // 用于记录上一次的购买人数
-				videoUrl: null,
-				showType: 1, //横屏1 竖屏2
-				boxHeight: 300, //小黄车高度
-				// isFollow: false,
-				// liveViewData: {},
-				liveViewers: [], //观众
-				likeName: 0,
-				hlsPlayer: null, // HLS播放器实例,
-				livingUrl: "",
-				products: {},
-				store: {},
-				orderUser: {}, //正在购买
-				userType: 0,
-				timestamp: '',
-				liveId: null,
-				// userId: uni.getStorageSync("userInfo.userId"),
-
-				isZoom: false, //点赞按钮控制是否放大
-				userinfo: '', //用户信息
-				// path: 'http://192.168.10.166/dev-api', //余红奇
-				// path: 'http://v56c9b8e.natappfree.cc', //余红奇
-				// path: 'live.test.ylrztop.com/prod-api', //余红奇
-				// path: 'http://192.168.10.170/dev-api', //陈果
-				// value: '',
-				talkdisabled: false, //输入框是否禁用
-				autoplay: false, //视频自动播放
-				showadd: false,
-				// talklist: [],
-				scrollIntoView: '',
-				videoContext: '',
-				thistime: uni.$u.timeFormat(new Date(), 'yyyy-mm-dd hh:MM:ss'),
-				// showWelcomeMessage: false,
-				isSubmit: false,
-				messageContent: "",
-				showziliao: false,
-				isScreen: true,
-				// shopping: false, //小黄车弹窗
-				scrollTop: 0, //弹幕
-				old: {
-					scrollTop: 0
-				},
-				livedata: {}, //直播间点赞、关注、在线人数数据
-
-			};
-		},
-
-
-		onLoad(options) {
-			this.initTime();
-			if (options.liveId) {
-				this.liveId = options.liveId; // 仅当 liveId 变化时更新
-			}
-			this.userinfo = JSON.parse(uni.getStorageSync("userInfo"))
-			// 初始化直播间列表
-			this.initLiveList(options);
-			this.getliveUser(false); // 调用获取在线用户接口
-			const platform = uni.getWindowInfo().platform;
-			// 初始化直播间列表
-
-			if (['mp-weixin', 'mp-alipay', 'mp-baidu', 'mp-toutiao'].includes(platform)) {
-				// 确保 API 存在再调用
-				if (uni.showShareMenu) {
-					uni.showShareMenu({
-						withShareTicket: true, // 可选参数,根据需求配置
-						success: () => {
-							console.log('分享菜单显示成功');
-						},
-						fail: (err) => {
-							console.error('分享菜单显示失败:', err);
-						}
-					});
-				} else {
-					console.warn('当前平台不支持 uni.showShareMenu');
-				}
-			} else {
-				console.log('当前平台无需显示分享菜单');
-			}
-		},
-		onReady() {},
-		onShareAppMessage() {
-			return {
-				// title: this.product.title,
-				title: this.livedata.liveName,
-				path: '/pages/home/living',
-				imageUrl: this.products.image,
-				success(res) {
-					console.log("分享成功", res);
-				},
-				fail(err) {
-					console.error("分享失败", err);
-				}
-			};
-		},
-		computed: {
-			filteredViewers() {
-				if (!this.liveViewers) {
-					return
-				} else {
-					return this.liveViewers.slice(0, 3);
-				}
-
-			}
-		},
-		onHide() {
-			const currentLive = this.list[this.currentSwiperIndex];
-			if (currentLive) {
-				this.pauseVideo(currentLive);
-			}
-		},
-		onUnload() {
-			// 关闭所有WebSocket连接
-			this.closeAllWebSockets();
-
-			// 移除所有全局事件监听
-			this.removeAllEventListeners();
-
-			// 清理定时器
-			this.clearAllTimers();
-
-			// 销毁HLS播放器(如果使用了hls.js)
-			if (this.hlsPlayer) {
-				this.hlsPlayer.destroy();
-				this.hlsPlayer = null;
-			}
-
-			this.list.forEach(liveItem => {
-				const videoId = `myVideo_${liveItem.liveId}`;
-				const videoContext = uni.createVideoContext(videoId, this);
-				if (videoContext) {
-					videoContext.pause(); // 仅暂停视频即可
-				}
-			});
-		},
-		watch: {
-			// 监听orderUser.count的变化
-			'orderUser.count': {
-				handler(newVal, oldVal) {
-					if (newVal !== this.prevOrderCount) {
-						this.prevOrderCount = newVal;
-						this.showPurchaseMessage();
-					}
-				},
-				immediate: true
-			}
-		},
-		methods: {
-			// 重置在线用户列表的分页参数
-			resetUserListParams() {
-				this.viewPageNum = 1; // 重置页码为第一页
-				this.viewNoMoreData = false; // 重置“没有更多数据”状态
-				this.liveViewers = []; // 清空现有列表
-			},
-			closeAllWebSockets() {
-				this.isManualClose = true;
-
-				// 关闭所有连接
-				Object.keys(this.socketInstances).forEach(liveId => {
-					try {
-						if (this.socketInstances[liveId] && this.socketInstances[liveId].instance) {
-							this.socketInstances[liveId].instance.close({
-								code: 1000,
-								reason: '页面关闭'
-							});
-							console.log(`直播间 ${liveId} WebSocket 已关闭`);
-						}
-					} catch (e) {
-						console.error(`关闭直播间 ${liveId} WebSocket 时出错:`, e);
-					}
-				});
-
-				this.socketInstances = {};
-				isSocketOpen = false;
-			}, // 移除所有全局事件监听器
-			removeAllEventListeners() {
-				uni.$off('initSocket');
-				uni.$off('sendMsg');
-				uni.$off('closeWebSocket');
-				uni.$off('refreshOrder');
-				// 可以根据实际情况添加其他需要移除的事件
-			}, // 清理所有定时器
-			clearAllTimers() {
-				if (this.intervalId) {
-					clearInterval(this.intervalId);
-					this.intervalId = null;
-				}
-
-				if (this.pingpangTimes) {
-					clearInterval(this.pingpangTimes);
-					this.pingpangTimes = null;
-				}
-
-				if (this.reconnectTimer) {
-					clearInterval(this.reconnectTimer);
-					this.reconnectTimer = null;
-				}
-
-				if (this.scrollTimer) {
-					clearTimeout(this.scrollTimer);
-					this.scrollTimer = null;
-				}
-
-				if (this.searchTimer) {
-					clearTimeout(this.searchTimer);
-					this.searchTimer = null;
-				}
-
-				if (this.purchasePromptTimer) {
-					clearTimeout(this.purchasePromptTimer);
-					this.purchasePromptTimer = null;
-				}
-			},
-			// 初始化当前直播间数据
-			async initCurrentLiveData() {
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (!currentLive) return;
-
-				// 设置加载状态
-				currentLive.loading = true;
-
-				try {
-					// 先初始化WebSocket连接
-					await this.initSocket(currentLive);
-
-					// 然后并行加载其他数据
-					await Promise.allSettled([
-						this.getLiveMsg(currentLive),
-						this.getliveViewData(currentLive),
-						this.getliving(currentLive)
-					]);
-
-					currentLive.loaded = true;
-				} catch (error) {
-					console.error("初始化直播间数据失败:", error);
-				} finally {
-					currentLive.loading = false;
-				}
-			},
-
-
-			// 初始化直播间列表
-			async initLiveList(options) {
-				try {
-					await this.getList(); // 先加载直播间列表
-					if (this.list.length === 0) {
-						console.error("直播间列表为空,无法初始化");
-						return;
-					}
-
-					// 设置初始直播间索引(原逻辑保留)
-					if (options.liveId) {
-						const index = this.list.findIndex(item => item.liveId == options.liveId);
-						this.currentSwiperIndex = index !== -1 ? index : 0;
-					} else {
-						this.currentSwiperIndex = 0;
-					}
-
-
-					// 延迟设置动画时间(原逻辑保留)
-					setTimeout(() => {
-						this.swiperDuration = 300;
-					}, 100);
-
-					// 获取当前直播间的liveItem
-					const currentLive = this.list[this.currentSwiperIndex];
-					if (currentLive) {
-						this.liveId = currentLive.liveId;
-
-						// 重置用户列表参数
-						this.resetUserListParams();
-
-						// 预加载相邻直播间(不初始化WebSocket)
-						this.preloadNearbyLives(false);
-
-						// 初始化当前直播间数据(包含WebSocket连接)
-						await this.initCurrentLiveData();
-
-						// 获取在线用户
-						this.getliveUser(true);
-
-						// 延迟播放视频
-						setTimeout(() => {
-							this.playVideo(currentLive);
-						}, 500);
-					}
-				} catch (error) {
-					console.error("初始化失败:", error);
-				}
-			},
-
-			// Swiper切换事件
-			async onSwiperChange(e) {
-				const newIndex = e.detail.current;
-				const oldIndex = this.currentSwiperIndex;
-
-				// 如果索引没有变化,直接返回
-				if (newIndex === oldIndex) return;
-
-				// 暂停旧视频
-				const oldLive = this.list[oldIndex];
-				if (oldLive) {
-					this.pauseVideo(oldLive);
-					this.closeWebSocket(oldLive.liveId);
-				}
-
-				// 更新当前索引
-				this.currentSwiperIndex = newIndex;
-				const newLive = this.list[newIndex];
-				if (!newLive) return;
-
-				// 更新当前直播ID
-				this.liveId = newLive.liveId;
-
-				try {
-					// 重置用户列表参数
-					this.resetUserListParams();
-
-					// 初始化新直播间数据(包含WebSocket连接)
-					await this.initCurrentLiveData();
-
-					// 获取新直播间的在线用户
-					this.getliveUser(false);
-
-					// 播放新视频
-					setTimeout(() => {
-						this.playVideo(newLive);
-					}, 100);
-				} catch (error) {
-					console.error('切换直播间失败:', error);
-				}
-			},
-			// 获取直播间列表
-			async getList() {
-				const data = {
-					page: 1,
-					page_size: 20
-				};
-				try {
-					const res = await liveList(data);
-					if (res.code === 200) {
-						this.list = res.rows.map(item => ({
-							...item,
-							talklist: [],
-							loading: false,
-							loaded: false,
-							shopping: false,
-							inputInfo: '',
-							showWelcomeMessage: false,
-							redInfo: {}
-							// 其他初始化字段...
-						}));
-						console.log("直播间列表加载成功,数量:", this.list.length); // 确认数量是否 > 0
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: "none"
-						});
-						this.list = []; // 接口失败时清空列表,避免后续错误
-					}
-				} catch (error) {
-					console.error("获取直播间列表失败:", error);
-					this.list = []; // 异常时清空列表
-				}
-			},
-			// 播放视频
-			playVideo(liveItem) {
-				if (!liveItem) return;
-
-				try {
-					const videoId = `myVideo_${liveItem.liveId}`;
-					const videoContext = uni.createVideoContext(videoId, this);
-					if (videoContext) {
-						videoContext.pause(() => {
-							// 暂停完成后再播放
-							videoContext.play();
-						});
-					}
-				} catch (error) {
-					console.error("播放视频失败:", error);
-				}
-			},
-
-			pauseVideo(liveItem) {
-				if (!liveItem) return;
-
-				try {
-					const videoId = `myVideo_${liveItem.liveId}`;
-					const videoContext = uni.createVideoContext(videoId, this);
-					if (videoContext) {
-						videoContext.pause();
-					}
-				} catch (error) {
-					console.error("暂停视频失败:", error);
-				}
-			},
-			// 预加载相邻直播间
-			async preloadNearbyLives(includeWebSocket = false) {
-				this.preloading = true;
-				const currentIndex = this.currentSwiperIndex;
-				const preloadIndexes = [];
-
-				if (currentIndex > 0) preloadIndexes.push(currentIndex - 1);
-				if (currentIndex > 1) preloadIndexes.push(currentIndex - 2);
-				if (currentIndex < this.list.length - 1) preloadIndexes.push(currentIndex + 1);
-				if (currentIndex < this.list.length - 2) preloadIndexes.push(currentIndex + 2);
-
-				for (const index of preloadIndexes) {
-					const liveItem = this.list[index];
-					if (!liveItem || liveItem.loaded || liveItem.loading) continue;
-
-					liveItem.loading = true;
-					try {
-						// 只加载视频和基本信息,不初始化WebSocket
-						await Promise.all([
-							this.getliving(liveItem),
-							this.getLiveMsg(liveItem),
-							this.getliveViewData(liveItem)
-						]);
-
-						// 只有当明确要求时才初始化WebSocket
-						if (includeWebSocket) {
-							await this.initSocket(liveItem);
-						}
-
-						liveItem.loaded = true;
-					} catch (error) {
-						console.error(`预加载直播间 ${index} 失败:`, error);
-						liveItem.loaded = false;
-					} finally {
-						liveItem.loading = false;
-					}
-				}
-				this.preloading = false;
-			},
-
-
-			openViews() {
-				// 计算scroll-view高度
-				this.$nextTick(() => {
-					const query = uni.createSelectorQuery().in(this);
-					query.select('.view-box').boundingClientRect(data => {
-						if (data) {
-							// 减去标题和底部固定区域的高度
-							this.scrollHeight = data.height - 80 - 120; // 80是标题高度,120是底部高度
-						}
-					}).exec();
-				});
-			},
-			// 重置直播间数据
-			resetLiveData() {
-				// 保留不需要重置的数据(如用户信息等)
-				const keepData = {
-					userinfo: this.userinfo,
-					list: this.list,
-					currentSwiperIndex: this.currentSwiperIndex
-				};
-
-				// 重置其他直播间特定数据
-				this.liveUserTotal = null;
-				// this.liveViewData = {};
-				this.liveViewers = [];
-				this.livingUrl = "";
-				this.videoUrl = null;
-				this.products = {};
-				this.store = {};
-				this.orderUser = {};
-				this.talklist = [];
-				this.livedata = {};
-				// this.isFollow = false;
-				this.shopping = false;
-				this.inputInfo = ''
-
-				// 恢复需要保留的数据
-				Object.assign(this, keepData);
-			},
-
-			// 获取直播间用户
-			async getliveUser(isLoadMore = false) {
-				// 强制使用当前 liveId,避免使用旧值
-				const currentLiveId = this.liveId;
-				if (!currentLiveId) return;
-				// if (this.viewLoading || this.viewNoMoreData) return;
-				this.viewLoading = true;
-				try {
-					const res = await watchUserList(currentLiveId, this.viewPageSize, this.viewPageNum, false);
-					if (res.code === 200) {
-						// 若请求期间已切换直播间,忽略旧数据
-						if (this.liveId !== currentLiveId) return;
-						this.liveUserTotal = res.total;
-						if (res.rows.length === 0) {
-							this.viewNoMoreData = true;
-							return;
-						}
-
-						this.liveViewers = isLoadMore ? [...this.liveViewers, ...res.rows] :
-							res.rows; // 首次加载/切换直播间时重置数据
-						this.viewPageNum++;
-						// console.log("在线观众", this.liveViewers)
-					}
-				} catch (error) {
-					console.error('获取观众列表失败:', error);
-				} finally {
-					this.viewLoading = false;
-				}
-			},
-			// 滚动到底部触发
-			handleScrollToLower() {
-				// 清除上一次未执行的定时器,避免重复请求
-				if (this.scrollTimer) {
-					clearTimeout(this.scrollTimer);
-				}
-
-				// 延迟0.5秒(500毫秒)执行接口请求
-				this.scrollTimer = setTimeout(() => {
-					this.getliveUser(true); // 加载更多数据
-				}, 1000); // 延迟时间:500毫秒
-			},
-			async getLiveMsg(liveItem) {
-				// 强化校验:确保 liveItem 存在且包含 liveId
-				if (!liveItem || !liveItem.liveId) {
-					console.error('getLiveMsg 错误:无效的 liveItem', {
-						liveItem: liveItem,
-						currentIndex: this.currentSwiperIndex,
-						listLength: this.list.length
-					});
-					return; // 直接返回,不执行后续逻辑
-				}
-
-				try {
-					const res = await liveMsg(liveItem.liveId, 30, 1);
-					if (res.code == 200) {
-						// 确保使用响应式更新
-						this.$set(liveItem, 'talklist', [...res.rows]);
-						this.$nextTick(() => {
-							this.$set(liveItem, 'scrollIntoView', `list_${liveItem.talklist.length-1}`);
-						});
-					}
-				} catch (error) {
-					console.error("获取聊天记录失败:", error);
-				}
-			},
-
-			// 点击红包
-			onRed(item) {
-				// console.log("点了this.liveId", item)
-				if (!item.liveId) return;
-				// console.log("点了this.liveId", this.liveId)
-				if (!item.redInfo?.redId) return;
-				// console.log("点了this.redInfo?.redId", this.redInfo.redId)
-				// console.log("点了this.userinfo.userId", this.userinfo.userId)
-				let data = {
-					liveId: item.liveId,
-					userId: this.userinfo.userId,
-					redId: item.redInfo.redId,
-				}
-				console.log("点了this.liveId", data)
-				liveRed(data).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			handleSearchInput() {
-				// 使用防抖优化性能,避免频繁请求
-				clearTimeout(this.searchTimer);
-				this.searchTimer = setTimeout(() => {
-					this.queryCollect();
-				}, 500); // 500毫秒延迟
-			},
-			// 显示购买提示信息
-			showPurchaseMessage() {
-				// 清除之前的定时器
-				if (this.purchasePromptTimer) {
-					clearTimeout(this.purchasePromptTimer);
-				}
-
-				// 显示提示
-				this.showPurchasePrompt = true;
-
-				// 2秒后自动隐藏
-				this.purchasePromptTimer = setTimeout(() => {
-					this.showPurchasePrompt = false;
-				}, 2000);
-			},
-			truncateString(str, maxLength) {
-				return str.length > maxLength ? str.slice(0, maxLength) + '...' : str;
-			},
-			goStore(item) {
-				console.log("带过去storeId", item)
-				if (!item.storeId) {
-					uni.showToast({
-						title: "当前直播间暂未开通店铺",
-						icon: 'none'
-					});
-					return;
-				}
-
-				uni.navigateTo({
-					url: '/pages_shop/store?liveId=' + item.liveId + "&storeId=" + item.storeId
-				})
-			},
-			// 去订单列表
-			goOrderList() {
-				uni.navigateTo({
-					url: "/pages_shop/order"
-				})
-			},
-
-			// 初始化HLS播放器
-			initHlsPlayer() {
-				if (Hls.isSupported() && this.livingUrl) {
-					const video = document.getElementById('myVideo');
-					if (video) {
-						this.hlsPlayer = new Hls();
-						this.hlsPlayer.loadSource(this.livingUrl);
-						this.hlsPlayer.attachMedia(video);
-						this.hlsPlayer.on(Hls.Events.MANIFEST_PARSED, () => {
-							video.play();
-						});
-					}
-				}
-			},
-
-			// 视频错误处理
-			videoError(e, liveItem) {
-				// 检查是否是当前直播间,避免处理非活跃直播间的错误
-				if (!liveItem || liveItem.liveId !== this.liveId) return;
-
-				// 限制重试次数
-				if (this.videoRetryCounts[liveItem.liveId] >= 3) {
-					console.error(`直播间 ${liveItem.liveId} 视频加载失败`);
-					return;
-				}
-
-				this.videoRetryCounts[liveItem.liveId]++;
-
-				// 延迟重试,避免与切换操作冲突
-				setTimeout(() => {
-					if (liveItem.liveId === this.liveId) {
-						this.playVideo(liveItem);
-					}
-				}, 2000);
-			},
-
-			// 修改获取直播信息方法
-			async getliving(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-				// console.log("获取直播信息:", liveItem.liveId);
-				const param = {
-					id: liveItem.liveId
-				};
-
-				try {
-					const res = await getlive({
-						id: liveItem.liveId
-					});
-					if (res.code !== 200) {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-						return;
-					}
-
-					// 强制更新视频源(覆盖旧值)
-					if (res.data.liveType === 2) {
-						// 回放视频
-						this.$set(liveItem, 'videoUrl', res.data.videoUrl);
-						this.$set(liveItem, 'livingUrl', ''); // 清空直播流
-						this.$set(liveItem, 'placeholderText', "说点什么...");
-
-					} else if (res.data.liveType === 1) {
-						// 直播流
-						this.$set(liveItem, 'livingUrl', res.data.flvHlsUrl);
-						console.log("排查中1》》",res.data.flvHlsUrl)
-						console.log("排查中2》》",liveItem.livingUrl)
-						this.$set(liveItem, 'videoUrl', ''); // 清空回放视频
-						this.$set(liveItem, 'placeholderText', "说点什么...");
-					} else {
-						// 未开播
-						this.$set(liveItem, 'livingUrl', '');
-						this.$set(liveItem, 'videoUrl', '');
-					}
-
-					// 更新其他直播信息
-					// 仅当是当前激活的直播间时,才允许自动播放
-					const isCurrentLive = this.currentSwiperIndex === this.list.findIndex(item => item.liveId ===
-						liveItem.liveId);
-					this.$set(liveItem, 'autoplay', isCurrentLive && res.data.liveType !== 0);
-					this.$set(liveItem, 'showType', res.data.showType);
-					this.$set(liveItem, 'storeId', res.storeId);
-					this.queryCollect();
-				} catch (err) {
-					console.error("获取直播信息失败:", err);
-					uni.showToast({
-						title: "获取直播信息失败",
-						icon: 'none'
-					});
-				}
-			}, // 设置视频播放
-			setupVideoPlayback(liveItem, liveData) {
-				if (!liveItem.livingUrl) return;
-
-				// H5 平台:使用 HLS.js 处理 .m3u8 流
-				// #ifdef H5
-				if (liveItem.livingUrl.includes('.m3u8')) {
-					this.initHlsPlayer(liveItem);
-					return;
-				}
-				// #endif
-
-				// 小程序/App 平台:直接使用 video 组件
-				const videoId = `myVideo_${liveItem.liveId}`;
-				const videoContext = uni.createVideoContext(videoId, this);
-
-				if (liveData.liveType === 1) {
-					// 回放:跳转到指定位置
-					videoContext.seek(liveData.nowDuration || 0);
-				} else {
-					// 直播:直接播放
-					videoContext.play();
-				}
-			},
-			maskString(str, maskChar = '*') {
-				// 如果str是undefined或null,直接返回空字符串
-				if (!str) return '';
-				// 确保str是字符串(如果是数字等类型,先转为字符串)
-				const strVal = String(str);
-				return strVal.split('').map((char, index) => (index === 0 ? char : maskChar)).join('');
-			},
-
-			getPureDecimal(num, precision = 6) {
-				const decimalPart = Math.abs(num).toFixed(precision).split('.')[1];
-				return decimalPart?.replace(/0+$/, '') || ''; // 移除末尾多余的0
-			},
-
-			// 返回上一个页面并关闭WebSocket
-			goBack() {
-				// 暂停当前视频
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (currentLive) {
-					this.pauseVideo(currentLive);
-				}
-
-				// 关闭所有WebSocket连接
-				this.closeWebSocket();
-
-				// 导航返回
-				const pages = getCurrentPages();
-				if (pages.length > 1) {
-					uni.navigateBack();
-				} else {
-					uni.reLaunch({
-						url: '/pages/list/index'
-					});
-				}
-			},
-
-			//正在购买
-			async getliveOrder() {
-				const currentLiveId = this.liveId;
-				if (!currentLiveId) return;
-
-				try {
-					const res = await liveOrderUser(currentLiveId);
-					if (res.code === 200) {
-						// 绑定到当前 liveItem
-						const currentLive = this.list[this.currentSwiperIndex];
-						if (currentLive) {
-							this.$set(currentLive, 'orderUser', res);
-							this.orderUser = res; // 同步全局变量
-						}
-					}
-				} catch (error) {
-					console.error('获取正在购买用户失败:', error);
-				}
-			},
-
-			// 获取直播间信息接口
-			getLiveinformation() {
-				if (!this.liveId) return;
-				getLiveInfo(this.liveId).then(res => {
-						if (res.code == 200) {
-							console.log("获取直播间信息接口>>>>", res)
-							this.livingUrl = res.livingUrl
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-
-
-			// 点赞
-			async onLike(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-				if (!liveItem.liveViewData) {
-					await this.getliveViewData(liveItem); // 强制加载数据
-					if (!liveItem.liveViewData) { // 仍未加载成功
-						uni.showToast({
-							title: "数据加载中,请稍后再试",
-							icon: 'none'
-						});
-						return;
-					}
-				}
-
-				try {
-					const res = await liveDataLike(liveItem.liveId);
-					if (res.code === 200) {
-						if (res.like) {
-							liveItem.liveViewData.like=res.like;
-						}
-						else{
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-					}
-				} catch (error) {
-					console.error('点赞失败:', error);
-				}
-			},
-			//直播间点赞、关注、在线人数数据
-			async getliveViewData(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-				try {
-					const res = await getLiveViewData(liveItem.liveId);
-					if (res.code == 200) {
-						// 强制响应式更新,确保数据实时显示
-						this.$set(liveItem, 'liveViewData', res);
-						// 打印日志确认数据已加载
-						console.log(`直播间 ${liveItem.liveId} 数据加载完成:`, res);
-					}
-				} catch (error) {
-					console.error("获取直播间数据失败:", error);
-					// 失败时兜底,避免显示异常
-					this.$set(liveItem, 'liveViewData', {
-						like: 0,
-						watchCount: 0
-					});
-				}
-			},
-			// 去购买,跳商品详情
-			goShop(productId, goodsId) {
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (!currentLive || !currentLive.liveId) return;
-				// console.log("拿现在的item", currentLive)
-
-				uni.navigateTo({
-					url: '/pages_shop/goods?productId=' + productId + '&liveId=' + currentLive.liveId +
-						'&goodsId=' +
-						goodsId + '&storeId=' + currentLive.storeId
-				})
-			},
-
-			// 查询店铺
-			async queryCollect() {
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (!currentLive || !currentLive.liveId) return;
-
-				const {
-					storeId
-				} = currentLive;
-				// console.log("小黄车数据>>>", currentLive)
-				if (!storeId) return;
-				try {
-					const res = await store(currentLive.storeId, currentLive.inputInfo, currentLive.liveId);
-					if (res.code === 200) {
-						// 数据绑定到当前 liveItem,避免全局污染
-						this.$set(currentLive, 'products', res.data.goodsList);
-						this.$set(currentLive, 'store', res.data);
-						// 同步更新全局变量(供弹窗使用)
-						this.products = res.data.goodsList;
-						this.store = res.data;
-					}
-				} catch (error) {
-					console.error('获取小黄车商品失败:', error);
-				}
-			},
-
-			// 店铺收藏
-			onStoreCollect(liveItem) {
-				console.log("店铺收藏", liveItem)
-				if (!liveItem.storeId) return;
-				collectStore(liveItem.storeId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							liveItem.store.isFavorite = !liveItem.store.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 商品收藏
-			onGoodsCollect(item) {
-				console.log("商品收藏", item)
-				if (!item || item.length === 0 || !item.goodsId) {
-					return;
-				}
-				collectGoods(item.goodsId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							item.isFavorite = !item.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 关注
-			// async onFollow(liveItem) {
-			// 	if (!liveItem || !liveItem.liveId) return;
-
-			// 	try {
-			// 		const res = await follow(liveItem.liveId);
-			// 		liveItem.isFollow = !liveItem.isFollow;
-			// 		uni.showToast({
-			// 			title: res.msg,
-			// 			icon: 'none'
-			// 		});
-			// 	} catch (error) {
-			// 		console.error("关注操作失败:", error);
-			// 	}
-			// },
-			// 时间戳
-			initTime() {
-				const now = new Date();
-				this.timestamp = now.getTime(); // 例如:'2023-04-01 12:00:00'
-			},
-			// initWebSocket() {
-			//       const liveWS = new LiveWS('ws://your-server.com', 123, 456);
-
-			//       // 从 URL 中解析 timestamp
-			//       const urlParams = new URL(liveWS.url).searchParams;
-			//       this.timestamp = urlParams.get('timestamp');
-			//       // console.log('Timestamp:', timestamp);
-			//     },
-
-			// 弹幕滚动
-			lowerChat: function(e) {
-				console.log(e)
-			},
-			scroll: function(e) {
-				console.log(e)
-				this.old.scrollTop = e.detail.scrollTop
-			},
-
-
-			loadmore() {
-				// for (let i = 0; i < 30; i++) {
-				//   this.indexList.push({
-				//     url: this.shopList[uni.$u.random(0, this.shopList.length - 1)],
-				//   });
-				// }
-			},
-
-			openShop() {
-
-			},
-			openViews() {
-				this.$nextTick(() => {
-					const query = uni.createSelectorQuery().in(this);
-					query.select('.view-box').boundingClientRect(data => {
-						if (data) {
-							this.scrollHeight = data.height - 80 - 120;
-						}
-					}).exec();
-				});
-			},
-			openCart(liveItem) {
-				if (!liveItem.storeId) {
-					uni.showToast({
-						title: "当前直播间暂未开通店铺",
-						icon: 'none'
-					});
-					return;
-				}
-				liveItem.shopping = !liveItem.shopping
-			},
-			close() {
-				this.showadd = !this.showadd
-			},
-			closes() {
-				this.showziliao = !this.showziliao
-			},
-			closest() {
-				this.showAnswer = !this.showAnswer
-			},
-			closestred() {
-				this.showAnswerred = !this.showAnswerred
-			},
-			closeanswer() {
-				this.answerbtn = !this.answerbtn
-			},
-			// 关闭小黄车
-			closeShop() {
-				// 通过当前swiper索引获取当前直播间实例
-				const currentLive = this.list[this.currentSwiperIndex];
-				if (currentLive) {
-					// 使用响应式更新修改shopping属性
-					this.$set(currentLive, 'shopping', !currentLive.shopping);
-				}
-			},
-			// 关闭红包
-			closeRed() {
-				this.showRed = !this.showRed
-			},
-			// 触摸结束
-			handleTouchEnd() {
-				this.isZoom = false; // 恢复原状
-			},
-			getEWechatSdk() {
-				// 只在H5平台执行
-				// #ifdef H5
-				let eWechatSdk = '';
-				if (/(Android)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'jWeixin';
-				} else if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'wx';
-				} else {
-					eWechatSdk = 'jWeixin';
-				}
-				uni.setStorageSync("wxSdk", eWechatSdk);
-				// #endif
-			},
-			// 修改关闭WebSocket方法
-			closeWebSocket(liveId = null) {
-				this.isManualClose = true;
-
-				// 清除所有定时器
-				clearInterval(this.pingpangTimes);
-				clearInterval(this.reconnectTimer);
-
-				// 关闭指定或所有WebSocket连接
-				if (liveId) {
-					// 关闭指定直播间的连接
-					if (this.socketInstances[liveId] && this.socketInstances[liveId].instance) {
-					  try {
-					    this.socketInstances[liveId].instance.close(); // socketTask.close()
-					    console.log(`直播间 ${liveId} WebSocket 已安全关闭`);
-					  } catch (e) { console.error('关闭失败', e); }
-					  delete this.socketInstances[liveId];
-					}
-				} else {
-					// 关闭所有连接
-					Object.keys(this.socketInstances).forEach(liveId => {
-						try {
-							uni.closeSocket({
-								instance: this.socketInstances[liveId]
-							});
-							console.log(`直播间 ${liveId} WebSocket 已安全关闭`);
-						} catch (e) {
-							console.error('关闭 WebSocket 时出错:', e);
-						}
-					});
-					this.socketInstances = {};
-				}
-
-				isSocketOpen = false;
-			},
-			reConnect() {
-				var that = this;
-				try {
-					uni.closeSocket();
-				} catch (e) {
-
-				}
-				setTimeout(function() {
-					that.initSocket();
-				}, 10000);
-
-			},
-			startHeartbeat(liveId) {
-			  clearInterval(this.pingpangTimes);
-			  this.pingpangTimes = setInterval(() => {
-			    const inst = this.socketInstances[liveId];
-			    if (!inst || !inst.isOpen || !inst.instance) return;
-			    const pingData = { cmd: 'ping', timestamp: Date.now() };
-			    try {
-			      inst.instance.send({ data: JSON.stringify(pingData) });
-			    } catch (err) {
-			      console.error('心跳发送失败:', err);
-			      this.scheduleReconnect(liveId);
-			    }
-			  }, 30000);
-			},
-			async initSocket(liveItem) {
-				if (!liveItem || !liveItem.liveId) return;
-
-				const liveId = liveItem.liveId;
-
-				// 检查是否已经是当前连接或正在连接
-				if (this.connectingLiveId === liveId ||
-					(this.socketInstances[liveId] && this.socketInstances[liveId].isOpen)) {
-					console.log(`直播间 ${liveId} 的WebSocket已经连接或正在连接,跳过初始化`);
-					return;
-				}
-
-				// 检查是否是当前活跃的直播间
-				if (this.currentSwiperIndex !== this.list.findIndex(item => item.liveId === liveId)) {
-					console.log(`不初始化非当前直播间 ${liveId} 的WebSocket`);
-					return;
-				}
-
-				// 关闭之前的连接(如果存在)
-				if (this.socketInstances[liveId]) {
-					this.closeWebSocket(liveId);
-				}
-
-				// 设置正在连接的直播间ID
-				this.connectingLiveId = liveId;
-
-				// 防止重复创建
-				if (this.reconnectCount >= this.maxReconnectAttempts) {
-					this.connectingLiveId = null;
-					return;
-				}
-
-				this.isManualClose = false;
-
-				// 生成签名
-				const signature = CryptoJS.HmacSHA256(
-					`${liveId}${this.userinfo.userId}${this.userType}${this.timestamp}`,
-					this.timestamp.toString()
-				).toString(CryptoJS.enc.Hex);
-
-				// 初始化实例状态
-				this.socketInstances[liveId] = {
-					instance: null,
-					isOpen: false
-				};
-
-				try {
-					const socketTask = uni.connectSocket({
-						url: `${wsUrl}?userId=${this.userinfo.userId}&liveId=${liveId}&userType=${this.userType}&timestamp=${this.timestamp}&signature=${signature}`,
-						success: () => {
-							console.log('WebSocket API 调用成功,正在建立连接...');
-						},
-						fail: (err) => {
-							console.error('WebSocket 连接失败:', err);
-							this.connectingLiveId = null;
-							this.scheduleReconnect(liveId);
-						}
-					});
-
-					socketTask.onOpen((res) => {
-						console.log('WebSocket 连接已成功建立', res);
-						this.socketInstances[liveId].instance = socketTask;
-						this.socketInstances[liveId].isOpen = true;
-						
-						isSocketOpen = true;
-						  this.connectingLiveId = null;
-						  this.reconnectCount = 0;
-						  // 改用 socketTask 的 send 作为心跳
-						  this.startHeartbeat(liveId); // 修改 startHeartbeat 以接受 liveId 并使用 socketTask.send
-					});
-
-					socketTask.onMessage((res) => {
-						// 找到对应的直播间并更新数据
-						const targetLive = this.list.find(item => item.liveId === liveId);
-						if (targetLive) {
-							this.handleSocketMessage(res, targetLive);
-						}
-					});
-
-					socketTask.onError((err) => {
-						console.error('WebSocket 连接错误:', err);
-						this.connectingLiveId = null;
-						this.scheduleReconnect(liveId);
-					});
-
-					socketTask.onClose(() => {
-						console.log(`WebSocket 连接已关闭: ${liveId}`);
-						this.connectingLiveId = null;
-					});
-				} catch (e) {
-					console.error('创建 WebSocket 异常:', e);
-					this.connectingLiveId = null;
-					this.scheduleReconnect(liveId);
-				}
-			},
-			// 处理Socket消息
-			handleSocketMessage(message, liveItem) {
-				let data = JSON.parse(message.data)
-				const socketMessage = data.data
-				// console.log("处理",data)
-				if (data.code == 200) {
-					const messageData = {
-						...socketMessage, // 原数据(可能包含部分字段)
-						cmd: socketMessage.cmd || '' // 强制添加cmd,确保存在(默认空字符串)
-					};
-					// console.log("messageData是",messageData)
-					if (socketMessage.cmd == 'sendMsg') {
-						// this.$set(liveItem, 'talklist', [...liveItem.talklist, messageData]);
-						this.$nextTick(() => {
-							this.$set(liveItem, 'scrollIntoView', `list_${liveItem.talklist.length-1}`);
-						});
-					} else if (socketMessage.cmd == 'red') {
-						// 领红包
-						this.$set(liveItem, 'redInfo', JSON.parse(socketMessage.data));
-						console.log("红包是liveItem.redInfo", liveItem)
-						// liveItem.redInfo = JSON.parse(message.data.data);
-
-					} else if (socketMessage.cmd == 'sendRedPacketQuestion') {
-						const list = JSON.parse(message.data.data);
-						// 处理红包答题逻辑
-					} else if (socketMessage.cmd == 'entry') {
-						// console.log("进入:", liveItem);
-						console.log("在线人数进入:");
-						this.$set(liveItem, 'talklist', [...liveItem.talklist, messageData]);
-						// 先重置为 false(避免残留状态)
-						this.$set(liveItem, 'showWelcomeMessage', false);
-						// 立即设为 true(触发 DOM 更新)
-						this.$set(liveItem, 'showWelcomeMessage', true);
-						this.getliveUser(false); // 调用获取在线用户接口
-						console.log("开启欢迎消息:", liveItem.showWelcomeMessage);
-						if (liveItem.welcomeTimer) {
-							clearTimeout(liveItem.welcomeTimer);
-						}
-						// 存储定时器到 liveItem 中(避免引用丢失)
-						liveItem.welcomeTimer = setTimeout(() => {
-							this.$set(liveItem, 'showWelcomeMessage', false);
-							console.log("关闭欢迎消息:", liveItem.showWelcomeMessage);
-						}, 1000); // 1秒后隐藏
-					} else if (socketMessage.cmd == 'live_start') {
-						// 直播开始
-					} else if (socketMessage.cmd == 'live_end') {
-						// 直播结束
-					} else if (socketMessage.data.cmd == 'deleteId') {
-						uni.$emit('deleteId');
-					} else if (socketMessage.data.cmd == 'sendRedPacketQuestion') {
-						// const list = JSON.parse(socketMessage)
-						// liveItem.redanswerAll = [...liveItem.redanswerAll, ...list]
-						// if (liveItem.redanswerAll[1].randomAmount !== null) {
-						// 	liveItem.redanswertips = JSON.parse(liveItem.redanswerAll[0]
-						// 		.randomAmount)
-						// }
-					}
-				} else {
-					uni.showToast({
-						title: data.msg,
-						icon: 'none'
-					});
-				}
-
-			},
-			scheduleReconnect() {
-				  if (this.isManualClose || this.reconnectCount >= this.maxReconnectAttempts) return;
-				  this.reconnectCount++;
-				  const delay = Math.min(3000 * this.reconnectCount, 30000);
-				  clearInterval(this.reconnectTimer);
-				  this.reconnectTimer = setTimeout(() => {
-				    this.initSocket(this.list.find(item => item.liveId === liveId) || { liveId });
-				  }, delay);
-			},
-			sendMsg(liveItem) {
-			  if (!liveItem || !liveItem.liveId) return;
-			
-			  // 防止连续点击发送两次(短时锁定)
-			  if (liveItem.isSending) return;
-			  liveItem.isSending = true;
-			  setTimeout(() => { liveItem.isSending = false; }, 800); // 800ms 内禁止再次发送
-			
-			  const text = (liveItem.value || '').trim();
-			  if (!text) {
-			    uni.showToast({ title: "不能发送空消息", icon: 'none' });
-			    return;
-			  }
-			
-			  const liveId = liveItem.liveId;
-			  const socketItem = this.socketInstances[liveId];
-			
-			  // 乐观更新:立即把消息加入到本地聊天列表并清空输入(更好的体验)
-			  const localMsg = {
-			    cmd: 'sendMsg',
-			    msg: text,
-			    nickName: this.userinfo.nickName,
-			    avatar: this.userinfo.avatar,
-			    userId: this.userinfo.userId,
-			    local: true, // 标记为本地消息(可用于样式或后续差异处理)
-			    ts: Date.now()
-			  };
-			  this.$set(liveItem, 'talklist', [...(liveItem.talklist || []), localMsg]);
-			  this.$set(liveItem, 'value', ''); // 立即清空输入
-			
-			  if (!socketItem || !socketItem.instance || !socketItem.isOpen) {
-			    // 如果 socket 未连接,尝试建立连接(但不要阻塞用户)
-			    this.initSocket(liveItem);
-			    uni.showToast({ title: "连接未建立,正在重连", icon: 'none' });
-			    return;
-			  }
-			
-			  const data = {
-			    liveId,
-			    userId: this.userinfo.userId,
-			    userType: 0,
-			    cmd: "sendMsg",
-			    msg: text,
-			    nickName: this.userinfo.nickName,
-			    avatar: this.userinfo.avatar
-			  };
-			
-			  try {
-			    socketItem.instance.send({
-			      data: JSON.stringify(data),
-			      success: () => {
-			        // 成功后可以移除 local 标记(可选)
-			        // 比如找到最后一条 local 消息并标记为 sent
-			      },
-			      fail: (err) => {
-			        console.error("发送失败:", err);
-			        uni.showToast({ title: "发送失败,请重试", icon: 'none' });
-			        // 可选择回滚本地显示(此处简单提示即可)
-			      }
-			    });
-			  } catch (err) {
-			    console.error('socket send 异常', err);
-			  }
-			}
-		}
-	};
-</script>
-
-<style scoped lang="scss">
-	.swiper-wrapper {
-		position: relative;
-		width: 100%;
-		height: 100vh;
-		overflow: hidden;
-		background-color: #000000;
-	}
-
-	.swiper-container {
-		width: 100%;
-		height: 100vh;
-	}
-
-	.container {
-		width: 100%;
-		height: 100%;
-		position: relative;
-
-		// 添加渐变过渡效果
-		transition: opacity 0.3s ease;
-
-		&.active {
-			opacity: 1;
-		}
-
-		// 非活动项半透明显示
-		// &:not(.active) {
-		// 	opacity: 0.7;
-		// }
-	}
-
-	.loading-tip {
-		position: absolute;
-		top: 50%;
-		left: 50%;
-		transform: translate(-50%, -50%);
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		justify-content: center;
-		z-index: 10;
-
-		.loading-text {
-			color: #ffffff;
-			font-size: 28rpx;
-			margin-top: 20rpx;
-		}
-	}
-
-	.loading-more,
-	.no-more {
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		padding: 20rpx 0;
-		color: #999;
-		font-size: 24rpx;
-	}
-
-	.loading-more {
-		flex-direction: column;
-	}
-
-	.preload-indicator {
-		position: absolute;
-		top: 50%;
-		right: 30rpx;
-		transform: translateY(-50%);
-		z-index: 100;
-		background: rgba(0, 0, 0, 0.5);
-		border-radius: 50%;
-		padding: 16rpx;
-	}
-
-	/* button自带样式清除 */
-	.student-orther-icon button::after {
-		border: none !important;
-		padding: 0 !important;
-		margin: 0 !important;
-	}
-
-	.student-orther-icon button {
-		background-color: transparent !important;
-		padding: 0 !important;
-		line-height: inherit !important;
-		margin: 0 !important;
-		width: auto !important;
-		font-weight: 500 !important;
-		border-radius: none !important;
-	}
-
-	.welcome-message {
-		position: fixed;
-		width: 100%;
-		bottom: 460rpx;
-		left: 50%;
-		transform: translateX(-50%);
-		color: white;
-		padding: 10px 20px;
-		border-radius: 20px;
-		// animation: fadeOut 1s ease 1s forwards;
-		z-index: 1000;
-		transition: opacity 0.3s ease;
-	}
-
-	@keyframes fadeOut {
-		from {
-			opacity: 1;
-		}
-
-		to {
-			opacity: 0;
-		}
-	}
-.send{
-	background-color: #4b4b4b;
-	border-radius:28rpx;
-	padding: 14rpx 16rpx;
-	color: #fff;
-}
-	// .container {
-	// 	position: relative;
-	// 	width: 100%;
-	// 	height: 100vh;
-	// 	overflow: hidden;
-	// }
-
-	// .talktext {
-	// 	border-radius: 8rpx;
-	// 	background-color: rgba(255, 255, 255, 0.1);
-
-	// 	view {
-	// 		width: 100%;
-	// 	}
-	// }
-
-	.talk-list {
-		border-radius: 30rpx;
-		background-color: rgba(33, 33, 33, 0.5);
-		padding: 10rpx 30rpx;
-	}
-
-	// .zoom-button-active {
-	// 	transform: scale(1.5);
-	// }
-
-	// .background-image {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 0;
-	// }
-
-	// .background-images {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 6;
-	// }
-
-	// .blackbg {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: 0;
-	// 	width: 100%;
-	// 	height: 100%;
-	// 	background: rgba(0, 0, 0, 0.7);
-	// 	object-fit: cover;
-	// 	filter: blur(10px);
-	// 	z-index: 1;
-	// }
-
-	.content {
-		position: relative;
-		z-index: 2;
-		height: 100%;
-		width: 100%;
-		top: 0;
-		left: 0;
-		display: flex;
-		flex-direction: column;
-		justify-content: space-between;
-
-		.content-top {
-			width: 100%;
-			margin-top: 68rpx;
-			display: flex;
-			// align-items: center;
-			justify-content: space-between;
-			padding: 0 24rpx;
-			box-sizing: border-box;
-
-			.sum {
-				width: 80rpx;
-				height: 52rpx;
-				background: rgba(0, 0, 0, 0.5);
-				border-radius: 26rpx 26rpx 26rpx 26rpx;
-				font-size: 24rpx;
-				color: #FFFFFF;
-				text-align: center;
-				line-height: 52rpx;
-
-			}
-		}
-
-		.follow-btn {
-			padding: 8rpx 16rpx;
-			background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-			border-radius: 26rpx;
-			font-weight: 500;
-			font-size: 26rpx;
-			color: #FFFFFF;
-		}
-	}
-
-	.videolist {
-		position: relative;
-	}
-
-	.video {
-		height: 100vh;
-		/* 占屏幕高度的80% */
-		width: 100%;
-		background-color: rgba(57, 57, 57, 0.4);
-	}
-
-	.videotop {
-		width: 100%;
-		height: 100%;
-	}
-
-	.video_row {
-		width: 100%;
-		max-height: 500rpx;
-		overflow: hidden;
-		margin-top: 360rpx;
-	}
-
-	.popup-video {
-		position: absolute;
-		top: 30%;
-		height: 500rpx;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		justify-content: center;
-		width: 100%;
-		color: #fff;
-		z-index: 9;
-
-		.more {
-			background-color: #3280fe;
-			border-radius: 80rpx;
-			width: 280rpx;
-			text-align: center;
-			height: 60rpx;
-			line-height: 60rpx;
-		}
-	}
-
-	.icon-bg {
-		background-color: rgba(157, 157, 157, 0.8);
-		border-radius: 50%;
-		width: 72rpx;
-		height: 72rpx;
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		transition: transform 0.2s ease;
-	}
-
-	.list {
-		width: 80%;
-		margin-bottom: 20rpx;
-		animation: xxxawdawd .2s;
-	}
-
-	@keyframes xxxawdawd {
-		from {
-			margin-top: 0rpx;
-			opacity: 0;
-		}
-
-		to {
-			margin-top: 20rpx;
-			opacity: 1;
-		}
-	}
-
-	.shop-prompt {
-		position: absolute;
-		bottom: 600rpx;
-		left: 24rpx;
-		padding: 6rpx 20rpx;
-		background: rgba(230, 154, 34, 0.7);
-		border-radius: 24rpx;
-		z-index: 9;
-		font-weight: 500;
-		font-size: 26rpx;
-		color: #FFFFFF;
-		transition: opacity 0.3s ease;
-	}
-
-	.siderow-group {
-		position: absolute;
-		top: 65%;
-		right: 30rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-	}
-
-	.side-group {
-		position: absolute;
-		// top: 30%;
-		top: 65%;
-		right: 30rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-
-
-	}
-
-	.red-box {
-		.button {
-			margin: 0 auto;
-			width: 80%;
-			line-height: 88rpx;
-			height: 88rpx;
-			background: linear-gradient(90deg, #FF5701 0%, #FFB501 100%);
-			box-shadow: 0rpx 8rpx 8rpx 0rpx rgba(238, 124, 80, 0.2);
-			border-radius: 44rpx 44rpx 44rpx 44rpx;
-			font-weight: 600;
-			font-size: 32rpx;
-			color: #FFFFFF;
-			text-align: center;
-		}
-	}
-
-	.view-box {
-		position: relative;
-		height: 40vh;
-		/* 设置弹出层高度为视窗高度的70% */
-		padding: 40rpx 0rpx 120rpx;
-		box-sizing: border-box;
-		display: flex;
-		flex-direction: column;
-
-		.scroll-content {
-			flex: 1;
-			overflow-y: auto;
-			padding: 0 40rpx;
-		}
-
-		.bottom {
-			padding: 20rpx 40rpx;
-			position: absolute;
-			bottom: 0;
-			width: 100%;
-			box-shadow: 0rpx -4rpx 10rpx 0rpx rgba(195, 195, 195, 0.3);
-			background: #fff;
-		}
-	}
-
-	.shoppop {
-		padding: 22rpx 16rpx;
-
-		.shoppop-top {
-			display: flex;
-			justify-content: space-between;
-			align-items: center;
-			padding: 0 16rpx 22rpx;
-
-			.search-input {
-				width: 414rpx;
-				height: 76rpx;
-				background: #FFFFFF;
-				border-radius: 36rpx;
-				margin-left: 20rpx;
-				padding: 0 32rpx;
-				box-sizing: border-box;
-				font-size: 24rpx;
-				margin-right: 24rpx;
-
-			}
-
-			.search-top {
-				font-size: 20rpx;
-				color: #222222;
-			}
-		}
-
-
-		.shop-list {
-			overflow: hidden;
-
-			.list-item {
-				display: flex;
-				align-items: center;
-				padding: 20rpx 16rpx;
-				background: #FFFFFF;
-				border-radius: 16rpx;
-				margin-bottom: 16rpx;
-
-				.goods-img {
-					width: 200rpx;
-					height: 200rpx;
-					border-radius: 16rpx;
-					overflow: hidden;
-					position: relative;
-					margin-right: 24rpx;
-
-					image {
-						width: 100%;
-						height: 100%;
-					}
-
-					.goods-label {
-						position: absolute;
-						top: 0;
-						width: 64rpx;
-						height: 40rpx;
-						background: rgba(0, 0, 0, 0.5);
-						border-radius: 16rpx 0rpx 16rpx 0rpx;
-						text-align: center;
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #FFFFFF;
-					}
-				}
-
-				.goods-right {
-					flex: 1;
-
-					.goods-title {
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #000000;
-
-					}
-
-					.goods-details {
-						font-size: 24rpx;
-						color: #999999;
-						margin: 10rpx 0 20rpx;
-					}
-
-					.goods-people {
-						font-size: 22rpx;
-						color: #E69A22;
-						height: 56rpx;
-					}
-
-					.goods-shop {
-						display: flex;
-						justify-content: space-between;
-
-						.nummber {
-							color: #FF5C03;
-							font-size: 22rpx;
-							font-weight: 500;
-						}
-
-						.btn-group {
-							text-align: center;
-							line-height: 56rpx;
-
-							.collect-btn {
-								width: 72rpx;
-								background: #F5F7FA;
-								border-radius: 8rpx 0rpx 0rpx 8rpx;
-
-							}
-
-							.shop-btn {
-								width: 152rpx;
-								background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-								border-radius: 0rpx 8rpx 8rpx 0rpx;
-								font-weight: 500;
-								font-size: 26rpx;
-								color: #FFFFFF;
-
-							}
-						}
-					}
-				}
-			}
-		}
-	}
-
-	:deep(.u-list-item) {
-		width: 100%;
-		display: flex;
-		align-items: center;
-	}
-
-	:deep(.u-safe-area-inset-bottom) {
-		padding-bottom: 0
-	}
-</style>

+ 0 - 342
pages_no/payOrder.vue

@@ -1,342 +0,0 @@
-<template>
-	<view class="content">
-		<view class="inner">
-			<!-- 时间、价格 -->
-			<view class="time-price">
-				<text class="time">请在{{payLimitTime}}前完成支付</text>
-				<view class="price-box">
-					<text class="unit">¥</text>
-					<text class="num">{{order.payPrice}}</text>
-				</view>
-			</view>
-			<!-- 支付方式 -->
-			<view class="pay-type">
-				<view class="title">支付方式</view>
-				<view class="item">
-					<view class="left">
-						<image src="/static/images/wecha_pay.png" mode=""></image>
-						<text class="text">微信支付</text>
-					</view>
-					<label>
-						<checkbox disabled value="" :checked="wxPay" />
-					</label>
-				</view>
-			</view>
-			<!-- 订单详情查看 -->
-			<view class="order-info">
-				<view class="title">订单信息</view>
-				<view class="item">
-					<text class="label">订单编号</text>
-					<view class="sn-box">
-						<text class="text">{{order.orderCode}}</text>
-						<view class="copy-btn" @click="copyOrderSn(order.orderCode)">复制</view>
-					</view>
-				</view>
-				<view class="item">
-					<text class="label">下单时间</text>
-					<text class="text">{{order.createTime}}</text>
-				</view>
-				<view class="item">
-					<text class="label">支付方式</text>
-					<text class="text">微信支付</text>
-				</view>
-				 
-			</view>
-			
-		</view>
-		<view class="btn-box">
-			<view class="btn" @click="payOrder()">去支付</view>
-		</view>
-	</view>
-</template>
-
-<script>
-	// import {pay,getStoreOrderById} from '@/api/storeOrder'
-	export default {
-		data() {
-			return {
-				payLimitTime:null,
-				order:null,
-				// 默认选中微信支付
-				wxPay: true,
-			}
-		},
-		onLoad: function(options) {
-		    if (options.hasOwnProperty('q') && options.q) {
-				// 通过下面这步解码,可以拿到url的值
-				const url = decodeURIComponent(options.q)
-				this.url=url;
-				// // 对url中携带的参数提取处理
-				const obj = this.utils.urlToObj(url)
-				this.orderId=obj.orderId;
-		    }
-			else if(options!=null&&options.orderId!=null){
-				this.orderId=options.orderId;
-			}
-		},
-		onShow() {
-			this.getStoreOrderById();
-		},
-		methods: {
-			copyOrderSn(text) {
-				// 复制方法
-				uni.setClipboardData({
-					data:text,
-					success:()=>{
-						uni.showToast({
-							title:'内容已成功复制到剪切板',
-							icon:'none'
-						})
-					}
-				});
-			},
-			getStoreOrderById(){
-				var data = {orderId:this.orderId};
-				var that=this;
-				uni.showLoading();
-				getStoreOrderById(data).then(
-					res => {
-						if(res.code==200){
-							 console.log(res);
-							  uni.hideLoading();
-							  that.order=res.order;
-							  that.payLimitTime=res.payLimitTime;
-						}else{
-							uni.showToast({
-								icon:'none',
-								title: res.msg,
-							});
-						}
-					},
-					rej => {}
-				);
-				
-			},
-			payOrder(){
-				var data = {orderId:this.order.id};
-				var that=this;
-				uni.showLoading();
-				pay(data).then(
-					res => {
-						if(res.code==200){
-							 console.log(res);
-							 uni.requestPayment({
-							 	provider: 'wxpay',
-							 	timeStamp: res.result.timeStamp,
-							 	nonceStr: res.result.nonceStr,
-							 	package: res.result.packageValue,
-							 	signType: res.result.signType,
-							 	paySign: res.result.paySign,
-							 	success: function(res) {
-							 		 uni.hideLoading();
-									 if(that.order.isPrescribe){
-										 //如果是处方订单开处方
-										uni.redirectTo({
-										 	url:"prescribe?orderId="+that.order.id
-										})
-									 }
-									 else{
-										//如果是普通订单
-										uni.redirectTo({
-											url:"success?order="+JSON.stringify(that.order)
-										}) 
-									 }
-							 	},
-							 	fail: function(err) {
-							 		console.log('fail:' + JSON.stringify(err));
-							 		uni.hideLoading();
-							 	}
-							 });
-						}else{
-							uni.showToast({
-								icon:'none',
-								title: res.msg,
-							});
-						}
-					},
-					rej => {}
-				);
-				
-			}
-		}
-	}
-</script>
-
-<style lang="scss">
-	page{
-		height: 100%;
-		background-color: #F2F5F9;
-	}
-	.content{
-		height: 100%;
-		display: flex;
-		flex-direction: column;
-		justify-content: space-between;
-		.inner{
-			padding: 20upx;
-			.time-price{
-				box-sizing: border-box;
-				height: 200upx;
-				background: #FFFFFF;
-				border-radius: 16upx;
-				display: flex;
-				flex-direction: column;
-				align-items: center;
-				padding-top: 50upx;
-				.time{
-					font-size: 26upx;
-					font-family: PingFang SC;
-					font-weight: 500;
-					color: #999999;
-					line-height: 1;
-					text-align: center;
-				}
-				.price-box{
-					display: flex;
-					align-items: flex-end;
-					margin-top: 28upx;
-					.unit{
-						font-size: 32upx;
-						font-family: PingFang SC;
-						font-weight: bold;
-						color: #FF6633;
-						line-height: 1.3;
-						margin-right: 10upx;
-					}
-					.num{
-						font-size: 56upx;
-						font-family: PingFang SC;
-						font-weight: bold;
-						color: #FF6633;
-						line-height: 1;
-					}
-				}
-			}
-			.pay-type{
-				box-sizing: border-box;
-				height: 192upx;
-				background: #FFFFFF;
-				border-radius: 16upx;
-				margin-top: 20upx;
-				padding: 40upx 30upx;
-				display: flex;
-				flex-direction: column;
-				justify-content: space-between;
-				.title{
-					font-size: 28upx;
-					font-family: PingFang SC;
-					font-weight: 500;
-					color: #999999;
-					line-height: 1;
-				}
-				.item{
-					display: flex;
-					align-items: center;
-					justify-content: space-between;
-					.left{
-						display: flex;
-						align-items: center;
-						image{
-							width: 44upx;
-							height: 44upx;
-							margin-right: 20upx;
-						}
-						.text{
-							font-size: 30upx;
-							font-family: PingFang SC;
-							font-weight: bold;
-							color: #222222;
-							line-height: 1;
-						}
-					}
-				}
-			}
-			.order-info{
-				margin-top: 20upx;
-				background: #FFFFFF;
-				border-radius: 16upx;
-				padding: 40upx 30upx;
-				.title{
-					font-size: 30upx;
-					font-family: PingFang SC;
-					font-weight: bold;
-					color: #222222;
-					line-height: 1;
-				}
-				.item{
-					margin-top: 40upx;
-					display: flex;
-					align-items: center;
-					justify-content: space-between;
-					.label{
-						font-size: 26upx;
-						font-family: PingFang SC;
-						font-weight: 500;
-						color: #666666;
-						line-height: 1;
-					}
-					.text{
-						font-size: 26upx;
-						font-family: PingFang SC;
-						font-weight: 500;
-						color: #222222;
-						line-height: 32upx;
-					}
-					.cont-text{
-						font-size: 26upx;
-						font-family: PingFang SC;
-						font-weight: 500;
-						color: #666666;
-						.bold{
-							color: #111111;
-						}
-					}
-					.sn-box{
-						display: flex;
-						align-items: center;
-						.copy-btn{
-							width: 58upx;
-							height: 32upx;
-							line-height: 32upx;
-							text-align: center;
-							font-size: 22upx;
-							font-family: PingFang SC;
-							font-weight: 500;
-							color: #222222;
-							background: #F5F5F5;
-							border-radius: 4upx;
-							margin-left: 24upx;
-						}
-					}
-					 
-				}
-				.line{
-					width: 100%;
-					height: 1px;
-					background: #F0F0F0;
-					margin-top: 30upx;
-				}
-			}
-		}
-		.btn-box{
-			height: 121upx;
-			background: #FFFFFF;
-			display: flex;
-			align-items: center;
-			justify-content: center;
-			.btn{
-				width: 91.73%;
-				height: 88upx;
-				line-height: 88upx;
-				font-size: 30upx;
-				font-family: PingFang SC;
-				font-weight: bold;
-				color: #FFFFFF;
-				text-align: center;
-				background: #0bb3f2;
-				border-radius: 44upx;
-			}
-		}
-	}
-	
-</style>

+ 0 - 2141
pages_no/zuizao.vue

@@ -1,2141 +0,0 @@
-<template>
-	<view class="container">
-		<!-- <view class="popup-video " v-if="!autoplay">
-			<view class="fs36 bold" v-if="livedata.status==1">——直播还未开始——</view>
-			<view class="fs36 bold" v-if="livedata.status==3">——直播已经结束——</view>
-			<view class="fs28 mtb20">了解更多,点击下方联系老师</view>
-			<view class="more" @click="showadd=!showadd">联系老师</view>
-		</view> -->
-
-		<!-- <image :src="livedata.liveImgUrl"
-	 :class="livedata.status!=2?'background-images':'background-image'"></image> -->
-		<view class="blackbg"></view>
-		<view class="content">
-			<!-- 页面内容 -->
-			<view style=" position: fixed;top: 0;z-index: 5;" class="content-top">
-				<view class="u-flex-y-center">
-					<image @click="goBack" style="width: 60rpx;height: 64rpx;margin-right: 26rpx;"
-						src="@/static/images/live/return.png"></image>
-					<view class=" align-center"
-						style="padding: 6rpx 4rpx;height: 64rpx;background: rgba(0,0,0,0.5);border-radius: 32rpx;">
-						<u-avatar :src="livedata.liveImgUrl||$img.logo" size="32"></u-avatar>
-						<view class="colorf" style="margin-left: 8rpx;">
-							<view>{{livedata.liveName?truncateString(livedata.liveName,5):"未命名"}}</view>
-							<view style="font-size: 16rpx;">
-								{{ liveViewData.follow || liveViewData.follow === 0 ? liveViewData.follow : 0 }}位粉丝
-							</view>
-						</view>
-						<view v-if="isFollow" @click="onFollow" class="follow-btn ml20">关注</view>
-						<view v-else @click="onFollow" class="follow-btn ml20">已关注</view>
-					</view>
-				</view>
-				<view class="u-flex-end align-center" @click="showadd=!showadd">
-					<image class="w52 h52 mr4" v-for="(item,index) in filteredViewers" :key="index"
-						style="border-radius: 26rpx;" :src="item.avatar||$img.logo"></image>
-					<view class="sum">{{liveUserTotal||0}}</view>
-				</view>
-			</view>
-
-			<!-- 页面内容 -->
-			<view style=" position: fixed;top:100rpx;left: 0rpx; z-index: 5;" class="content-top">
-				<view class="u-flex-y-center">
-					<image @click="onRed" v-if="redInfo?.redStatus==1" style="width: 70rpx;height: 70rpx;"
-						src="@/static/images/hongbao.png"></image>
-				</view>
-
-			</view>
-
-			<!-- 右边的 -->
-			<view :class=" showType==1 ? 'siderow-group' : 'side-group'">
-				<view class="side-item">
-					<image @click="onLike" src="/static/images/live/like.png"></image>
-					<view>{{liveViewData.like||0}}</view>
-				</view>
-				<view class="side-item">
-					<image @click="goStore()" src="/static/images/live/shop.png"></image>
-					<view>店铺</view>
-				</view>
-
-				<view class="side-item">
-					<button open-type="share">
-						<image src="/static/images/live/share.png" mode="widthFix"></image>
-					</button>
-					<view>分享</view>
-				</view>
-
-			</view>
-
-			<view class="shop-prompt u-flex-y-center" v-if="showPurchasePrompt&&orderUser?.count">
-				<image class="w32 h32 mr8" src="/static/images/live/shopping.png"></image>
-				<text> {{orderUser.userName ? maskString(orderUser.userName) : ''}} 等 {{orderUser.count || 0}}
-					人正在去购买</text>
-			</view>
-
-			<!-- object-fit:fill; -->
-			<view class="videolist " style="margin: auto 0">
-				<!-- <view class="video" :style="{height:isScreen?'100vh':''}"> -->
-				<view class="video" style="height:100vh">
-					<!-- 修改video组件以支持HLS -->
-					<!-- showType 1 横屏   2 竖屏 -->
-					<video v-if="livingUrl" id="myVideo" :class="showType == 1 ? 'video_row' : 'videotop'"
-						:src="livingUrl" :autoplay="autoplay" :controls='false' object-fit='contain'
-						:custom-cache="false" :enable-progress-gesture="false" vslide-gesture-in-fullscreen='true'
-						:show-center-play-btn="false" :http-cache="false" @error="videoError">
-					</video>
-
-					<video v-if="videoUrl" :class="showType == 1 ? 'video_row' : 'videotop'" :src="videoUrl"
-						:autoplay="autoplay" :controls='false' object-fit='contain' :custom-cache="false"
-						:enable-progress-gesture="false" vslide-gesture-in-fullscreen='true'
-						:show-center-play-btn="false" :http-cache="false" loop @error="videoError">
-					</video>
-				</view>
-			</view>
-			<view class="pb40  mt90" style="position: fixed;bottom: 0;">
-				<view class="w100 h300 mt20">
-					<scroll-view enable-flex scroll-y="true" class="talk p20 scrolly flex-1 column"
-						style="width: calc(100% - 40rpx);height: calc(100% - 40rpx);"
-						:scroll-into-view="scrollIntoView">
-						<view>
-							<view class="list justify-start" v-for="(item,index) in talklist" :key="index"
-								v-show="item.cmd=='announcement'">
-								<view class="talk-list ml16 justify-start">
-									<view class="fs24">
-										<text class='fs24 colorf'> {{item.msg}}直播间{{messageContent}}</text>
-									</view>
-								</view>
-							</view>
-						</view>
-
-
-						<view class="list justify-start" v-for="(item,index) in talklist" :key="index"
-							:id="`list_${index}`" v-show="item.cmd!='red'&&item.cmd!='out'&&item.cmd!='entry'">
-							<view class="talk-list ml16 justify-start">
-								<view class="fs24">
-									<!-- <text style="color: #3fc69b;transform: scale(0.8);display: inline-block; "v-if="item.userId==userinfo.userId&&item.cmd=='sendMsg'">我</text> -->
-									<!-- <text style="color: #c84e1e;transform: scale(0.8);display: inline-block;" v-if="item.userType==1">[ 管理员 ]</text> -->
-									<text style="color: #FFDA73;">{{item.nickName}}:</text>
-									<text class='fs24 colorf'>{{item.msg}}</text>
-								</view>
-							</view>
-						</view>
-						<view v-if="showWelcomeMessage" class="welcome-message">
-							<view class="list justify-start" v-for="(item,index) in talklist" :key="index"
-								v-show="item.cmd=='entry'||item.cmd=='out'">
-								<view class="talk-list ml16 justify-start">
-									<view class="fs24">
-										<text style="color: #ff89d6;">{{item.nickName}} </text>
-										<text class='fs24 colorf'> {{item.msg}}直播间{{messageContent}}</text>
-									</view>
-								</view>
-							</view>
-						</view>
-					</scroll-view>
-				</view>
-
-				<view class="justify-between p24">
-					<view class="u-flex-y-center"
-						style="background:rgba(157, 157, 157, 0.8);padding:18rpx 14rpx 18rpx 32rpx;width: 526rpx;box-sizing:border-box;border-radius:36rpx;">
-						<u-input :placeholder="placeholderText" border="none" customStyle='font-size:24rpx;'
-							v-model="value" shape='circle' color='#fff' placeholderStyle='color:#e7e7e7' class="ml20"
-							@keydown.enter="sendMsg" @confirm="sendMsg">
-						</u-input>
-						<!-- <image @click="sendMsg" class="w44 h44" src="@/static/images/live/like.png"></image> -->
-					</view>
-					<!-- :disabled='talkdisabled' ></u-input> -->
-					<!-- <view @click="sendMsg" class="colorf center ml10 fs24">发送</view> -->
-					<view class="justify-between mr30  align-center">
-						<!-- <view class="icon-bg ml20" @click="answerbtn=!answerbtn">
-							<image src="/static/images/redbag.png" class="w40 h40"></image>
-						</view> -->
-						<view class="icon-bg ml20" @click="shopping=!shopping">
-							<image src="/static/images/shopping.png" class="w48 h48"></image>
-						</view>
-						<view class="icon-bg ml20" @click="showziliao=!showziliao">
-							<image src="/static/images/more-icon.png" class="w48 h48"></image>
-						</view>
-						<!-- <view class="icon-bg ml20" :class="{ 'zoom-button-active': isZoom }"
-							@touchstart="handleTouchStart" @touchend="handleTouchEnd">
-							<image src="/static/images/dianzan.png" class="w40 h40"></image>
-						</view> -->
-					</view>
-				</view>
-			</view>
-		</view>
-
-		<!-- <u-popup :show="showadd" @close="close" @open="open" round='20rpx' bgColor='#fffee1'>
-			<view class="addchat p20">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="showadd=!showadd"></u-icon>
-				</view>
-				<view class="column align-center">
-					<view class="fs36" style="color: #ff5c03;">扫码添加助教老师</view>
-					<view class="fs28 color6">扫码添加助教老师</view>
-					<view class="p10 mt40" style="border: #ff5c03 solid 2rpx;">
-						<image :src="codeimg" class="wh180" @touchstart="longPress" @touchend="cancelLongPress">
-						</image>
-					</view>
-					<view class="color6 mt20">长按识别二维码</view>
-				</view>
-			</view>
-		</u-popup> -->
-		<u-popup :show="showadd" @close="close" @open="openViews" round='20rpx' bgColor='#ffffff'>
-			<view class="view-box">
-				<view class="t-c fs30">在线观众</view>
-				<scroll-view scroll-y class="scroll-content" :style="{height: scrollHeight + 'px'}"
-					@scrolltolower="handleScrollToLower">
-					<view class="fs24 u-flex-y-center mb20" v-for="(item,index) in liveViewers" :key="index">
-						<view
-							:style="{color: index === 0 ? '#FF3B30' : index === 1 ? '#FF9500' : index === 2 ? '#FFCC00' :  '#8E8E93',fontWeight: index < 3 ? 'bold' : 'normal',width: '50rpx'}"
-							class="mr10">{{index+1}}</view>
-						<u-avatar :src="item.avatar||$img.logo" size="32"></u-avatar>
-						<text class="ml16">{{item.nickName||"未命名"}}</text>
-					</view>
-					<!-- <view class="loading-more" v-if="viewLoading">
-					    <u-loading mode="circle"></u-loading>
-					    <text>加载中...</text>
-					  </view> -->
-					<view class="no-more" v-if="viewNoMoreData && liveViewers.length > 0">
-						<text>没有更多了</text>
-					</view>
-				</scroll-view>
-				<view class="fs24 u-flex-y-center bottom">
-					<view class="mr10" style="width:50rpx">我</view>
-					<u-avatar :src="livedata.liveImgUrl||$img.logo" size="32"></u-avatar>
-					<text class="ml16">{{livedata.liveName||"未命名"}}</text>
-				</view>
-
-			</view>
-		</u-popup>
-		<!-- <u-popup :show="showziliao" @close="closes" round='20' bgColor='#fffee1'>
-			<view class="addchat p20 bgf" style="border-radius: 20rpx;">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="showziliao=!showziliao"></u-icon>
-				</view>
-				<view class="column align-center h400">
-					<view class="fs36 " style="color: #ff5c03;">资料</view>
-					<view v-html="livedata.liveDesc"></view>
-				</view>
-			</view>
-		</u-popup> -->
-
-
-
-		<!-- 抽奖 -->
-		<!-- <u-popup :show="answerbtn" @close="closeanswer" round='40rpx' bgColor='#fff'>
-			<view class=" p20 bgf" style="border-radius: 40rpx;height: fit-content;">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="answerbtn=!answerbtn"></u-icon>
-				</view>
-				<view class="column align-center h400">
-					<view class="fs36 " style="color: #000000;font-weight: bold;">答题获取红包/积分奖励</view>
-					<view class="answerpop" @click="noredanswer">
-						<view class="color6 w350 fs24">
-							边玩边学,解锁你的知识巅峰!
-						</view>
-						<view class="answera">答题挑战</view>
-					</view>
-					<view class="answerpop">
-
-						<view class="color6 fs24" v-if='redanswertips&&redanswertips.length>0'>
-							🔥 <text style="color: #ff5c03;" class="fs30 bold">{{redanswertips[1].probability}}</text>
-							%用户首抽得
-							<text style="color: #ff5c03;" class="fs40 bold">{{redanswertips[1].maxAmount}}</text>元
-						</view>
-						<view v-else class="color6 w350 fs24">
-							随机奖励
-						</view>
-						<view class="answera" @click="redbagAnswer">
-							<image src="/static/images/baganswer.png"></image>
-							<view> 获得红包</view>
-						</view>
-					</view>
-				</view>
-			</view>
-		</u-popup> -->
-
-
-		<!-- <u-popup :show="showAnswer" @close="closest" round='40' bgColor='#fffee1' mode="center">
-			<view class="answerbox p20 bgf">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="closest"></u-icon>
-				</view>
-				<view class="column align-center ">
-					<view v-if="answerlist.type==1" style="width: 100%;">
-						<view class="mb40" style="text-align: center;">
-							<text class="color9 fs24">(单选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue[0]== item.label?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-					</view>
-					<view v-if="answerlist.type==2" style="width: 100%;">
-						<view class="mb40 " style="text-align: center;">
-							<text class="color9 fs24">(多选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue.includes(item.label)?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-						<view class=" submitbtn" @click="submitAnswers">确认</view>
-					</view>
-					<view class="fs24 mtb20 " style="color: #717171;">
-						{{answerfrist+1}}/{{Answerlistall}}
-					</view>
-				</view>
-			</view>
-		</u-popup> -->
-
-
-		<!-- 	<u-popup :show="showAnswerred" @close="closestred" round='40' bgColor='#fffee1' mode="center">
-			<view class="answerbox p20 bgf">
-				<view class="u-flex-row-reverse u-flex">
-					<u-icon name="close" size="18" @click="closestred"></u-icon>
-				</view>
-				<view class="column align-center ">
-					<view v-if="answerlist.type==1" style="width: 100%;">
-						<view class="mb40" style="text-align: center;">
-							<text class="color9 fs24">(单选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue[0]== item.label?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-					</view>
-					<view v-if="answerlist.type==2" style="width: 100%;">
-						<view class="mb40 " style="text-align: center;">
-							<text class="color9 fs24">(多选)</text>{{answerlist.title}}
-						</view>
-						<view v-for="(item,index) in answerlist.content" :key="index"
-							:class=" checkboxValue.includes(item.label)?'answeract itemanswer':'itemanswer' "
-							@click="handleCheckboxSelect(item.label)">{{item.label}}. {{item.content}}</view>
-						<view class=" submitbtn" @click="submitAnswers">确认</view>
-					</view>
-					<view class="fs24 mtb20 " style="color: #717171;">
-						{{answerfrist+1}}/{{Answerlistall}}
-					</view>
-				</view>
-			</view>
-		</u-popup> -->
-
-		<!-- 小黄车弹窗 -->
-		<u-popup :show="shopping" @close="closeShop" @open="openShop" round='20rpx' bgColor='#f3f5f9'>
-			<view class="shoppop">
-				<view class="shoppop-top">
-					<u-avatar :src="store.logoUrl" size="36" class="ml16"></u-avatar>
-					<view class="search-input u-flex-y-center">
-						<image style="width: 24rpx;height: 24rpx;margin-right: 16rpx;" src="@/static/images/search.png">
-						</image>
-						<input placeholder="请搜索商品" v-model="inputInfo" @input="handleSearchInput" />
-					</view>
-					<view class="t-c search-top" style="margin-right: 48rpx;">
-						<image @click="onStoreCollect" v-if="store.isFavorite" style="width: 32rpx;height: 32rpx;"
-							src="@/static/images/collect_select.png"></image>
-						<image v-else @click="onStoreCollect" style="width: 32rpx;height: 32rpx;"
-							src="@/static/images/collect.png"></image>
-						<view>收藏</view>
-					</view>
-					<view class="t-c search-top" @click="goOrderList">
-						<image style="width: 32rpx;height: 32rpx;" src="@/static/images/order.png"></image>
-						<view>订单</view>
-					</view>
-				</view>
-
-				<scroll-view enable-flex scroll-y class="shop-list" :style="{ height: boxHeight + 'px' }">
-					<view class="list-item " v-for="(item,index) in products" :key="index">
-						<view class="goods-img">
-							<image :src="item.imgUrl" mode="widthFix"></image>
-							<view class="goods-label">{{index+1}}</view>
-						</view>
-						<view class="goods-right">
-							<view class="goods-title">{{item.productName}}</view>
-							<!-- <view class="goods-details">{{item.productIntroduce}}</view> -->
-							<view class="goods-people">{{item.sales}} 人已购</view>
-							<view class="goods-shop">
-								<text class="nummber"><text style="font-size: 20rpx;font-weight: 600;">¥</text><text
-										style="font-size: 36rpx;font-weight: bold;">{{Math.trunc(item.price)}}</text>.{{getPureDecimal(item.price)?getPureDecimal(item.price):'00'}}/日</text>
-								<view class="btn-group  u-flex-y-center">
-									<view class="collect-btn">
-										<image v-if="item.isFavorite" @click="onGoodsCollect(item)"
-											style="width: 32rpx;height: 32rpx;" src="/static/images/collect_select.png">
-										</image>
-										<image v-else @click="onGoodsCollect(item)" style="width: 32rpx;height: 32rpx;"
-											src="/static/images/collect.png">
-										</image>
-									</view>
-									<view v-if="item.status==1" class="shop-btn"
-										@click="goShop(item.productId,item.goodsId)">去购买
-									</view>
-									<view v-else-if="item.status==0" @click="goShop(item.productId)" class="shop-btn">
-										已下架</view>
-								</view>
-							</view>
-						</view>
-					</view>
-				</scroll-view>
-			</view>
-		</u-popup>
-		<!-- 红包 -->
-		<!-- <u-popup :show="showRed" mode="center" @close="closeRed" round='20rpx' @open="openRed" bgColor='#ff3833'>
-			<view class="red-box" style="width: 500rpx;height: 500rpx; ">
-				<view class="button">立即领取</view>
-			</view>
-		</u-popup> -->
-	</view>
-</template>
-
-<script>
-	import Hls from 'hls.js';
-	import CryptoJS from 'crypto-js'
-	import {
-		liveList
-	} from '@/api/list'
-	import {
-		liveRed, // 点击领红包
-		liveDataLike, // 点赞
-		collectStore, // 店铺收藏/取消收藏
-		collectGoods, // 商品收藏/取消收藏
-		store, // 查询店铺
-		follow, // 关注/取消关注
-		watchUserList, //获取直播间用户(展示在线用户)
-		liveMsg, //获取最近聊天记录
-		// 小黄车
-		liveStore, //店铺展示,
-		// liveGoodsDetail, //商品详情,
-		liveOrderUser, //正在购买
-		getLiveInfo, //获取直播间信息接口
-		getLiveViewData //直播间点赞、关注、在线人数数据
-	} from '@/api/live'
-	import {
-		liveOrderList, // 订单列表
-	} from '@/api/order'
-
-	// import parse from '../../uni_modules/uview-plus/libs/config/props/parse';
-	import {
-		LiveWS
-	} from '@/utils/liveWS.js'
-	import {
-		getlive,
-		// gettextlist,
-		getAnswerlist,
-		submitAnswer
-	} from '@/api/home'
-	// var wsUrl = "ws://192.168.10.166:7114/app/webSocket";
-
-	// var wsUrl = "ws://192.168.10.166:7114/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.125:7114/app/webSocket"; //涂小龙
-	var wsUrl = "wss://live.test.ylrztop.com/ws/live-api/app/webSocket"; //余红奇
-	// var wsUrl = "ws://nd383294.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://v56c9b8e.natappfree.cc/app/webSocket"; //余红奇
-	// var wsUrl = "ws://192.168.10.170:7114/app/webSocket"; //陈果
-	// var wsUrl = "ws://live.ylrzcloud.com/socket/app/webSocket";
-	var pingpangTimes = null;
-	var initTimes = null;
-	var isSocketOpen = false;
-	var socket = null;
-
-	export default {
-		data() {
-			return {
-				liveUserTotal: null,
-				viewPageSize: 10, // 每页数量
-				viewPageNum: 1, // 当前页码
-				viewLoading: false, // 是否正在加载
-				viewNoMoreData: false, // 是否没有更多数据
-				scrollHeight: 0,
-				scrollTimer: null, // 滚动防抖定时器
-
-
-				socketInstance: null, // 统一管理 socket 实例
-				reconnectCount: 0,
-				maxReconnectAttempts: 3,
-				isManualClose: false, // 标记是否手动关闭
-
-				showRed: true,
-				redInfo: {},
-				inputInfo: '',
-				searchTimer: null,
-				storeId: null,
-				reconnectCount: 0,
-				maxReconnectAttempts: 3,
-				reconnectTimer: null,
-				isCollect: false,
-				showPurchasePrompt: false,
-				purchasePromptTimer: null,
-				prevOrderCount: 0, // 用于记录上一次的购买人数
-				videoUrl: null,
-				showType: 1, //横屏1 竖屏2
-				boxHeight: 300, //小黄车高度
-				isFollow: true,
-				liveViewData: {},
-				liveViewers: [], //观众
-				likeName: 0,
-				hlsPlayer: null, // HLS播放器实例,
-				livingUrl: "",
-				products: {},
-				store: {},
-				orderUser: {}, //正在购买
-				userType: 0,
-				timestamp: '',
-				liveId: null,
-				// userId: uni.getStorageSync("userInfo.userId"),
-				codeimg: '',
-				placeholderText: '说点什么...',
-				isZoom: false, //点赞按钮控制是否放大
-				userinfo: '', //用户信息
-				// path: 'http://192.168.10.166/dev-api', //余红奇
-				// path: 'http://v56c9b8e.natappfree.cc', //余红奇
-				// path: 'live.test.ylrztop.com/prod-api', //余红奇
-				// path: 'http://192.168.10.170/dev-api', //陈果
-				value: '',
-				talkdisabled: false, //输入框是否禁用
-				autoplay: false, //视频自动播放
-				showadd: false,
-				talklist: [],
-				scrollIntoView: '',
-				bufferRate: 0, //视频缓冲时间
-				playDuration: 0, //视频播放时间
-				videoContext: '',
-				thistime: uni.$u.timeFormat(new Date(), 'yyyy-mm-dd hh:MM:ss'),
-				upDown: true, //是否视频显示隐藏
-				isLongPress: false, // 是否长按
-				timeout: null, // 计时器
-				showWelcomeMessage: false,
-				isSubmit: false,
-				messageContent: "",
-				showziliao: false,
-				isScreen: true,
-				showAnswer: false, //展示答题
-				Answerlistall: {}, //所有题目
-				answerlist: {}, //当前题目
-				answerfrist: 0, //当前选择
-				checkboxValue: [], //多选数据
-				checkboxFormValue: "", //多选数据
-				allAnswerLists: [], // 新增:存储所有题目列表
-				showAnswerred: false, //展示红包答题
-				answerbtn: false, //答题按钮弹窗
-				redallAnswerLists: [], //储存所有红包答题列表
-				redanswerAll: [], //红包当前题目
-				redanswerList: [], //红包答题列表
-				redanswertips: [], //红包答题提示
-				shopping: false, //小黄车弹窗
-				scrollTop: 0, //弹幕
-				old: {
-					scrollTop: 0
-				},
-				livedata: {}, //直播间点赞、关注、在线人数数据
-
-			};
-		},
-
-
-		onLoad(options) {
-			this.userinfo = JSON.parse(uni.getStorageSync("userInfo"))
-			if (options.liveId) {
-				this.liveId = options.liveId; // 仅当 liveId 变化时更新
-			}
-			uni.showShareMenu({
-				withShareTicket: true
-			});
-		},
-		onShareAppMessage() {
-			return {
-				// title: this.product.title,
-				title: this.livedata.liveName,
-				path: '/pages/home/index',
-				imageUrl: this.products.image,
-				success(res) {
-					console.log("分享成功", res);
-				},
-				fail(err) {
-					console.error("分享失败", err);
-				}
-			};
-		},
-		computed: {
-			filteredViewers() {
-				if (!this.liveViewers) {
-					return
-				} else {
-					return this.liveViewers.slice(0, 3);
-				}
-
-			}
-		},
-		mounted() {
-			this.getLiveMsg() // 获取最近聊天记录
-			// this.onLike()
-			this.getliveViewData() ////直播间点赞、关注、在线人数数据
-
-			// this.intervalId = setInterval(() => {
-			// 	this.getliveViewData();
-			// }, 60 * 1000);
-			// this.getLiveinformation() // 获取直播间信息接口
-			this.getliveOrder() //正在购买
-			// this.getliveStore() // 获取小黄车 店铺展示
-			// this.getliveGoods() // 获取小黄车 商品详情
-			this.getliveUser() // 获取直播间用户
-			this.initTime()
-			// this.initWebSocket()
-			this.initSocket()
-			var that = this;
-			uni.$on('initSocket', () => {
-				that.initSocket()
-			})
-			uni.$on('sendMsg', (item) => {
-				that.sendMsg(item)
-			})
-			uni.$on('closeWebSocket', () => {
-				that.closeWebSocket()
-			})
-			this.getEWechatSdk();
-
-			this.getliving() //hls
-			// this.gettalklist()
-			// this.getAnswerlists()
-
-		},
-		onReady: function(res) {
-			this.videoContext = uni.createVideoContext('myVideo')
-			// console.log(this.videoContext)
-		},
-		onHide() {
-			clearInterval(this.intervalId); // 页面隐藏时清理
-		},
-		onUnload() {
-			this.closeWebSocket();
-			uni.$off('refreshOrder');
-			clearInterval(this.intervalId);
-
-			if (this.hlsPlayer) {
-				this.hlsPlayer.destroy(); // 清理 HLS 播放器
-			}
-			if (this.pingpangTimes) {
-				clearInterval(this.pingpangTimes); // 清除心跳定时器
-			}
-
-		},
-		watch: {
-			// 监听orderUser.count的变化
-			'orderUser.count': {
-				handler(newVal, oldVal) {
-					if (newVal !== this.prevOrderCount) {
-						this.prevOrderCount = newVal;
-						this.showPurchaseMessage();
-					}
-				},
-				immediate: true
-			}
-		},
-		methods: {
-			// 获取直播间列表
-			getList() {
-				const data = {
-					page: 1,
-					page_size: 10,
-				};
-				uni.showLoading({
-					title: "处理中..."
-				});
-				liveList(data)
-					.then(res => {
-						if (res.code == 200) {
-							this.list = res.rows; // 直接赋值给 this.list
-							console.log("list>>", this.list); // ✅ 打印已定义的 this.list
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					})
-					.catch(rej => {
-						console.log("请求失败:", JSON.stringify(rej));
-					})
-					.finally(() => {
-						uni.hideLoading();
-					});
-			},
-			openViews() {
-				// 计算scroll-view高度
-				this.$nextTick(() => {
-					const query = uni.createSelectorQuery().in(this);
-					query.select('.view-box').boundingClientRect(data => {
-						if (data) {
-							// 减去标题和底部固定区域的高度
-							this.scrollHeight = data.height - 80 - 120; // 80是标题高度,120是底部高度
-						}
-					}).exec();
-				});
-			},
-
-
-			// 获取直播间用户
-			async getliveUser(isLoadMore = false) {
-				if (this.viewLoading || this.viewNoMoreData) return;
-
-				this.viewLoading = true;
-
-				try {
-					const res = await watchUserList(this.liveId, this.viewPageSize, this.viewPageNum, false);
-
-					if (res.code == 200) {
-						this.liveUserTotal = res.total
-						if (res.rows.length === 0) {
-							this.viewNoMoreData = true;
-							if (this.viewPageNum > 1) {
-								uni.showToast({
-									title: '没有更多数据了',
-									icon: 'none'
-								});
-							}
-							return;
-						}
-
-						if (isLoadMore) {
-							// 加载更多时追加数据
-							this.liveViewers = [...this.liveViewers, ...res.rows];
-						} else {
-							// 首次加载或刷新
-							this.liveViewers = res.rows;
-						}
-
-						// 只有成功获取数据后才增加页码
-						this.viewPageNum++;
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-					}
-				} catch (error) {
-					console.error('获取观众列表失败:', error);
-					uni.showToast({
-						title: '获取数据失败',
-						icon: 'none'
-					});
-				} finally {
-					this.viewLoading = false;
-				}
-			},
-			// 滚动到底部触发
-			handleScrollToLower() {
-				// 清除上一次未执行的定时器,避免重复请求
-				if (this.scrollTimer) {
-					clearTimeout(this.scrollTimer);
-				}
-
-				// 延迟0.5秒(500毫秒)执行接口请求
-				this.scrollTimer = setTimeout(() => {
-					this.getliveUser(true); // 加载更多数据
-				}, 1000); // 延迟时间:500毫秒
-			},
-			// gettalklist() {
-			// 	if (!this.liveId) return;
-			// 	const param = {
-			// 		id: this.liveId
-			// 	}
-			// 	gettextlist(param).then(res => {
-			// 		if (res.code == 200) {
-			// 			this.talklist = res.data
-			// 			// console.log(res.data);
-			// 			this.$nextTick(() => {
-			// 				this.scrollIntoView = `list_${this.talklist.length-1}`
-			// 			})
-			// 		}
-			// 	})
-			// },
-			// 获取最近聊天记录
-			getLiveMsg() {
-				if (!this.liveId) return;
-				let pageSize = 30
-				let pageNum = 1
-				liveMsg(this.liveId, pageSize, pageNum).then(res => {
-					if (res.code == 200) {
-						// 使用Vue.set或直接赋值确保响应式更新
-						this.talklist = [...res.rows] // 使用展开运算符创建新数组
-						console.log("获取最近聊天记录>>", this.talklist)
-						this.$nextTick(() => {
-							this.scrollIntoView = `list_${this.talklist.length-1}`
-							console.log('应该滚动到:', this.scrollIntoView)
-						})
-					} else {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-					}
-				});
-			},
-			// 点击红包
-			onRed() {
-				console.log("点了")
-
-				if (!this.liveId) return;
-				console.log("点了this.liveId", this.liveId)
-				if (!this.redInfo?.redId) return;
-				console.log("点了this.redInfo?.redId", this.redInfo.redId)
-				console.log("点了this.userinfo.userId", this.userinfo.userId)
-				let data = {
-					liveId: this.liveId,
-					userId: this.userinfo.userId,
-					redId: this.redInfo.redId,
-				}
-				liveRed(data).then(res => {
-						if (res.code == 200) {} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			handleSearchInput() {
-				// 使用防抖优化性能,避免频繁请求
-				clearTimeout(this.searchTimer);
-				this.searchTimer = setTimeout(() => {
-					this.queryCollect();
-				}, 500); // 500毫秒延迟
-			},
-			// 显示购买提示信息
-			showPurchaseMessage() {
-				// 清除之前的定时器
-				if (this.purchasePromptTimer) {
-					clearTimeout(this.purchasePromptTimer);
-				}
-
-				// 显示提示
-				this.showPurchasePrompt = true;
-
-				// 2秒后自动隐藏
-				this.purchasePromptTimer = setTimeout(() => {
-					this.showPurchasePrompt = false;
-				}, 2000);
-			},
-			truncateString(str, maxLength) {
-				return str.length > maxLength ? str.slice(0, maxLength) + '...' : str;
-			},
-			goStore() {
-				console.log("带过去storeId", this.storeId)
-				uni.navigateTo({
-					url: '/pages_shop/store?liveId=' + this.liveId + "&storeId=" + this.storeId
-				})
-			},
-			// 去订单列表
-			goOrderList() {
-				uni.navigateTo({
-					url: "/pages_shop/order"
-				})
-			},
-
-			// 初始化HLS播放器
-			initHlsPlayer() {
-				if (Hls.isSupported() && this.livingUrl) {
-					const video = document.getElementById('myVideo');
-					if (video) {
-						this.hlsPlayer = new Hls();
-						this.hlsPlayer.loadSource(this.livingUrl);
-						this.hlsPlayer.attachMedia(video);
-						this.hlsPlayer.on(Hls.Events.MANIFEST_PARSED, () => {
-							video.play();
-						});
-					}
-				}
-			},
-
-			// 视频错误处理
-			videoError(e) {
-				console.error('视频播放错误:', e.detail.errMsg);
-				// 尝试重新加载或切换到备用流
-				if (this.livingUrl) {
-					setTimeout(() => {
-						this.videoContext.play();
-					}, 2000);
-				}
-			},
-
-			getliving() {
-				if (!this.liveId) return;
-				console.log("获取直播信息");
-				const param = {
-					id: this.liveId
-				};
-
-				getlive(param).then(res => {
-					if (res.code !== 200) {
-						uni.showToast({
-							title: res.msg,
-							icon: 'none',
-							duration: 2000
-						});
-						return;
-					}
-
-					this.livedata = res.data;
-					this.showType = res.data.showType;
-					this.storeId = res.storeId
-					this.queryCollect() //查询店铺
-					console.log("横屏1或竖屏2", this.showType)
-					// 1. 根据直播类型设置播放地址
-					if (res.data.liveType === 2) {
-						// 回放视频
-						this.videoUrl = res.data.videoUrl;
-						this.autoplay = true;
-						// this.placeholderText = "观看回放中";
-						this.placeholderText = "说点什么...";
-						this.talkdisabled = false;
-					} else if (res.data.liveType === 1) {
-						// 直播流
-						this.livingUrl = res.data.flvHlsUrl;
-						this.autoplay = true;
-						this.placeholderText = "说点什么...";
-						this.talkdisabled = false;
-					} else {
-						// 未开播
-						this.livingUrl = "";
-						this.autoplay = false;
-						this.placeholderText = "直播未开始,暂时无法发言";
-						this.talkdisabled = true;
-						return;
-					}
-
-					// 2. 根据不同平台处理播放逻辑
-					this.$nextTick(() => {
-						if (!this.livingUrl) return;
-
-						// H5 平台:使用 HLS.js 处理 .m3u8 流
-						// #ifdef H5
-						if (this.livingUrl.includes('.m3u8')) {
-							this.initHlsPlayer();
-							return;
-						}
-						// #endif
-
-						// 小程序/App 平台:直接使用 video 组件
-						if (!this.videoContext) {
-							this.videoContext = uni.createVideoContext('myVideo', this);
-						}
-
-						if (res.data.liveType === 1) {
-							// 回放:跳转到指定位置
-							this.videoContext.seek(res.data.nowDuration || 0);
-						} else {
-							// 直播:直接播放
-							this.videoContext.play();
-						}
-					});
-				}).catch(err => {
-					console.error("获取直播信息失败:", err);
-					uni.showToast({
-						title: "获取直播信息失败",
-						icon: 'none'
-					});
-				});
-			},
-			maskString(str, maskChar = '*') {
-				// 新增:如果str是undefined或null,直接返回空字符串
-				if (!str) return '';
-				// 确保str是字符串(如果是数字等类型,先转为字符串)
-				const strVal = String(str);
-				return strVal.split('').map((char, index) => (index === 0 ? char : maskChar)).join('');
-			},
-
-			getPureDecimal(num, precision = 6) {
-				const decimalPart = Math.abs(num).toFixed(precision).split('.')[1];
-				return decimalPart?.replace(/0+$/, '') || ''; // 移除末尾多余的0
-			},
-
-			// 返回上一个页面并关闭WebSocket
-			goBack() {
-				const pages = getCurrentPages();
-				// 如果页面栈长度大于1,说明有上一页可以返回
-				this.closeWebSocket();
-				if (pages.length > 1) {
-					uni.navigateBack();
-				} else {
-					// 如果没有上一页,跳转到默认页面(比如首页)
-					uni.switchTab({
-						url: '/pages/list/index' // 替换为你的首页路径
-					});
-
-				}
-
-			},
-
-			//直播间点赞、关注、在线人数数据
-			getliveViewData() {
-				if (!this.liveId) return;
-				getLiveViewData(this.liveId).then(res => {
-						if (res.code == 200) {
-							// console.log("直播间点赞、关注、在线人数数据>>>>", res)
-							this.liveViewData = res
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			//正在购买
-			getliveOrder() {
-				if (!this.liveId) return;
-				liveOrderUser(this.liveId).then(res => {
-						if (res.code == 200) {
-							console.log("正在购买>>>>", res)
-							this.orderUser = res
-
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			//小黄车 店铺展示
-			// getliveStore() {
-			// 	if (!this.liveId) return;
-			// 	let data = {
-			// 		pageSize: 10,
-			// 		page: 1
-			// 	}
-			// 	liveStore(this.liveId, data).then(res => {
-			// 			if (res.code == 200) {
-			// 				console.log("小黄车 店铺展示>>>>", res)
-			// 				this.products = res.data
-			// 				this.queryCollect()
-			// 			} else {
-			// 				uni.showToast({
-			// 					title: res.msg,
-			// 					icon: 'none'
-			// 				});
-			// 			}
-			// 		},
-			// 		rej => {}
-			// 	);
-			// },
-			// 获取直播间信息接口
-			getLiveinformation() {
-				if (!this.liveId) return;
-				getLiveInfo(this.liveId).then(res => {
-						if (res.code == 200) {
-							console.log("获取直播间信息接口>>>>", res)
-							this.livingUrl = res.livingUrl
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-
-
-			// 点赞
-			onLike() {
-				if (!this.liveId) return;
-				liveDataLike(this.liveId).then(res => {
-						if (res.code == 200) {
-							if (res.like) {
-								this.liveViewData.like++
-							} else {
-								uni.showToast({
-									title: res.msg,
-									icon: 'none'
-								});
-							}
-
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-
-			},
-			// 去购买,跳商品详情
-			goShop(productId, goodsId) {
-				uni.navigateTo({
-					url: '/pages_shop/goods?productId=' + productId + '&liveId=' + this.liveId + '&goodsId=' +
-						goodsId + '&storeId=' + this.storeId
-				})
-			},
-
-			// 查询店铺
-			queryCollect() {
-				if (!this.storeId) return;
-				store(this.storeId, this.inputInfo).then(res => {
-						if (res.code == 200) {
-							console.log("查询店铺>>", res)
-							this.products = res.data.goodsList
-							this.store = res.data
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 店铺收藏
-			onStoreCollect() {
-				if (!this.storeId) return;
-				collectStore(this.storeId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							this.store.isFavorite = !this.store.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 商品收藏
-			onGoodsCollect(item) {
-				if (!item || item.length === 0 || !item.goodsId) {
-					return;
-				}
-				collectGoods(item.goodsId).then(res => {
-						if (res.code == 200) {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-							item.isFavorite = !item.isFavorite
-						} else {
-							uni.showToast({
-								title: res.msg,
-								icon: 'none'
-							});
-						}
-					},
-					rej => {}
-				);
-			},
-			// 关注
-			onFollow() {
-				if (!this.liveId) return;
-				follow(this.liveId).then(res => {
-						this.isFollow = !this.isFollow
-						uni.showToast({
-							title: res.msg,
-							icon: 'none'
-						});
-					},
-					rej => {}
-				);
-			},
-			// 时间戳
-			initTime() {
-				const now = new Date();
-				this.timestamp = now.getTime(); // 例如:'2023-04-01 12:00:00'
-			},
-			// initWebSocket() {
-			//       const liveWS = new LiveWS('ws://your-server.com', 123, 456);
-
-			//       // 从 URL 中解析 timestamp
-			//       const urlParams = new URL(liveWS.url).searchParams;
-			//       this.timestamp = urlParams.get('timestamp');
-			//       // console.log('Timestamp:', timestamp);
-			//     },
-
-			// 弹幕滚动
-			lowerChat: function(e) {
-				console.log(e)
-			},
-			scroll: function(e) {
-				console.log(e)
-				this.old.scrollTop = e.detail.scrollTop
-			},
-
-
-			loadmore() {
-				// for (let i = 0; i < 30; i++) {
-				//   this.indexList.push({
-				//     url: this.shopList[uni.$u.random(0, this.shopList.length - 1)],
-				//   });
-				// }
-			},
-
-			// 弹幕
-			scrollchat() {
-				// this.loadmore();
-			},
-
-
-			noredanswer() {
-				if (this.Answerlistall > 0) {
-					this.showAnswer = !this.this.showAnswer
-				} else {
-					uni.showToast({
-						title: '暂无题目',
-						icon: 'none',
-					});
-				}
-			},
-			redbagAnswer() {
-				this.showAnswerred = !this.showAnswerred
-				this.answerbtn = !this.answerbtn
-
-			},
-			submitAnswers() {
-				if (this.isSubmit) return;
-				this.isSubmit = true;
-				const data = {
-					questionId: this.answerlist.id,
-					answer: this.checkboxFormValue
-				}
-				submitAnswer(data).then(res => {
-					if (res.code == 200) {
-
-						uni.showToast({
-							title: res.msg,
-							icon: 'none',
-						});
-					}
-					// 本地切换下一题
-					if (this.answerfrist < this.Answerlistall - 1) {
-						this.answerfrist++;
-						this.answerlist = this.allAnswerLists[this.answerfrist];
-						this.answerlist.content = JSON.parse(this.answerlist.content);
-					} else {
-						uni.showToast({
-							title: '已是最后一题',
-							icon: 'none'
-						});
-						this.showAnswer = false; // 自动关闭弹窗
-					}
-					this.checkboxValue = []
-					this.checkboxFormValue = "";
-					uni.showToast({
-						title: res.msg,
-						icon: 'none'
-					});
-				}).finally(e => {
-					this.isSubmit = false;
-				})
-			},
-			// handleCheckboxSelect(value) {
-			// 	const index = this.checkboxValue.indexOf(value)
-			// 	console.log(value)
-			// 	if (this.answerlist.type == 1) {
-			// 		this.checkboxValue = [value]
-			// 		this.checkboxFormValue = this.checkboxValue.join(',')
-			// 		setTimeout(() => {
-			// 		      uni.showToast({
-			// 		        title: '准备下一题',
-			// 		        icon: 'none',
-			// 		        duration: 2000
-			// 		      });
-			// 		    }, 1000);
-			// 		this.submitAnswers()
-			// 		console.log(this.checkboxValue)
-			// 	} else if (this.answerlist.type == 2) {
-			// 		if (index > -1) {
-			// 			this.checkboxValue.splice(index, 1)
-			// 			this.checkboxFormValue = this.checkboxValue.join(',')
-			// 		} else {
-			// 			this.checkboxValue.push(value)
-			// 			this.checkboxFormValue = this.checkboxValue.join(',')
-			// 		}
-			// 		console.log(this.checkboxFormValue)
-			// 	}
-			// },
-			getAnswerlists() {
-				if (!this.liveId) return;
-				const data = {
-					liveId: this.liveId
-				}
-				getAnswerlist(data).then(res => {
-					if (res.code == 200) {
-						if (res.data.length > 0) {
-							this.allAnswerLists = res.data; // 存储所有题目
-							this.Answerlistall = res.data.length;
-							if (this.allAnswerLists.length > 0) {
-								this.answerlist = this.allAnswerLists[0];
-								this.answerlist.content = JSON.parse(this.allAnswerLists[0].content);
-							}
-							this.showAnswer = true
-						} else {
-							this.showAnswer = false
-						}
-
-					}
-				})
-			},
-
-			openShop() {
-
-			},
-			openViews() {
-
-			},
-			close() {
-				this.showadd = !this.showadd
-			},
-			closes() {
-				this.showziliao = !this.showziliao
-			},
-			closest() {
-				this.showAnswer = !this.showAnswer
-			},
-			closestred() {
-				this.showAnswerred = !this.showAnswerred
-			},
-			closeanswer() {
-				this.answerbtn = !this.answerbtn
-			},
-			// 关闭小黄车
-			closeShop() {
-				this.shopping = !this.shopping
-			},
-			// 关闭红包
-			closeRed() {
-				this.showRed = !this.showRed
-			},
-			// longPress() {
-			// 	this.timeout = setTimeout(() => {
-			// 		this.isLongPress = true;
-			// 		// 执行保存图片的操作
-			// 		uni.saveImageToPhotosAlbum({
-			// 			filePath: this.livedata.qwQrCode, // 图片的本地路径或网络路径
-			// 			success: () => {
-			// 				uni.showToast({
-			// 					title: '保存成功'
-			// 				});
-			// 			},
-			// 			fail: () => {
-			// 				uni.showToast({
-			// 					title: '',
-			// 					icon: 'none'
-			// 				});
-			// 			}
-			// 		});
-			// 	}, 500); // 设置长按的阈值时间,这里是500毫秒
-			// },
-			// cancelLongPress() {
-			// 	clearTimeout(this.timeout);
-			// 	this.isLongPress = false;
-			// },
-			// 触摸开始
-			handleTouchStart() {
-				this.isZoom = true; // 触发放大效果
-			},
-			// 触摸结束
-			handleTouchEnd() {
-				this.isZoom = false; // 恢复原状
-			},
-			getEWechatSdk() {
-				// 只在H5平台执行
-				// #ifdef H5
-				let eWechatSdk = '';
-				if (/(Android)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'jWeixin';
-				} else if (/(iPhone|iPad|iPod|iOS)/i.test(navigator.userAgent)) {
-					eWechatSdk = 'wx';
-				} else {
-					eWechatSdk = 'jWeixin';
-				}
-				uni.setStorageSync("wxSdk", eWechatSdk);
-				// #endif
-			},
-			closeWebSocket() {
-				this.isManualClose = true;
-
-				// 清除所有定时器
-				clearInterval(this.pingpangTimes);
-				clearTimeout(this.reconnectTimer);
-
-				// 关闭 WebSocket 连接
-				if (this.socketInstance) {
-					try {
-						uni.closeSocket();
-						console.log('WebSocket 已安全关闭');
-					} catch (e) {
-						console.error('关闭 WebSocket 时出错:', e);
-					}
-					this.socketInstance = null;
-				}
-				isSocketOpen = false;
-			},
-			reConnect() {
-				var that = this;
-				try {
-					uni.closeSocket();
-				} catch (e) {
-
-				}
-				setTimeout(function() {
-					that.initSocket();
-				}, 10000);
-
-			},
-			startHeartbeat() {
-				clearInterval(this.pingpangTimes);
-
-				this.pingpangTimes = setInterval(() => {
-					if (!isSocketOpen) return;
-
-					const pingData = {
-						cmd: 'ping',
-						timestamp: Date.now()
-					};
-					uni.sendSocketMessage({
-						data: JSON.stringify(pingData),
-						success: () => console.debug('心跳发送成功'),
-						fail: (err) => {
-							console.error('心跳发送失败:', err);
-							this.scheduleReconnect();
-						}
-					});
-				}, 30000); // 30秒心跳间隔
-			},
-			initSocket() {
-				// 防止重复创建
-				if (isSocketOpen || this.reconnectCount >= this.maxReconnectAttempts) {
-					return;
-				}
-
-				this.closeWebSocket(); // 确保先关闭旧连接
-				this.isManualClose = false;
-
-				// 参数校验
-				if (!this.liveId) {
-					return;
-				}
-
-				// 生成签名
-				const signature = CryptoJS.HmacSHA256(
-					`${this.liveId}${this.userinfo.userId}${this.userType}${this.timestamp}`,
-					this.timestamp.toString()
-				).toString(CryptoJS.enc.Hex);
-
-				// 创建连接
-				try {
-					this.socketInstance = uni.connectSocket({
-						url: `${wsUrl}?userId=${this.userinfo.userId}&liveId=${this.liveId}&userType=${this.userType}&timestamp=${this.timestamp}&signature=${signature}`,
-						success: () => {
-							// 事件监听统一管理
-							this.setupSocketListeners();
-						},
-						fail: (err) => {
-							console.error('WebSocket 连接失败:', err);
-							this.scheduleReconnect();
-						}
-					});
-				} catch (e) {
-					console.error('创建 WebSocket 异常:', e);
-					this.scheduleReconnect();
-				}
-			},
-
-			// 设置 WebSocket 监听器
-			setupSocketListeners() {
-				uni.onSocketOpen(() => {
-					isSocketOpen = true;
-					this.reconnectCount = 0;
-					console.log('WebSocket 连接成功');
-					this.startHeartbeat();
-				});
-
-				uni.onSocketClose(() => {
-					isSocketOpen = false;
-					console.log('WebSocket 连接关闭');
-					if (!this.isManualClose) {
-						this.scheduleReconnect();
-					}
-				});
-
-				uni.onSocketError((err) => {
-					isSocketOpen = false;
-					console.error('WebSocket 错误:', err);
-					if (!this.isManualClose) {
-						this.scheduleReconnect();
-					}
-				});
-
-				uni.onSocketMessage((res) => {
-					try {
-						const redata = JSON.parse(res.data);
-						this.talklist.push(redata.data);
-						this.$nextTick(() => {
-							this.scrollIntoView = `list_${this.talklist.length - 1}`; // 最后一项的id
-						});
-						if (redata.data.cmd == 'deleteId') {
-							uni.$emit('deleteId');
-						}
-
-						// else if (redata.data.cmd == 'init') {
-						// 	uni.$emit('init', redata.data);
-						// } else if (redata.data.cmd == 'reload') {
-						// 	uni.$emit('reload');
-						// }
-						else if (redata.data.cmd == 'red') {
-							// 领红包
-							this.redInfo = JSON.parse(redata.data.data)
-							console.log(" 领红包1redata.data>>", redata.data)
-							console.log(" 领红包2redata.data.data>>", redata.data.data)
-							console.log(" 领红包3this.redInfo>>", this.redInfo)
-							console.log(" 领红包4this.redInfo.redId>>", this.redInfo.redId)
-							// let redId= this.redInfo.redId
-							// this.redInfo.redNum=redata.data.redNum
-							// this.redInfo.redStatus=redata.data.redStatus
-							// this.redInfo.duration=redata.data.duration
-
-						} else if (redata.data.cmd == 'sendRedPacketQuestion') {
-							const list = JSON.parse(redata.data.data)
-							this.redanswerAll = [...this.redanswerAll, ...list]
-							if (this.redanswerAll[1].randomAmount !== null) {
-								this.redanswertips = JSON.parse(this.redanswerAll[0]
-									.randomAmount)
-							}
-							console.log(this.redanswertips)
-							console.log(this.redanswerAll)
-						} else if (redata.data.cmd == 'entry') {
-							this.showWelcomeMessage = true
-							// setTimeout(() => {
-							// 	this.showWelcomeMessage = false;
-							//   }, 1000);
-							uni.$emit('entry', redata.data);
-						} else if (redata.data.cmd == 'live_start') {
-							// 直播开始
-						} else if (redata.data.cmd == 'live_end') {
-							// 直播结束
-						}
-					} catch (e) {
-						console.error('解析消息失败:', e);
-					}
-				})
-			},
-			scheduleReconnect() {
-				if (this.isManualClose || this.reconnectCount >= this.maxReconnectAttempts) return;
-
-				this.reconnectCount++;
-				const delay = Math.min(3000 * this.reconnectCount, 30000);
-
-				console.log(`将在 ${delay}ms 后重连 (尝试 ${this.reconnectCount}/${this.maxReconnectAttempts})`);
-
-				this.reconnectTimer = setTimeout(() => {
-					this.initSocket();
-				}, delay);
-			},
-			sendMsg() {
-				if (!isSocketOpen) {
-					uni.showToast({
-						title: "连接未建立,请稍后再试",
-						icon: 'none'
-					});
-					return;
-				}
-
-				if (!this.socketInstance) {
-					uni.showToast({
-						title: "连接异常",
-						icon: 'none'
-					});
-					return;
-				}
-
-				const data = {
-					liveId: this.liveId,
-					userId: this.userinfo.userId,
-					userType: 0,
-					cmd: "sendMsg",
-					msg: this.value,
-					nickName: this.userinfo.nickName,
-					avatar: this.userinfo.avatar
-				};
-
-				if (!this.value.trim()) { // 优化空消息判断
-					uni.showToast({
-						title: "不能发送空消息",
-						icon: 'none'
-					});
-					return;
-				}
-
-				// 使用正确的实例 this.socketInstance 发送消息
-				this.socketInstance.send({
-					data: JSON.stringify(data),
-					success: () => {
-						console.log("发送成功");
-						this.value = ''; // 清空输入框
-					},
-					fail: (err) => {
-						console.error("发送失败:", err);
-						uni.showToast({
-							title: "发送失败,请重试",
-							icon: 'none'
-						});
-					}
-				});
-			},
-		},
-	};
-</script>
-
-<style scoped lang="scss">
-	.loading-more,
-	.no-more {
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		padding: 20rpx 0;
-		color: #999;
-		font-size: 24rpx;
-	}
-
-	.loading-more {
-		flex-direction: column;
-	}
-
-	/* button自带样式清除 */
-	.student-orther-icon button::after {
-		border: none !important;
-		padding: 0 !important;
-		margin: 0 !important;
-	}
-
-	.student-orther-icon button {
-		background-color: transparent !important;
-		padding: 0 !important;
-		line-height: inherit !important;
-		margin: 0 !important;
-		width: auto !important;
-		font-weight: 500 !important;
-		border-radius: none !important;
-	}
-
-	// 抽奖
-	// .answerpop {
-	// 	background: linear-gradient(to right, #fff7f8, #fee1e2);
-	// 	margin-top: 30rpx;
-	// 	padding: 10rpx 20rpx;
-	// 	width: calc(100% - 40rpx);
-	// 	border-radius: 20rpx;
-	// 	display: flex;
-	// 	align-items: center;
-	// 	justify-content: space-between;
-	// 	box-shadow: 2px 2px 4px 0 rgba(255, 124, 126, 0.1);
-
-	// 	.answera {
-	// 		display: flex;
-	// 		justify-content: center;
-	// 		background-color: #fff;
-	// 		padding: 20rpx 0;
-	// 		width: 35%;
-	// 		border-radius: 40rpx;
-	// 		align-items: center;
-	// 		margin: 10rpx 0;
-	// 		box-shadow: 2px 2px 4px 0 rgba(72, 72, 72, 0.1);
-
-	// 		image {
-	// 			width: 40rpx;
-	// 			height: 40rpx;
-	// 			margin-right: 10rpx;
-	// 		}
-	// 	}
-	// }
-
-	// .submitbtn {
-	// 	width: 260rpx;
-	// 	margin: 0 auto;
-	// 	text-align: center;
-	// 	border-radius: 80rpx;
-	// 	padding: 20rpx 0;
-	// 	color: #fff;
-	// 	background-color: #ff5c03;
-	// }
-
-	// .itemanswer {
-	// 	padding: 20rpx 20rpx;
-	// 	text-align: center;
-	// 	border-radius: 80rpx;
-	// 	border: 2rpx solid #dddddd;
-	// 	margin: 12rpx 0;
-	// 	color: #555;
-	// 	width: calc(100% - 40rpx);
-	// }
-
-	// .answeract {
-	// 	background-color: rgba(0, 202, 166, 1);
-	// 	color: #fff;
-	// }
-
-	// .answerbox {
-	// 	width: 600rpx;
-	// 	border-radius: 20rpx;
-	// }
-
-	.welcome-message {
-		position: fixed;
-		width: 100%;
-		bottom: 460rpx;
-		left: 50%;
-		transform: translateX(-50%);
-		color: white;
-		padding: 10px 20px;
-		border-radius: 20px;
-		animation: fadeOut 1s ease 1s forwards;
-		z-index: 1000;
-	}
-
-	@keyframes fadeOut {
-		from {
-			opacity: 1;
-		}
-
-		to {
-			opacity: 0;
-		}
-	}
-
-	// .container {
-	// 	position: relative;
-	// 	width: 100%;
-	// 	height: 100vh;
-	// 	overflow: hidden;
-	// }
-
-	// .talktext {
-	// 	border-radius: 8rpx;
-	// 	background-color: rgba(255, 255, 255, 0.1);
-
-	// 	view {
-	// 		width: 100%;
-	// 	}
-	// }
-
-	.talk-list {
-		border-radius: 30rpx;
-		background-color: rgba(33, 33, 33, 0.5);
-		padding: 10rpx 30rpx;
-	}
-
-	// .zoom-button-active {
-	// 	transform: scale(1.5);
-	// }
-
-	// .background-image {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 0;
-	// }
-
-	// .background-images {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: -40rpx;
-	// 	width: 110%;
-	// 	height: 110%;
-	// 	object-fit: cover;
-	// 	filter: blur(20px);
-	// 	z-index: 6;
-	// }
-
-	// .blackbg {
-	// 	position: absolute;
-	// 	top: 0;
-	// 	left: 0;
-	// 	width: 100%;
-	// 	height: 100%;
-	// 	background: rgba(0, 0, 0, 0.7);
-	// 	object-fit: cover;
-	// 	filter: blur(10px);
-	// 	z-index: 1;
-	// }
-
-	.content {
-		position: relative;
-		z-index: 2;
-		height: 100%;
-		width: 100%;
-		top: 0;
-		left: 0;
-		display: flex;
-		flex-direction: column;
-		justify-content: space-between;
-
-		.content-top {
-			width: 100%;
-			margin-top: 150rpx;
-			display: flex;
-			align-items: center;
-			justify-content: space-between;
-			padding: 0 24rpx;
-			box-sizing: border-box;
-
-			.sum {
-				width: 80rpx;
-				height: 52rpx;
-				background: rgba(0, 0, 0, 0.5);
-				border-radius: 26rpx 26rpx 26rpx 26rpx;
-				font-size: 24rpx;
-				color: #FFFFFF;
-				text-align: center;
-				line-height: 52rpx;
-
-			}
-		}
-
-		.follow-btn {
-			padding: 8rpx 16rpx;
-			background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-			border-radius: 26rpx;
-			font-weight: 500;
-			font-size: 26rpx;
-			color: #FFFFFF;
-		}
-	}
-
-	.videolist {
-		position: relative;
-	}
-
-	.video {
-		height: 100vh;
-		/* 占屏幕高度的80% */
-		width: 100%;
-		background-color: rgba(0, 0, 0, 0.8);
-	}
-
-	.videotop {
-		width: 100%;
-		height: 100%;
-	}
-
-	.video_row {
-		width: 100%;
-		max-height: 500rpx;
-		overflow: hidden;
-		margin-top: 360rpx;
-	}
-
-	.popup-video {
-		position: absolute;
-		top: 30%;
-		height: 500rpx;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-		justify-content: center;
-		width: 100%;
-		color: #fff;
-		z-index: 9;
-
-		.more {
-			background-color: #3280fe;
-			border-radius: 80rpx;
-			width: 280rpx;
-			text-align: center;
-			height: 60rpx;
-			line-height: 60rpx;
-		}
-	}
-
-	.icon-bg {
-		background-color: rgba(157, 157, 157, 0.8);
-		border-radius: 50%;
-		width: 72rpx;
-		height: 72rpx;
-		display: flex;
-		justify-content: center;
-		align-items: center;
-		transition: transform 0.2s ease;
-	}
-
-	.list {
-		width: 80%;
-		margin-bottom: 20rpx;
-		animation: xxxawdawd .2s;
-	}
-
-	@keyframes xxxawdawd {
-		from {
-			margin-top: 0rpx;
-			opacity: 0;
-		}
-
-		to {
-			margin-top: 20rpx;
-			opacity: 1;
-		}
-	}
-
-	.shop-prompt {
-		position: absolute;
-		bottom: 600rpx;
-		left: 24rpx;
-		padding: 6rpx 20rpx;
-		background: rgba(230, 154, 34, 0.7);
-		border-radius: 24rpx;
-		z-index: 9;
-		font-weight: 500;
-		font-size: 26rpx;
-		color: #FFFFFF;
-		transition: opacity 0.3s ease;
-	}
-
-	.siderow-group {
-		position: absolute;
-		top: 56%;
-		right: 50rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-	}
-
-	.side-group {
-		position: absolute;
-		// top: 30%;
-		top: 56%;
-		right: 50rpx;
-		z-index: 9;
-		display: flex;
-		flex-direction: column;
-		align-items: center;
-
-		.side-item {
-			font-weight: 500;
-			font-size: 24rpx;
-			color: #FFFFFF;
-			margin-bottom: 32rpx;
-			text-align: center;
-
-			button {
-				background-color: transparent;
-				margin: 0;
-				line-height: 1;
-				padding: 0;
-			}
-
-			image {
-				width: 72rpx;
-				height: 72rpx;
-			}
-		}
-
-
-	}
-
-	.red-box {
-		.button {
-			margin: 0 auto;
-			width: 80%;
-			line-height: 88rpx;
-			height: 88rpx;
-			background: linear-gradient(90deg, #FF5701 0%, #FFB501 100%);
-			box-shadow: 0rpx 8rpx 8rpx 0rpx rgba(238, 124, 80, 0.2);
-			border-radius: 44rpx 44rpx 44rpx 44rpx;
-			font-weight: 600;
-			font-size: 32rpx;
-			color: #FFFFFF;
-			text-align: center;
-		}
-	}
-
-	.view-box {
-		position: relative;
-		height: 40vh;
-		/* 设置弹出层高度为视窗高度的70% */
-		padding: 40rpx 0rpx 120rpx;
-		box-sizing: border-box;
-		display: flex;
-		flex-direction: column;
-
-		.scroll-content {
-			flex: 1;
-			overflow-y: auto;
-			padding: 0 40rpx;
-		}
-
-		.bottom {
-			padding: 20rpx 40rpx;
-			position: absolute;
-			bottom: 0;
-			width: 100%;
-			box-shadow: 0rpx -4rpx 10rpx 0rpx rgba(195, 195, 195, 0.3);
-			background: #fff;
-		}
-	}
-
-	.shoppop {
-		padding: 22rpx 16rpx;
-
-		.shoppop-top {
-			display: flex;
-			justify-content: space-between;
-			align-items: center;
-			padding: 0 16rpx 22rpx;
-
-			.search-input {
-				width: 414rpx;
-				height: 76rpx;
-				background: #FFFFFF;
-				border-radius: 36rpx;
-				margin-left: 20rpx;
-				padding: 0 32rpx;
-				box-sizing: border-box;
-				font-size: 24rpx;
-				margin-right: 24rpx;
-
-			}
-
-			.search-top {
-				font-size: 18rpx;
-				color: #222222;
-			}
-		}
-
-
-		.shop-list {
-			overflow: hidden;
-
-			.list-item {
-				display: flex;
-				align-items: center;
-				padding: 20rpx 16rpx;
-				background: #FFFFFF;
-				border-radius: 16rpx;
-				margin-bottom: 16rpx;
-
-				.goods-img {
-					width: 200rpx;
-					height: 200rpx;
-					border-radius: 16rpx;
-					overflow: hidden;
-					position: relative;
-					margin-right: 24rpx;
-
-					image {
-						width: 100%;
-						height: 100%;
-					}
-
-					.goods-label {
-						position: absolute;
-						top: 0;
-						width: 64rpx;
-						height: 40rpx;
-						background: rgba(0, 0, 0, 0.5);
-						border-radius: 16rpx 0rpx 16rpx 0rpx;
-						text-align: center;
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #FFFFFF;
-					}
-				}
-
-				.goods-right {
-					flex: 1;
-
-					.goods-title {
-						font-weight: 500;
-						font-size: 28rpx;
-						color: #000000;
-
-					}
-
-					.goods-details {
-						font-size: 24rpx;
-						color: #999999;
-						margin: 10rpx 0 20rpx;
-					}
-
-					.goods-people {
-						font-size: 22rpx;
-						color: #E69A22;
-						height: 56rpx;
-					}
-
-					.goods-shop {
-						display: flex;
-						justify-content: space-between;
-
-						.nummber {
-							color: #FF5C03;
-							font-size: 22rpx;
-							font-weight: 500;
-						}
-
-						.btn-group {
-							text-align: center;
-							line-height: 56rpx;
-
-							.collect-btn {
-								width: 72rpx;
-								background: #F5F7FA;
-								border-radius: 8rpx 0rpx 0rpx 8rpx;
-
-							}
-
-							.shop-btn {
-								width: 152rpx;
-								background: linear-gradient(270deg, #FF5C03 0%, #FFAC64 100%);
-								border-radius: 0rpx 8rpx 8rpx 0rpx;
-								font-weight: 500;
-								font-size: 26rpx;
-								color: #FFFFFF;
-
-							}
-						}
-					}
-				}
-			}
-		}
-	}
-
-	:deep(.u-list-item) {
-		width: 100%;
-		display: flex;
-		align-items: center;
-	}
-
-	:deep(.u-safe-area-inset-bottom) {
-		padding-bottom: 0
-	}
-</style>

BIN
static/images/a.jpg


BIN
static/images/like.png


BIN
static/images/live/like.png


BIN
static/images/live/share.png


BIN
static/images/red_bg.png


BIN
static/images/red_head.png


BIN
static/images/red_title.png


BIN
static/images/share.png


+ 1 - 1
unpackage/dist/dev/mp-weixin/api/home.js

@@ -1 +1 @@
-"use strict";const s=require("../common/request.js");let e=new s.Request().http;function n(t){return e("/app/live/live",t,"GET","application/json;charset=UTF-8",!1)}function i(t){return e("/app/live/msgList",t,"GET","application/json;charset=UTF-8")}function r(t){return e("/app/question/questionList",t,"GET","application/json;charset=UTF-8")}function a(t){return e("/app/question/answer",t,"POST","application/json;charset=UTF-8")}exports.getAnswerlist=r;exports.getlive=n;exports.gettextlist=i;exports.submitAnswer=a;
+"use strict";const t=require("../common/request.js");let i=new t.Request().http;function s(e){return i("/app/live/live",e,"GET","application/json;charset=UTF-8",!1)}exports.getlive=s;

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/api/live.js


+ 1 - 4
unpackage/dist/dev/mp-weixin/app.json

@@ -4,14 +4,11 @@
     "pages/home/living",
     "pages/user/index",
     "pages/list/index",
-    "pages/home/live",
     "pages/games/index",
     "pages/auth/findpass",
     "pages/auth/h5WxLogin",
     "pages/auth/loginIndex",
-    "pages/auth/register",
-    "pages_no/zuizao",
-    "pages_no/living827"
+    "pages/auth/register"
   ],
   "subPackages": [
     {

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/common/assets.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/common/vendor.js


+ 1 - 1
unpackage/dist/dev/mp-weixin/pages/auth/h5WxLogin.js

@@ -1 +1 @@
-"use strict";const n=require("../../common/vendor.js"),a=require("../../api/login.js"),s=require("../../common/assets.js"),d=()=>String(navigator.userAgent.toLowerCase().match(/MicroMessenger/i))==="micromessenger",l={data(){return{code:null}},onLoad(e){this.getWechatCode()},onUnload(){},mounted(){},methods:{loginByMp(){if(this.code==null)return;n.index.showLoading({title:"处理中..."});let e=this;var o={code:this.code};a.loginByWeChat(o).then(t=>{n.index.hideLoading(),t.code==200?(n.index.setStorageSync("AppToken",t.token),n.index.setStorageSync("userInfo",JSON.stringify(t.user)),n.index.$emit("refreshIM"),e.goToLanch()):n.index.showToast({title:t.msg,icon:"none"})},t=>{})},getWechatCode(){if(d){let e="wx9ea36eecd281bcd3",o=this.getUrlCode().code,t=window.location.href;o==null||o===""?window.location.href="https://open.weixin.qq.com/connect/oauth2/authorize?appid="+e+"&redirect_uri="+encodeURIComponent(t)+"&response_type=code&scope=snsapi_userinfo&state=STATE#wechat_redirect":this.code=o}},getUrlCode(){var e=location.search,o=new Object;if(e.indexOf("?")!=-1)for(var t=e.substr(1),i=t.split("&"),r=0;r<i.length;r++)o[i[r].split("=")[0]]=i[r].split("=")[1];return console.log(o),o},goToLanch(){let e=n.index.getStorageSync("beforLoginPage");console.log("beforLoginUrl:"+e),n.index.reLaunch({url:e})}}};function g(e,o,t,i,r,c){return{a:s._imports_0$4,b:n.o(u=>c.loginByMp())}}const h=n._export_sfc(l,[["render",g]]);wx.createPage(h);
+"use strict";const n=require("../../common/vendor.js"),a=require("../../api/login.js"),s=require("../../common/assets.js"),d=()=>String(navigator.userAgent.toLowerCase().match(/MicroMessenger/i))==="micromessenger",l={data(){return{code:null}},onLoad(e){this.getWechatCode()},onUnload(){},mounted(){},methods:{loginByMp(){if(this.code==null)return;n.index.showLoading({title:"处理中..."});let e=this;var o={code:this.code};a.loginByWeChat(o).then(t=>{n.index.hideLoading(),t.code==200?(n.index.setStorageSync("AppToken",t.token),n.index.setStorageSync("userInfo",JSON.stringify(t.user)),n.index.$emit("refreshIM"),e.goToLanch()):n.index.showToast({title:t.msg,icon:"none"})},t=>{})},getWechatCode(){if(d){let e="wx9ea36eecd281bcd3",o=this.getUrlCode().code,t=window.location.href;o==null||o===""?window.location.href="https://open.weixin.qq.com/connect/oauth2/authorize?appid="+e+"&redirect_uri="+encodeURIComponent(t)+"&response_type=code&scope=snsapi_userinfo&state=STATE#wechat_redirect":this.code=o}},getUrlCode(){var e=location.search,o=new Object;if(e.indexOf("?")!=-1)for(var t=e.substr(1),i=t.split("&"),r=0;r<i.length;r++)o[i[r].split("=")[0]]=i[r].split("=")[1];return console.log(o),o},goToLanch(){let e=n.index.getStorageSync("beforLoginPage");console.log("beforLoginUrl:"+e),n.index.reLaunch({url:e})}}};function g(e,o,t,i,r,c){return{a:s._imports_0$3,b:n.o(u=>c.loginByMp())}}const h=n._export_sfc(l,[["render",g]]);wx.createPage(h);

+ 1 - 1
unpackage/dist/dev/mp-weixin/pages/auth/loginIndex.js

@@ -1 +1 @@
-"use strict";const e=require("../../common/vendor.js");require("../../api/login.js");const g=require("../../common/assets.js"),u={data(){return{btnLoading:!1,agree:!1}},onLoad(){if(!this.$isLogin()){let t=getCurrentPages(),o=t[t.length-3];if(t.length>2&&o&&(o.route=="pages/auth/login"||o.route=="pages/auth/loginIndex"||o.route=="pages/common/launch"))e.index.navigateBack({delta:2});else if(String(navigator.userAgent.toLowerCase().match(/MicroMessenger/i))==="micromessenger"){const s=getCurrentPages();if(s.length>1){const a=s[s.length-2],n=a.options;if(n&&JSON.stringify(n)!="{}"){let r="/"+a.route+e.index.$u.queryParams(n);e.index.setStorageSync("beforLoginPage",r)}else e.index.setStorageSync("beforLoginPage","/"+a.route);e.index.redirectTo({url:"/pages/auth/h5WxLogin"})}else this.submit()}else e.index.redirectTo({url:"/pages/auth/login"})}},onShow(){this.$isLogin()&&e.index.reLaunch({url:"../course/index",animationType:"none",animationDuration:2e3})},methods:{goToWeb(t){e.index.setStorageSync("url",t==0?"https://userapp.his.cdwjyyh.com/web/userAgreement":"https://userapp.his.cdwjyyh.com/web/privacyPolicy"),e.index.navigateTo({url:"/pages/index/h5"})},handleAgree(){this.agree=!this.agree},submit(){this.$showLoginPage()},handleOtherLogin(){e.index.redirectTo({url:"/pages/auth/login"})},close(t){this.$refs.popup.close(),t=="agree"&&(this.agree=!0,this.submit())}}};function h(t,o,s,a,n,r){return{a:n.btnLoading,b:n.btnLoading,c:e.o((...i)=>r.submit&&r.submit(...i)),d:n.btnLoading,e:e.o((...i)=>r.handleOtherLogin&&r.handleOtherLogin(...i)),f:g._imports_0$5,g:!n.agree,h:g._imports_1$4,i:n.agree,j:e.o((...i)=>r.handleAgree&&r.handleAgree(...i)),k:e.o(i=>r.goToWeb(0)),l:e.o(i=>r.goToWeb(1))}}const c=e._export_sfc(u,[["render",h],["__scopeId","data-v-648b5fa7"]]);wx.createPage(c);
+"use strict";const e=require("../../common/vendor.js");require("../../api/login.js");const g=require("../../common/assets.js"),u={data(){return{btnLoading:!1,agree:!1}},onLoad(){if(!this.$isLogin()){let t=getCurrentPages(),o=t[t.length-3];if(t.length>2&&o&&(o.route=="pages/auth/login"||o.route=="pages/auth/loginIndex"||o.route=="pages/common/launch"))e.index.navigateBack({delta:2});else if(String(navigator.userAgent.toLowerCase().match(/MicroMessenger/i))==="micromessenger"){const s=getCurrentPages();if(s.length>1){const a=s[s.length-2],n=a.options;if(n&&JSON.stringify(n)!="{}"){let r="/"+a.route+e.index.$u.queryParams(n);e.index.setStorageSync("beforLoginPage",r)}else e.index.setStorageSync("beforLoginPage","/"+a.route);e.index.redirectTo({url:"/pages/auth/h5WxLogin"})}else this.submit()}else e.index.redirectTo({url:"/pages/auth/login"})}},onShow(){this.$isLogin()&&e.index.reLaunch({url:"../course/index",animationType:"none",animationDuration:2e3})},methods:{goToWeb(t){e.index.setStorageSync("url",t==0?"https://userapp.his.cdwjyyh.com/web/userAgreement":"https://userapp.his.cdwjyyh.com/web/privacyPolicy"),e.index.navigateTo({url:"/pages/index/h5"})},handleAgree(){this.agree=!this.agree},submit(){this.$showLoginPage()},handleOtherLogin(){e.index.redirectTo({url:"/pages/auth/login"})},close(t){this.$refs.popup.close(),t=="agree"&&(this.agree=!0,this.submit())}}};function h(t,o,s,a,n,r){return{a:n.btnLoading,b:n.btnLoading,c:e.o((...i)=>r.submit&&r.submit(...i)),d:n.btnLoading,e:e.o((...i)=>r.handleOtherLogin&&r.handleOtherLogin(...i)),f:g._imports_0$4,g:!n.agree,h:g._imports_1$4,i:n.agree,j:e.o((...i)=>r.handleAgree&&r.handleAgree(...i)),k:e.o(i=>r.goToWeb(0)),l:e.o(i=>r.goToWeb(1))}}const c=e._export_sfc(u,[["render",h],["__scopeId","data-v-648b5fa7"]]);wx.createPage(c);

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages/home/live.js


+ 0 - 13
unpackage/dist/dev/mp-weixin/pages/home/live.json

@@ -1,13 +0,0 @@
-{
-  "navigationBarTitleText": "",
-  "navigationBarTextStyle": "black",
-  "enablePullDownRefresh": false,
-  "navigationStyle": "custom",
-  "usingComponents": {
-    "u-tabs": "../../uni_modules/uview-plus/components/u-tabs/u-tabs",
-    "u-avatar": "../../uni_modules/uview-plus/components/u-avatar/u-avatar",
-    "u-input": "../../uni_modules/uview-plus/components/u-input/u-input",
-    "u-icon": "../../uni_modules/uview-plus/components/u-icon/u-icon",
-    "u-popup": "../../uni_modules/uview-plus/components/u-popup/u-popup"
-  }
-}

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages/home/live.wxml


+ 0 - 1
unpackage/dist/dev/mp-weixin/pages/home/live.wxss

@@ -1 +0,0 @@
-.welcome-message.data-v-81fcd0c9{position:fixed;width:100%;bottom:120rpx;left:50%;transform:translate(-50%);color:#666;padding:10px 20px;border-radius:20px;animation:fadeOut-81fcd0c9 1s ease 1s forwards;z-index:1000}@keyframes fadeOut-81fcd0c9{0%{opacity:1}to{opacity:0}}.live.data-v-81fcd0c9{height:100%;overflow:hidden}.list.data-v-81fcd0c9{width:80%;margin-bottom:20rpx;animation:xxxawdawd-81fcd0c9 .2s}@keyframes xxxawdawd-81fcd0c9{0%{margin-top:0rpx;opacity:0}to{margin-top:20rpx;opacity:1}}.vedio.data-v-81fcd0c9{height:500rpx;width:100%;background-color:rgba(0,0,0,.6);position:relative}.videotop.data-v-81fcd0c9{width:100%;height:100%}.popup-video.data-v-81fcd0c9{position:absolute;top:0;height:500rpx;display:flex;flex-direction:column;align-items:center;justify-content:center;width:100%;color:#fff;background-color:rgba(0,0,0,.6)}.popup-video .more.data-v-81fcd0c9{background-color:#3280fe;border-radius:80rpx;width:280rpx;text-align:center;height:60rpx;line-height:60rpx}.textscll.data-v-81fcd0c9{position:absolute;top:0;z-index:999}.reflash.data-v-81fcd0c9{border:2rpx solid #888;border-radius:80rpx;padding:4rpx 16rpx;color:#888}.talktext.data-v-81fcd0c9{border-radius:8rpx}.talktext view.data-v-81fcd0c9{width:100%}.bot_talk.data-v-81fcd0c9{width:calc(100% - 40rpx);display:flex;justify-content:space-between;align-items:center;position:fixed;bottom:0;padding:20rpx}.bot_talk .sent.data-v-81fcd0c9{width:120rpx;text-align:center;height:60rpx;line-height:60rpx;background-color:#3280fe;color:#fff;border-radius:40rpx;font-size:24rpx}.invite-member.data-v-81fcd0c9{height:55px;width:50px;position:fixed;bottom:80px;right:10px;cursor:pointer}.invite-member .weimg.data-v-81fcd0c9{position:relative}.invite-member .addwe.data-v-81fcd0c9{position:absolute;left:-7%;bottom:4rpx;color:#fff;background-color:#fc285c;font-size:24rpx;border-radius:20rpx;padding:4rpx 12rpx}.addchat.data-v-81fcd0c9{height:450rpx}

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages/home/living.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages/home/living.wxml


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages/home/living.wxss


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages/list/index.js


+ 1 - 1
unpackage/dist/dev/mp-weixin/pages/list/index.wxml

@@ -1 +1 @@
-<view class="content data-v-7bd28468"><mescroll-body wx:if="{{f}}" class="r data-v-7bd28468" u-s="{{['d']}}" u-r="mescrollRef" bindinit="{{c}}" binddown="{{d}}" bindup="{{e}}" u-i="7bd28468-0" bind:__l="__l" u-p="{{f}}"><view class="list data-v-7bd28468"><view wx:for="{{a}}" wx:for-item="item" wx:key="n" class="list-item data-v-7bd28468" bindtap="{{item.m}}"><image wx:if="{{item.a}}" class="data-v-7bd28468" src="{{item.b}}"></image><video wx:if="{{item.c}}" class="data-v-7bd28468" id="{{item.d}}" src="{{item.e}}" autoplay="{{false}}" muted controls="{{false}}" object-fit="contain" custom-cache="{{false}}" enable-progress-gesture="{{false}}" show-center-play-btn="{{false}}" http-cache="{{false}}" muted="{{true}}" binderror="{{item.f}}"></video><video wx:if="{{item.g}}" class="data-v-7bd28468" id="{{item.h}}" src="{{item.i}}" autoplay="{{false}}" muted controls="{{false}}" object-fit="contain" custom-cache="{{false}}" enable-progress-gesture="{{false}}" show-center-play-btn="{{false}}" http-cache="{{false}}" loop="{{true}}" muted="{{true}}" binderror="{{item.j}}" bindloadedmetadata="{{item.k}}"></video><view class="info data-v-7bd28468"><text class="data-v-7bd28468">{{item.l}}</text></view></view></view></mescroll-body></view>
+<view class="content data-v-7bd28468"><mescroll-body wx:if="{{f}}" class="r data-v-7bd28468" u-s="{{['d']}}" u-r="mescrollRef" bindinit="{{c}}" binddown="{{d}}" bindup="{{e}}" u-i="7bd28468-0" bind:__l="__l" u-p="{{f}}"><view class="list data-v-7bd28468"><view wx:for="{{a}}" wx:for-item="item" wx:key="l" class="list-item data-v-7bd28468" bindtap="{{item.k}}"><video wx:if="{{item.a}}" class="data-v-7bd28468" id="{{item.b}}" src="{{item.c}}" autoplay="{{false}}" muted controls="{{false}}" object-fit="contain" custom-cache="{{false}}" enable-progress-gesture="{{false}}" show-center-play-btn="{{false}}" http-cache="{{false}}" muted="{{true}}" binderror="{{item.d}}"></video><video wx:if="{{item.e}}" class="data-v-7bd28468" id="{{item.f}}" src="{{item.g}}" autoplay="{{false}}" muted controls="{{false}}" object-fit="contain" custom-cache="{{false}}" enable-progress-gesture="{{false}}" show-center-play-btn="{{false}}" http-cache="{{false}}" loop="{{true}}" muted="{{true}}" binderror="{{item.h}}" bindloadedmetadata="{{item.i}}"></video><view class="info data-v-7bd28468"><text class="data-v-7bd28468">{{item.j}}</text></view></view></view></mescroll-body></view>

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_no/living827.js


+ 0 - 8
unpackage/dist/dev/mp-weixin/pages_no/living827.json

@@ -1,8 +0,0 @@
-{
-  "navigationBarTitleText": "",
-  "usingComponents": {
-    "u-avatar": "../uni_modules/uview-plus/components/u-avatar/u-avatar",
-    "u-input": "../uni_modules/uview-plus/components/u-input/u-input",
-    "u-popup": "../uni_modules/uview-plus/components/u-popup/u-popup"
-  }
-}

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_no/living827.wxml


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_no/living827.wxss


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_no/zuizao.js


+ 0 - 8
unpackage/dist/dev/mp-weixin/pages_no/zuizao.json

@@ -1,8 +0,0 @@
-{
-  "navigationBarTitleText": "",
-  "usingComponents": {
-    "u-avatar": "../uni_modules/uview-plus/components/u-avatar/u-avatar",
-    "u-input": "../uni_modules/uview-plus/components/u-input/u-input",
-    "u-popup": "../uni_modules/uview-plus/components/u-popup/u-popup"
-  }
-}

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_no/zuizao.wxml


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_no/zuizao.wxss


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/cart.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/confirmCreateOrder.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/confirmPackageOrder.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/goods.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/paymentOrder.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/refundOrder.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/store.js


Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/storeOrder.js


+ 1 - 1
unpackage/dist/dev/mp-weixin/pages_shop/storeOrderDelivery.js

@@ -1 +1 @@
-"use strict";const e=require("../common/vendor.js"),n=require("../common/assets.js"),d={data(){return{statusBarHeight:e.index.getStorageSync("menuInfo").statusBarHeight,orderId:null,deliveryId:null,express:{},expressList:[]}},onLoad(r){this.orderId=r.orderId,this.getExpress()},methods:{getExpress(){var r={orderId:this.orderId};getExpress(r).then(t=>{t.code==200?(this.express=t.express,this.expressList=t.data,this.deliveryId=t.deliveryId):e.index.showToast({icon:"none",title:"请求失败"})})},back(){e.index.navigateBack()},copyOrderSn(r){e.index.setClipboardData({data:r,success:()=>{e.index.showToast({title:"内容已成功复制到剪切板",icon:"none"})}})},callPhone(r){e.index.makePhoneCall({phoneNumber:r})}}};function a(r,t,p,x,s,o){return e.e({a:n._imports_0$13,b:s.statusBarHeight,c:n._imports_1$9,d:e.o((...i)=>o.back&&o.back(...i)),e:e.t(s.deliveryId),f:e.o(i=>o.copyOrderSn(s.deliveryId)),g:e.t(s.express.name),h:s.expressList!=null},s.expressList!=null?e.e({i:s.expressList.Traces!=null},s.expressList.Traces!=null?{j:e.f(s.expressList.Traces,(i,c,u)=>({a:e.t(i.AcceptStation),b:e.t(i.AcceptTime),c})),k:n._imports_2$6,l:n._imports_3$3}:{}):{})}const l=e._export_sfc(d,[["render",a]]);wx.createPage(l);
+"use strict";const e=require("../common/vendor.js"),n=require("../common/assets.js"),d={data(){return{statusBarHeight:e.index.getStorageSync("menuInfo").statusBarHeight,orderId:null,deliveryId:null,express:{},expressList:[]}},onLoad(r){this.orderId=r.orderId,this.getExpress()},methods:{getExpress(){var r={orderId:this.orderId};getExpress(r).then(t=>{t.code==200?(this.express=t.express,this.expressList=t.data,this.deliveryId=t.deliveryId):e.index.showToast({icon:"none",title:"请求失败"})})},back(){e.index.navigateBack()},copyOrderSn(r){e.index.setClipboardData({data:r,success:()=>{e.index.showToast({title:"内容已成功复制到剪切板",icon:"none"})}})},callPhone(r){e.index.makePhoneCall({phoneNumber:r})}}};function a(r,t,p,x,s,o){return e.e({a:n._imports_0$12,b:s.statusBarHeight,c:n._imports_1$8,d:e.o((...i)=>o.back&&o.back(...i)),e:e.t(s.deliveryId),f:e.o(i=>o.copyOrderSn(s.deliveryId)),g:e.t(s.express.name),h:s.expressList!=null},s.expressList!=null?e.e({i:s.expressList.Traces!=null},s.expressList.Traces!=null?{j:e.f(s.expressList.Traces,(i,c,u)=>({a:e.t(i.AcceptStation),b:e.t(i.AcceptTime),c})),k:n._imports_2$5,l:n._imports_3$2}:{}):{})}const l=e._export_sfc(d,[["render",a]]);wx.createPage(l);

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_shop/storeOrderRefundSubmit.js


+ 1 - 1
unpackage/dist/dev/mp-weixin/pages_shop/success.js

@@ -1 +1 @@
-"use strict";const e=require("../common/vendor.js"),t=require("../common/assets.js"),i={data(){return{order:null,orderCode:"",ids:[]}},onLoad(r){this.order=JSON.parse(decodeURIComponent(r.order)),this.orderCode=this.order&&this.order.orderCodes?this.order.orderCodes.join(","):this.order.orderCode||"",this.ids=this.order&&this.order.ids?this.order.ids:this.order.id?[this.order.id]:[]},methods:{copyOrderSn(r){e.index.setClipboardData({data:r,success:()=>{e.index.showToast({title:"内容已成功复制到剪切板",icon:"none"})}})},goOrderDetails(r){this.ids&&this.ids.length>1?e.index.navigateTo({url:"/pages_user/user/storeOrder?status="}):e.index.redirectTo({url:"/pages_user/user/storeOrderDetail?id="+this.ids[0]})}}};function n(r,a,h,u,o,s){return{a:t._imports_0$12,b:e.o(d=>s.goOrderDetails(o.order.id)),c:e.f(o.order.orderCodes,(d,_,l)=>({a:e.t(d),b:d})),d:e.o(d=>s.copyOrderSn(o.orderCode)),e:e.t(o.order.createTime)}}const c=e._export_sfc(i,[["render",n]]);wx.createPage(c);
+"use strict";const e=require("../common/vendor.js"),t=require("../common/assets.js"),i={data(){return{order:null,orderCode:"",ids:[]}},onLoad(r){this.order=JSON.parse(decodeURIComponent(r.order)),this.orderCode=this.order&&this.order.orderCodes?this.order.orderCodes.join(","):this.order.orderCode||"",this.ids=this.order&&this.order.ids?this.order.ids:this.order.id?[this.order.id]:[]},methods:{copyOrderSn(r){e.index.setClipboardData({data:r,success:()=>{e.index.showToast({title:"内容已成功复制到剪切板",icon:"none"})}})},goOrderDetails(r){this.ids&&this.ids.length>1?e.index.navigateTo({url:"/pages_user/user/storeOrder?status="}):e.index.redirectTo({url:"/pages_user/user/storeOrderDetail?id="+this.ids[0]})}}};function n(r,a,h,u,o,s){return{a:t._imports_0$11,b:e.o(d=>s.goOrderDetails(o.order.id)),c:e.f(o.order.orderCodes,(d,_,l)=>({a:e.t(d),b:d})),d:e.o(d=>s.copyOrderSn(o.orderCode)),e:e.t(o.order.createTime)}}const c=e._export_sfc(i,[["render",n]]);wx.createPage(c);

Fichier diff supprimé car celui-ci est trop grand
+ 0 - 0
unpackage/dist/dev/mp-weixin/pages_user/addAddress.js


+ 1 - 1
unpackage/dist/dev/mp-weixin/pages_user/address.js

@@ -1 +1 @@
-"use strict";const e=require("../common/vendor.js"),u=require("../api/order.js"),o=require("../common/assets.js"),h={data(){return{address:[]}},onLoad(){this.getUserAddr(),e.index.$on("refreshAddress",()=>{this.getUserAddr()})},methods:{getUserAddr(){this.userInfo=JSON.parse(e.index.getStorageSync("userInfo")),u.userAddr(this.userInfo.userId).then(s=>{s.code==200?(console.log("用户收货地址>>>>",s.data),this.address=s.data):e.index.showToast({title:s.msg,icon:"none"})},s=>{})},selectAddress(s){e.index.$emit("updateAddress",s),e.index.navigateBack({delta:1})},editAddress(s){e.index.navigateTo({url:"./addAddress?type=edit&addressId="+s.addressId})},delAddress(s){e.index.showModal({title:"提示",content:"确认删除此地址吗?",showCancel:!0,cancelText:"取消",confirmText:"确定",success:i=>{if(i.confirm){var c={addressId:s.addressId};u.delAddress(c).then(n=>{n.code==200?(e.index.showToast({icon:"success",title:"操作成功"}),this.getUserAddr()):e.index.showToast({icon:"none",title:"请求失败"})},n=>{})}}})},addAdress(){e.index.navigateTo({url:"./addAddress?type=add"})}}};function A(s,i,c,n,a,r){return e.e({a:e.f(a.address,(d,t,f)=>e.e({a:d.isDefault==1},d.isDefault==1?{}:{},{b:e.t(d.province),c:e.t(d.city),d:e.t(d.district),e:e.t(d.detail),f:e.t(d.realName),g:e.t(s.$parsePhone(d.phone)),h:e.o(l=>r.selectAddress(d),t),i:e.o(l=>r.delAddress(d),t),j:e.o(l=>r.editAddress(d),t),k:t})),b:o._imports_0$14,c:o._imports_1$10,d:a.address.length==0},a.address.length==0?{e:o._imports_2$2,f:e.o(d=>s.getAddressList())}:{},{g:e.o((...d)=>r.addAdress&&r.addAdress(...d))})}const g=e._export_sfc(h,[["render",A]]);wx.createPage(g);
+"use strict";const e=require("../common/vendor.js"),u=require("../api/order.js"),o=require("../common/assets.js"),h={data(){return{address:[]}},onLoad(){this.getUserAddr(),e.index.$on("refreshAddress",()=>{this.getUserAddr()})},methods:{getUserAddr(){this.userInfo=JSON.parse(e.index.getStorageSync("userInfo")),u.userAddr(this.userInfo.userId).then(s=>{s.code==200?(console.log("用户收货地址>>>>",s.data),this.address=s.data):e.index.showToast({title:s.msg,icon:"none"})},s=>{})},selectAddress(s){e.index.$emit("updateAddress",s),e.index.navigateBack({delta:1})},editAddress(s){e.index.navigateTo({url:"./addAddress?type=edit&addressId="+s.addressId})},delAddress(s){e.index.showModal({title:"提示",content:"确认删除此地址吗?",showCancel:!0,cancelText:"取消",confirmText:"确定",success:i=>{if(i.confirm){var c={addressId:s.addressId};u.delAddress(c).then(n=>{n.code==200?(e.index.showToast({icon:"success",title:"操作成功"}),this.getUserAddr()):e.index.showToast({icon:"none",title:"请求失败"})},n=>{})}}})},addAdress(){e.index.navigateTo({url:"./addAddress?type=add"})}}};function A(s,i,c,n,a,r){return e.e({a:e.f(a.address,(d,t,f)=>e.e({a:d.isDefault==1},d.isDefault==1?{}:{},{b:e.t(d.province),c:e.t(d.city),d:e.t(d.district),e:e.t(d.detail),f:e.t(d.realName),g:e.t(s.$parsePhone(d.phone)),h:e.o(l=>r.selectAddress(d),t),i:e.o(l=>r.delAddress(d),t),j:e.o(l=>r.editAddress(d),t),k:t})),b:o._imports_0$13,c:o._imports_1$9,d:a.address.length==0},a.address.length==0?{e:o._imports_2$1,f:e.o(d=>s.getAddressList())}:{},{g:e.o((...d)=>r.addAdress&&r.addAdress(...d))})}const g=e._export_sfc(h,[["render",A]]);wx.createPage(g);

+ 1 - 1
unpackage/dist/dev/mp-weixin/project.config.json

@@ -13,7 +13,7 @@
   },
   "compileType": "miniprogram",
   "libVersion": "3.4.2",
-  "appid": "wx73f85f8d62769119",
+  "appid": "wx503cf8ab31f83dd4",
   "projectname": "签约",
   "condition": {
     "search": {

BIN
unpackage/dist/dev/mp-weixin/static/images/a.jpg


BIN
unpackage/dist/dev/mp-weixin/static/images/like.png


BIN
unpackage/dist/dev/mp-weixin/static/images/live/like.png


BIN
unpackage/dist/dev/mp-weixin/static/images/live/share.png


BIN
unpackage/dist/dev/mp-weixin/static/images/red_bg.png


BIN
unpackage/dist/dev/mp-weixin/static/images/red_head.png


BIN
unpackage/dist/dev/mp-weixin/static/images/red_title.png


BIN
unpackage/dist/dev/mp-weixin/static/images/share.png


Certains fichiers n'ont pas été affichés car il y a eu trop de fichiers modifiés dans ce diff