liujiaxin 5 天之前
父節點
當前提交
02589964a4

+ 4 - 1
api/living.js

@@ -223,8 +223,11 @@ export function sendliveGift(data) {
   	return request('/app/live/completion/integral-logs',data,'GET','application/json;charset=UTF-8');
  }
 // 静默登录
+// export function loginByMp(data) {
+// 	return request('/liveAPP/app/wx/login', data, 'POST', 'application/json;charset=UTF-8');
+// }
 export function loginByMp(data) {
-	return request('/liveAPP/app/wx/login', data, 'POST', 'application/json;charset=UTF-8');
+	return request('/liveAPP/app/wx/loginByMiniApp', data, 'POST', 'application/json;charset=UTF-8');
 }
 export function getUserInfo() {
 	return request('/liveAPP/app/user/getUserInfo', null, 'GET');

+ 3 - 3
manifest.json

@@ -1,5 +1,5 @@
 {
-    "name" : "芳华选",
+    "name" : "芳华选",
     "appid" : "__UNI__D138114",
     "description" : "",
     "versionName" : "1.0.0",
@@ -69,7 +69,7 @@
     "quickapp" : {},
     /* 小程序特有相关 */
     "mp-weixin" : {
-        "appid" : "wx4d225cc86cc7885d",
+        "appid" : "wx776d6bd6848eec49",
         "setting" : {
             "urlCheck" : false,
             "minified" : true,
@@ -101,7 +101,7 @@
     "sassImplementationName" : "node-sass",
     "vueVersion" : "2",
     "h5" : {
-        "title" : "芳华选",
+        "title" : "芳华选",
         "devServer" : {
             "https" : false
         },

+ 2 - 2
pages.json

@@ -24,7 +24,7 @@
 		{
 			"path": "pages/home/index",
 			"style": {
-				"navigationBarTitleText": "芳华选",
+				"navigationBarTitleText": "芳华选",
 				"enablePullDownRefresh": false,
 				"navigationStyle": "custom",
 				"app-plus": {
@@ -994,7 +994,7 @@
 	],
 	"globalStyle": {
 		"navigationBarTextStyle": "black",
-		"navigationBarTitleText": "芳华选",
+		"navigationBarTitleText": "芳华选",
 		"navigationBarBackgroundColor": "#FFFFFF",
 		"backgroundColor": "#FFFFFF"
 	},

+ 1 - 1
pages/auth/login.vue

@@ -9,7 +9,7 @@
 							src="/static/images/logo.png">
 						</image>
 					</view>
-					<view class="title">芳华选</view>
+					<view class="title">芳华选</view>
 				</view>
 				<view class="login-notice">为了提供更优质的服务,请先登录</view>
 				<!-- <button

+ 1 - 1
pages/common/launch.vue

@@ -2,7 +2,7 @@
 	<view class="content">
 		<view class="loadding" v-if="loadding==true">
 			<image src="/static/images/logo.png"></image>
-			<text class="text">芳华选</text>
+			<text class="text">芳华选</text>
 		</view>
 	</view>
 </template>

+ 3 - 3
pages/home/index.vue

@@ -8,7 +8,7 @@
 					<!-- 这里是状态栏 -->
 					<view class="status_bar" :style="{height: statusBarHeight}"></view>
 					<view class="top-title">
-						<view class="name">芳华选</view>
+						<view class="name">芳华选</view>
 						<!-- <view class="dot">•</view><view class="sub-name">七彩互联网医院</view> -->
 					</view>
 					<!-- 搜索框、购物车、客服 -->
@@ -495,7 +495,7 @@
 		},
 		onShareAppMessage(res) {
 			return {
-				title: '芳华选',
+				title: '芳华选',
 				path: `/pages/common/launch`,
 				imageUrl: '/static/images/logo.png' //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
 			}
@@ -507,7 +507,7 @@
 		//分享到朋友圈
 		onShareTimeline(res) {
 			return {
-				title: '芳华选互联网医院',
+				title: '芳华选互联网医院',
 				query:'',//页面参数
 				imageUrl: 'https://hos-1309931967.cos.ap-chongqing.myqcloud.com/fs/20250721/efce6c594de34caba6537992083a5e47.png' //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
 			}

+ 2 - 2
pages_company/order/confirmCompanyOrder.vue

@@ -83,7 +83,7 @@
 		//发送给朋友
 		onShareAppMessage(res) {
 			return {
-				title: "芳华选-您的专属健康解决方案",
+				title: "芳华选-您的专属健康解决方案",
 				path: '/pages_company/order/confirmOrder?orderKey='+this.orderKey,
 				imageUrl: 'https://hos-1309931967.cos.ap-chongqing.myqcloud.com/fs/20250721/efce6c594de34caba6537992083a5e47.png' //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
 			}
@@ -92,7 +92,7 @@
 		//分享到朋友圈
 		onShareTimeline(res) {
 			return {
-				title:"芳华选-您的专属健康解决方案",
+				title:"芳华选-您的专属健康解决方案",
 				query:'orderKey='+this.orderKey,
 				imageUrl:  'https://hos-1309931967.cos.ap-chongqing.myqcloud.com/fs/20250721/efce6c594de34caba6537992083a5e47.png' //分享图标,路径可以是本地文件路径、代码包文件路径或者网络图片路径.支持PNG及JPG。显示图片长宽比是 5:4
 			}

+ 2 - 12
pages_company/storeProductPackageDetails.vue

@@ -63,8 +63,7 @@
 				 
 			</view>
 			<view class="btn-box">
-				<button :class="isSubmitting?'btnsel btn buy':'btn buy'" @click="buy" 
-				:disabled="isSubmitting">{{ isSubmitting ? '提交中...' : '立即购买' }}</button>
+				<button class="btn buy" @click="buy" >立即购买</button>
 			</view>
 		</view>
 		<view class="message-box" v-if="messageShow">
@@ -91,7 +90,6 @@
 				products:[],
 				// 当前轮播的图片
 				activeBanner: 1,
-				 isSubmitting: false // 控制按钮禁用状态
 			};
 		},
 		onLoad(options) {
@@ -208,20 +206,12 @@
 				this.activeBanner = event.detail.current + 1
 			},
 			buy() {
-				if (this.isSubmitting) return; // 防止重复点击
-				 this.isSubmitting = true; // 禁用按钮
-				 if(this.isSubmitting){
-				 	uni.showToast({
-				 		icon:'none',
-				 		title: '不能重复点击',
-				 	});
-				 }
+				
 				this.utils.isLogin().then(res => {
 					if(res){
 						uni.navigateTo({
 							url: '/pages_shopping/shopping/confirmPackageOrder?packageId='+this.packageId+"&companyUserId="+this.companyUserId
 						})
-						this.isSubmitting = false; // 禁用按钮
 					}
 				})
 				

+ 303 - 65
pages_course/components/liveVideo.vue

@@ -7,18 +7,19 @@
 				<live-player v-if="liveItem.livingUrl && liveItem.liveType == 1" :id="'myLivePlayer_' + liveId"
 					:src="liveItem.livingUrl" autoplay mode="live" object-fit="cover" :muted="false"
 					orientation="vertical" :enable-play-gesture="false" min-cache="1" max-cache="3"
-					@statechange="onLiveStateChange" @error="onLiveError" class="item"></live-player>
+					@statechange="onLiveStateChange" @error="onLiveError" class="item"
+					:flushed="false" :seek="0"></live-player>
 
 				<!-- 录播 -->
 				<video v-if="liveItem.videoUrl && liveItem.liveType == 2" :id="`myVideo_${liveId}`" :autoplay="true"
 					class="item" :src="liveItem.videoUrl" :controls="false"
-					:object-fit="liveItem.showType==2||isFullscreen?'contain':'fill'" :custom-cache="false"
+					:object-fit="liveItem.showType==2||isFullscreen?'contain':'fill'"
 					:enable-progress-gesture="false" vslide-gesture-in-fullscreen="false" :show-center-play-btn="false"
-					:http-cache="false" loop @error="videoError" @timeupdate="onVideoTimeUpdate"
+					loop @error="videoError" @timeupdate="onVideoTimeUpdate"
 					@loadedmetadata="onVideoMetaLoaded" @pause="onVideoPause" @play="onVideoPlay"
-					@waiting="onVideoWaiting" :enable-play-gesture="false" :play-strategy="1"
-					@dblclick="preventDoubleClick" preload="auto" :enable-stash-buffer="false" :stash-initial-size="0"
-					:stash-max-size="0" :stash-time="0" type="application/x-mpegURL"></video>
+					@waiting="onVideoWaiting" :enable-play-gesture="false"
+					@dblclick="preventDoubleClick" preload="metadata"
+					:initial-time="0" :show-play-btn="false" :show-fullscreen-btn="false" :show-playback-rate-btn="false"></video>
 				<view v-if="liveItem.videoUrl && liveItem.liveType == 2" class="time"
 					:class="isFullscreen ? 'look-time' : 'time'">{{ diffTotalTime }}</view>
 				<view class="custom-controls" @click.stop="toggleFullscreen">
@@ -44,24 +45,24 @@
 		<view class="videolist" v-if="liveItem.status == 4">
 			<view class="video" :class="liveItem.showType == 1 ? 'video_row' : ''">
 				<!-- 直播回放 -->
-				<video v-if="liveItem.videoUrl && liveItem.liveType == 3" :id="`myVideo_${liveId}`" class="item"
-					:src="liveItem.videoUrl" :autoplay="true" :controls="true" object-fit="cover" :custom-cache="false"
-					:enable-progress-gesture="liveItem.isSpeedAllowed" vslide-gesture-in-fullscreen="true"
-					:show-center-play-btn="true" :http-cache="false" loop @error="videoError"
-					@timeupdate="onVideoTimeUpdate" @loadedmetadata="onVideoMetaLoaded" @pause="onVideoPause"
-					@play="onVideoPlay" :enable-play-gesture="true" preload="auto" @waiting="onVideoWaiting"
-					type="application/x-mpegURL"></video>
+					<video v-if="liveItem.videoUrl && liveItem.liveType == 3" :id="`myVideo_${liveId}`" class="item"
+							:src="liveItem.videoUrl" :autoplay="true" :controls="true" object-fit="cover"
+							:enable-progress-gesture="liveItem.isSpeedAllowed" vslide-gesture-in-fullscreen="true"
+							:show-center-play-btn="true" loop @error="videoError"
+							@timeupdate="onVideoTimeUpdate" @loadedmetadata="onVideoMetaLoaded" @pause="onVideoPause"
+							@play="onVideoPlay" :enable-play-gesture="true" preload="metadata" @waiting="onVideoWaiting"
+							:initial-time="0"></video>
 				<view v-if="liveItem.videoUrl && liveItem.liveType == 3" class="lable">直播回放</view>
 			</view>
 
 		</view>
 		<view class="trailer-box" v-if="liveItem.status == 1">
 			<video v-if="liveItem.previewUrl" :id="`myVideo_${liveId}`" class="trailer-video" :src="liveItem.previewUrl"
-				:autoplay="true" loop object-fit="cover" :custom-cache="false" :enable-progress-gesture="false"
-				vslide-gesture-in-fullscreen="false" :show-center-play-btn="false" :http-cache="false"
-				@error="videoError" @loadedmetadata="onVideoMetaLoaded" @pause="onVideoPause" @play="onVideoPlay"
-				:disable-progress="true" :enable-play-gesture="true" @waiting="onVideoWaiting" preload="auto"
-				type="application/x-mpegURL" :controls="false"></video>
+					:autoplay="true" loop object-fit="cover"
+					vslide-gesture-in-fullscreen="false" :show-center-play-btn="false"
+					@error="videoError" @loadedmetadata="onVideoMetaLoaded" @pause="onVideoPause" @play="onVideoPlay"
+					:disable-progress="true" :enable-play-gesture="true" @waiting="onVideoWaiting" preload="metadata"
+					:controls="false" :initial-time="0" :show-play-btn="false" :show-fullscreen-btn="false"></video>
 			<image v-if="liveItem.status == 1 && !liveItem.previewUrl" class="trailer-placeholder"
 				src="https://bjzmky-1323137866.cos.ap-chongqing.myqcloud.com/userapp/images/no_live.png">
 			</image>
@@ -143,46 +144,54 @@
 			}
 		},
 		data() {
-			return {
-					videoLoaded: false, // 视频是否加载成功
-				isManualPause: false, // 是否手动暂停
-				waitingTimer: null, // 视频等待定时器
-				waitingStartTime: 0, // 视频等待开始时间
-				lastVideoUpdateTime: 0, // 视频最后更新时间
-				trafficStartTime: 0, // 流量计算开始时间
-				liveBeginWatchTime: 0, //开始观看的时间点 不包含预告
-
-				
-				// hasSubscribed: false, // 已成功订阅(永久禁用)
-				isFullscreen: false,
-				isVideoRotated: false,
-				showNonVideoElementsFlag: true,
-				showCustomControls: true,
-				videoContext: null,
-
-				// 流量计算相关
-				uuId: '',
-				totalTraffic: 0,
-				bitrate: 800,
-				bitrateLive: 1600,
-
-				// 定时器
-				trafficTimer: null,
-				liveStartTimer: null,
-				trafficInterval: null,
-				lookTimer: null,
-
-				// 状态数据
-				liveCountdown: {},
-				diffTotalTime: '',
-				videoCurrentTime: 0,
-				videoProgressKey: '',
-				startTime: 0,
-				stayTime: 0,
-				// 内部状态跟踪
-				hasInitialized: false,
-				lastLiveItemStatus: null
-			};
+				return {
+						videoLoaded: false, // 视频是否加载成功
+					isManualPause: false, // 是否手动暂停
+					waitingTimer: null, // 视频等待定时器
+					waitingStartTime: 0, // 视频等待开始时间
+					lastVideoUpdateTime: 0, // 视频最后更新时间
+					trafficStartTime: 0, // 流量计算开始时间
+					liveBeginWatchTime: 0, //开始观看的时间点 不包含预告
+
+					// 视频加载状态管理
+					videoLoading: false, // 视频是否正在加载
+					videoLoadError: false, // 视频加载是否出错
+					videoRetryCount: 0, // 视频加载重试次数
+					maxRetryCount: 3, // 最大重试次数
+					isHarmonyOS: false, // 是否为鸿蒙系统
+					localIsAgreement: false, // 本地存储的协议同意状态
+
+					
+					// hasSubscribed: false, // 已成功订阅(永久禁用)
+					isFullscreen: false,
+					isVideoRotated: false,
+					showNonVideoElementsFlag: true,
+					showCustomControls: true,
+					videoContext: null,
+
+					// 流量计算相关
+					uuId: '',
+					totalTraffic: 0,
+					bitrate: 800,
+					bitrateLive: 1600,
+
+					// 定时器
+					trafficTimer: null,
+					liveStartTimer: null,
+					trafficInterval: null,
+					lookTimer: null,
+
+					// 状态数据
+					liveCountdown: {},
+					diffTotalTime: '',
+					videoCurrentTime: 0,
+					videoProgressKey: '',
+					startTime: 0,
+					stayTime: 0,
+					// 内部状态跟踪
+					hasInitialized: false,
+					lastLiveItemStatus: null
+				};
 		},
 		watch: {
 			// 深度监听 liveItem 的所有变化
@@ -231,7 +240,14 @@
 			},
 		},
 		beforeUnmount() {
+			// 暂停所有视频播放
+			this.pauseVideo();
+			// 清理所有定时器
 			this.cleanup();
+			// 清理所有可能的引用
+			this.liveItem = null;
+			this.liveId = null;
+			this.userData = null;
 			// 强制退出全屏
 			this.isFullscreen = false;
 			this.showCustomControls = true;
@@ -417,21 +433,61 @@
 						const livePlayerContext = uni.createLivePlayerContext(livePlayerId, this);
 						// console.log("直播")
 						if (livePlayerContext) {
-							livePlayerContext.play();
+							if (this.isHarmonyOS) {
+								console.log('鸿蒙系统播放直播');
+								// 鸿蒙系统特殊处理:延迟播放并添加重试机制
+								setTimeout(() => {
+									try {
+										livePlayerContext.play();
+										console.log('鸿蒙系统直播播放命令已发送');
+										// 强制UI更新
+										this.$forceUpdate();
+										// 1秒后再次检查播放状态
+										setTimeout(() => {
+											console.log('鸿蒙系统直播播放状态检查');
+											// 再次强制UI更新
+											this.$forceUpdate();
+										}, 1000);
+									} catch (error) {
+										console.error('鸿蒙系统直播播放失败:', error);
+										// 播放失败时重试
+										setTimeout(() => {
+											livePlayerContext.play();
+											console.log('鸿蒙系统直播播放重试');
+										}, 1000);
+									}
+								}, 500);
+							} else {
+								livePlayerContext.play();
+							}
 						}
 					} else if (this.liveItem.status == 1 && this.liveItem.previewUrl) {
 						const videoId = `myVideo_${this.liveId}`;
 						const videoContext = uni.createVideoContext(videoId, this);
 
 						if (videoContext) {
-							videoContext.play();
+							if (this.isHarmonyOS) {
+								// 鸿蒙系统特殊处理:延迟播放
+								setTimeout(() => {
+									videoContext.play();
+								}, 500);
+							} else {
+								videoContext.play();
+							}
 						}
 					} else if (this.liveItem.liveType === 2 && this.liveItem.videoUrl && this.liveItem.status == 2) {
 						const videoId = `myVideo_${this.liveId}`;
 						const videoContext = uni.createVideoContext(videoId, this);
 						// console.log("录播")
 						if (videoContext) {
-							videoContext.play();
+							if (this.isHarmonyOS) {
+								// 鸿蒙系统特殊处理:延迟播放
+								setTimeout(() => {
+									videoContext.play();
+								}, 500);
+							} else {
+								videoContext.play();
+							}
 						}
 					} // 回放视频使用video
 					else if (this.liveItem.liveType === 3 && this.liveItem.videoUrl && this.liveItem.status == 4) {
@@ -439,11 +495,26 @@
 						const videoContext = uni.createVideoContext(videoId, this);
 						// console.log("回放")
 						if (videoContext) {
-							videoContext.play();
+							if (this.isHarmonyOS) {
+								// 鸿蒙系统特殊处理:延迟播放
+								setTimeout(() => {
+									videoContext.play();
+								}, 500);
+							} else {
+								videoContext.play();
+							}
 						}
 					}
 				} catch (error) {
 					console.error('播放视频失败:', error);
+					// 播放失败时尝试重试
+					if (this.videoRetryCount < this.maxRetryCount) {
+						this.videoRetryCount++;
+						console.log(`视频播放失败,${this.videoRetryCount}秒后重试`);
+						setTimeout(() => {
+							this.playVideo();
+						}, this.videoRetryCount * 1000);
+					}
 				}
 			},
 
@@ -480,6 +551,7 @@
 			// 视频错误处理
 			videoError(e, liveItem) {
 				if (!liveItem || !this.liveId) return;
+				console.error('视频错误:', e, liveItem);
 				// 初始化重试计数
 				if (this.videoRetryCounts[liveItem.liveId] === undefined) {
 					this.videoRetryCounts[liveItem.liveId] = 0;
@@ -498,13 +570,16 @@
 
 				this.videoRetryCounts[this.liveId]++;
 
+				// 鸿蒙系统特殊处理:更长的重试延迟
+				const retryDelay = this.isHarmonyOS ? 3000 : 2000;
+				
 				// 延迟重试
 				setTimeout(() => {
 					if (this.liveId === this.liveId) {
 						console.log(`第${this.videoRetryCounts[this.liveId]}次重试播放视频`);
 						this.playVideo();
 					}
-				}, 2000);
+				}, retryDelay);
 			}, // 视频暂停
 			onVideoPause(e) {
 				if (this.liveItem.liveType === 2) {
@@ -587,6 +662,25 @@
 				this.trafficTimer = setInterval(() => {
 					that.calculateTraffic(bitrate);
 				}, 10000); // 每10秒计算一次
+			},
+			// 清理所有定时器
+			clearAllTimers() {
+				if (this.trafficTimer) {
+					clearInterval(this.trafficTimer);
+					this.trafficTimer = null;
+				}
+				if (this.lookTimer) {
+					clearInterval(this.lookTimer);
+					this.lookTimer = null;
+				}
+				if (this.liveStartTimer) {
+					clearInterval(this.liveStartTimer);
+					this.liveStartTimer = null;
+				}
+				if (this.trafficInterval) {
+					clearInterval(this.trafficInterval);
+					this.trafficInterval = null;
+				}
 			}, // 计算码率
 			calculateBitrate() {
 				// 如果接口返回了视频文件大小和时长,使用这些数据计算码率
@@ -679,6 +773,31 @@
 						that.getInternetTraffic();
 					}, 10000);
 				}
+				
+				// 记录等待开始时间
+								if (!this.waitingStartTime) {
+									this.waitingStartTime = Date.now();
+								}
+				// 检测是否真的出现黑屏或卡顿(等待超过5秒且视频时间没有更新)
+								if (!this.waitingTimer) {
+									this.waitingTimer = setTimeout(() => {
+										const waitingDuration = Date.now() - this.waitingStartTime;
+										const timeSinceLastUpdate = Date.now() - this.lastVideoUpdateTime;
+				
+										// 只有在等待超过5秒,且视频时间超过3秒没有更新时,才认为是真正的卡顿/黑屏
+									if (waitingDuration >= 5000 && timeSinceLastUpdate >= 3000) {
+										uni.showToast({
+											title: '当前您的网络不稳定',
+											icon: 'loading',
+											duration: 2000
+										});
+										// 鸿蒙系统特殊处理:检测到黑屏时主动处理
+										if (this.isHarmonyOS) {
+											this.handleHarmonyOSBlackScreen();
+										}
+									}
+									}, 5000); // 延迟5秒检测
+								}
 			},
 			setVideoProgress() {
 				// 只有录播和回放需要设置进度
@@ -745,6 +864,18 @@
 			onVideoTimeUpdate(e) {
 				// 获取当前播放时间
 				this.videoCurrentTime = e.detail.currentTime;
+				// 更新视频最后更新时间(用于检测是否卡顿)
+								this.lastVideoUpdateTime = Date.now();
+				
+								// 如果视频在更新,说明没有卡顿,清除等待状态
+								if (this.waitingStartTime && this.lastVideoUpdateTime - this.waitingStartTime < 1000) {
+									// 视频在1秒内恢复了,清除等待定时器
+									if (this.waitingTimer) {
+										clearTimeout(this.waitingTimer);
+										this.waitingTimer = null;
+									}
+									this.waitingStartTime = 0;
+								}
 				// 每隔10秒保存一次进度(避免频繁存储)
 				if (Math.floor(this.videoCurrentTime) % 10 === 0) {
 					this.saveVideoProgress();
@@ -779,8 +910,11 @@
 					开始时间: this.liveItem?.startTime
 				});
 
+				// 检测系统类型
+				this.detectSystemType();
+
 				this.uuId = generateRandomString(16);
-				this.isAgreement = uni.getStorageSync('isAgreement');
+				this.localIsAgreement = uni.getStorageSync('isAgreement');
 
 				// 立即检查当前状态并启动相应功能
 				if (this.liveItem?.status === 1 && this.liveItem.startTime) {
@@ -794,6 +928,33 @@
 				this.startTimer();
 				this.hasInitialized = true;
 			},
+			// 检测系统类型
+				detectSystemType() {
+					try {
+						const systemInfo = uni.getSystemInfoSync();
+						console.log('系统信息:', systemInfo);
+						// 检测是否为鸿蒙系统
+						// 检查多个可能的字段
+						const isHarmony = (
+							systemInfo.platform === 'openharmony' ||
+							systemInfo.system?.toLowerCase().includes('harmony') ||
+							systemInfo.osName?.toLowerCase().includes('harmony') ||
+							systemInfo.platform?.toLowerCase().includes('harmony')
+						);
+						if (isHarmony) {
+							this.isHarmonyOS = true;
+							console.log('检测到鸿蒙系统');
+						} else {
+							console.log('非鸿蒙系统:', {
+								platform: systemInfo.platform,
+								system: systemInfo.system,
+								osName: systemInfo.osName
+							});
+						}
+					} catch (error) {
+						console.error('获取系统信息失败:', error);
+					}
+				},
 
 			// 启动直播倒计时 - 增强版本
 			startLiveCountdown() {
@@ -940,11 +1101,88 @@
 					clearInterval(this.lookTimer);
 					this.lookTimer = null;
 				}
+				// 清理等待定时器
+				if (this.waitingTimer) {
+					clearTimeout(this.waitingTimer);
+					this.waitingTimer = null;
+				}
 				if (this.liveItem && this.liveItem.timeTimer) {
 					clearInterval(this.liveItem.timeTimer);
 					this.liveItem.timeTimer = null;
 				}
-			}
+			},
+			// 重置视频状态 - 用于处理黑屏问题
+			resetVideoState() {
+				console.log('重置视频状态');
+				// 重置视频加载状态
+				this.videoLoaded = false;
+				this.videoLoading = false;
+				this.videoLoadError = false;
+				this.videoRetryCount = 0;
+				// 清理所有定时器
+				this.cleanup();
+				// 重新播放视频
+				if (this.liveItem) {
+					setTimeout(() => {
+						this.playVideo();
+					}, 500);
+				}
+			},
+			// 鸿蒙系统黑屏处理
+				handleHarmonyOSBlackScreen() {
+					if (!this.isHarmonyOS) return;
+					console.log('鸿蒙系统黑屏处理');
+					// 重置视频状态
+					this.resetVideoState();
+					// 显示加载提示
+					uni.showToast({
+						title: '视频加载中,请稍候...',
+						icon: 'loading',
+						duration: 3000
+					});
+				},
+				// 直播状态变化处理
+				onLiveStateChange(e) {
+					console.log('直播状态变化:', e);
+					// 获取直播状态
+					const state = e.detail.state;
+					console.log('直播状态:', state);
+					// 鸿蒙系统特殊处理
+					if (this.isHarmonyOS) {
+						console.log('鸿蒙系统直播状态变化:', state);
+						// 当状态为2(播放中)时,确保视频正常显示
+						if (state === 2) {
+							console.log('鸿蒙系统直播开始播放');
+							// 强制UI更新
+							this.$forceUpdate();
+						}
+						// 当状态为3(加载中)时,显示加载提示
+						else if (state === 3) {
+							console.log('鸿蒙系统直播加载中');
+							uni.showToast({
+								title: '直播加载中,请稍候...',
+								icon: 'loading',
+								duration: 2000
+							});
+						}
+					}
+				},
+				// 直播错误处理
+				onLiveError(e) {
+					console.error('直播错误:', e);
+					// 显示错误提示
+					uni.showToast({
+						title: '直播加载失败,请检查网络',
+						icon: 'none',
+						duration: 2000
+					});
+					// 鸿蒙系统特殊处理
+					if (this.isHarmonyOS) {
+						console.log('鸿蒙系统直播错误处理');
+						// 重置视频状态
+						this.resetVideoState();
+					}
+				},
 		}
 	};
 </script>

+ 1 - 1
pages_course/living-new.vue

@@ -400,7 +400,7 @@
 				isNetworkAvailable: true, // 网络是否可用
 
 				// templateId: 'fxYJu817lxHNKXl0hJypb-y-lLm8CNmGbcwpQmasCVg',//芳华惠选
-				templateId: 'bpc9DOFwugg7_cNDN260TRclIgmIjDOuvLxIbM-c0mg', //芳华
+				templateId: 'bpc9DOFwugg7_cNDN260TRclIgmIjDOuvLxIbM-c0mg', //芳华
 				isAgreement: false,
 
 				wsNewUrl: 'wss://api.fhhx.runtzh.com/ws/app/webSocket',

+ 94 - 91
pages_course/living.vue

@@ -14,7 +14,7 @@
 								<u-avatar :src="liveItem.liveImgUrl || '/static/images/avatar.png'"
 									:size="32"></u-avatar>
 								<view class="colorf ml10 mr6">
-									<view>{{ liveItem.liveName ? truncateString(liveItem.liveName, 8) : '未命名' }}</view>
+									<view>111{{ liveItem.liveName ? truncateString(liveItem.liveName, 8) : '未命名' }}</view>
 								</view>
 							</view>
 						</view>
@@ -34,8 +34,8 @@
 					</view>
 
 					<view class="end">
-						<view v-if="Array.isArray(filteredViewers)" class="align-center" @click="toggleViewerList"
-							style="margin-top: 88rpx">
+						<view v-if="Array.isArray(filteredViewers)" class="align-center"
+											style="margin-top: 88rpx">
 							<view v-for="(item, viewerIndex) in filteredViewers" :key="viewerIndex">
 								<image v-if="item.avatar" class="w52 h52 mr4" style="border-radius: 26rpx"
 									:src="item.avatar" />
@@ -223,10 +223,8 @@
 			<WinningPopup :show="winning" :prizeList="prizeAll" :liveId="liveId" @close="closeWin"
 				@fill-address="handleFillAddress" />
 
-			<!-- 观众列表弹窗 -->
-			<Viewer ref="viewer" :show="showViewerList" :viewers="liveViewers" :lookAudsCount="lookAudsCount"
-				:loading="viewLoading" :scrollHeight="scrollHeight" @close="closeViewerList" @open="openViewerList"
-				@loadMore="handleViewerLoadMore" />
+			
+				
 
 			<!-- 更多弹窗 -->
 			<u-popup :show="isMore" @close="closeMore" round="20rpx" bgColor="#f3f5f9" zIndex="10076">
@@ -329,8 +327,7 @@
 
 <script>
 	import ChatInput from '@/pages_course/components/chatInput.vue'
-	import Viewer from '@/pages_course/components/viewer.vue'
-	import LiveVideo from '@/pages_course/components/liveVideo.vue'
+import LiveVideo from '@/pages_course/components/liveVideo.vue'
 	import ShopPopup from '@/pages_course/components/shopPopup.vue'
 	import LotteryPopup from '@/pages_course/components/lotteryPopup.vue'
 	import WinningPopup from '@/pages_course/components/winningPopup.vue'
@@ -388,11 +385,13 @@
 			WinningPopup,
 			ShopPopup,
 			LiveVideo,
-			Viewer,
 			ChatInput
 		},
 		data() {
-			return {
+			return {fakeAvatar: Array.from({
+						length: 11
+					}, (_, i) =>
+					`https://bjzmky-1323137866.cos.ap-chongqing.myqcloud.com/userapp/images/avatar${i + 1}.jpg`),
 				hasSubscribed: false, // 已成功订阅(永久禁用)
 				integralNum: null, //礼物芳华币数量
 				isPreview: true, //是否预告
@@ -418,8 +417,7 @@
 				isFullscreen: null,
 				notice: [],
 				isShowNotice: false,
-				showViewerList: false,
-				giftList: [{
+			giftList: [{
 						img: '/static/images/gift1.png',
 						name: '人气票',
 						number: 1
@@ -517,7 +515,7 @@
 				isManualClose: false,
 				networkType: 'unknown',
 				isNetworkAvailable: true,
-				templateId: 'bpc9DOFwugg7_cNDN260TRclIgmIjDOuvLxIbM-c0mg',
+				templateId: 'oDN_EoYNNb5RKbhTAfVtXevSGRhoyoOQwR9JKqeKMbA',
 				isAgreement: false,
 				wsNewUrl: 'wss://api.fhhx.runtzh.com/ws/app/webSocket',
 				qrFrom: null,
@@ -565,17 +563,12 @@
 				lastClickTime: 0,
 				videoRetryCounts: Object.create(null),
 				clickDelay: 300,
-				liveUserTotal: 0,
-				viewPageSize: 10,
-				viewPageNum: 1,
-				viewLoading: false,
-				scrollHeight: 0,
-				showPurchasePrompt: false,
+			liveUserTotal: 0,
+			showPurchasePrompt: false,
 				prevOrderCount: 0,
 				videoUrl: null,
-				boxHeight: 300,
-				liveViewers: [],
-				products: [],
+			boxHeight: 300,
+			products: [],
 				loadingProducts: false,
 				orderUser: {},
 				userType: 0,
@@ -588,7 +581,7 @@
 				userlogo: false,
 				user: {},
 				userInfo: '',
-				urlOption: {},
+				urlOption: {}
 			}
 		},
 		async onLoad(options) {
@@ -775,7 +768,16 @@
 				this.stayTime = 0
 				this.startTime = 0
 			}
-
+// 清除等待定时器
+			if (this.$refs.liveVideo && this.$refs.liveVideo.waitingTimer) {
+				clearTimeout(this.$refs.liveVideo.waitingTimer);
+				this.$refs.liveVideo.waitingTimer = null;
+			}
+			// 同时清理自身的waitingTimer(如果存在)
+			if (this.waitingTimer) {
+				clearTimeout(this.waitingTimer);
+				this.waitingTimer = null;
+			}
 
 			if (this.trafficTimer) {
 				clearInterval(this.trafficTimer)
@@ -789,7 +791,7 @@
 			}
 
 
-			if (this.liveItem.completionPointsEnabled) {
+			if (this.liveItem.completionPointsEnabled && !this.hasReceived) {
 				setTimeout(() => {
 					this.startCountdown();
 				}, 500);
@@ -829,14 +831,22 @@
 				return this.formatCountdown(this.pointsRemainingTime)
 			},
 			formattedWatchCount() {
-				return this.formatNumber(this.liveUserTotal || 0)
+				return this.formatNumber(this.liveUserTotal*2+50 || 0)
 			},
 			formattedLikeCount() {
 				return this.formatNumber(this.liveViewData.like || 0)
 			},
 			filteredViewers() {
-				const safeLiveViewers = Array.isArray(this.liveTopViewersData) ? this.liveTopViewersData : []
-				return safeLiveViewers.slice(0, 3)
+				
+				// 从预设的头像数组中随机选择3个
+				const avatarArray = this.fakeAvatar;
+				const shuffled = [...avatarArray].sort(() => 0.5 - Math.random());
+				const selected = shuffled.slice(0, 3);
+				// 转换为包含avatar属性的对象数组
+				return selected.map((avatar, index) => ({
+					userId: `virtual_${index}`,
+					avatar: avatar
+				}));
 			},
 			isCurrentUserWon() {
 				if (!Array.isArray(this.prizeInfo) || !this.userData?.userId) {
@@ -872,19 +882,27 @@
 			// 保存观看时长
 			this.updateWatchDuration();
 			this.stopCountdown();
+			// 清理流量定时器
+			if (this.$refs.liveVideo && this.$refs.liveVideo.clearAllTimers) {
+				this.$refs.liveVideo.clearAllTimers()
+			}
 		},
 		onUnload() {
 			if (this.$refs.liveVideo && this.$refs.liveVideo.saveVideoProgress) {
 				this.$refs.liveVideo.saveVideoProgress()
 			}
-			if (this.liveItem) {
-				if (this.$refs.liveVideo && this.$refs.liveVideo.pauseVideo) {
-					this.$refs.liveVideo.pauseVideo()
-				}
-				if (this.liveItem.timeTimer) {
-					clearInterval(this.liveItem.timeTimer)
-					this.liveItem.timeTimer = null
-				}
+			// 暂停视频
+			if (this.$refs.liveVideo && this.$refs.liveVideo.pauseVideo) {
+				this.$refs.liveVideo.pauseVideo()
+			}
+			// 清理流量定时器
+			if (this.$refs.liveVideo && this.$refs.liveVideo.clearAllTimers) {
+				this.$refs.liveVideo.clearAllTimers()
+			}
+			// 清理liveItem中的定时器
+			if (this.liveItem && this.liveItem.timeTimer) {
+				clearInterval(this.liveItem.timeTimer)
+				this.liveItem.timeTimer = null
 			}
 			// 更新后端观看时长
 			this.updateWatchDuration();
@@ -995,9 +1013,14 @@
 										uni.setStorageSync('userInfo', JSON
 											.stringify(res
 												.user));
-										uni.setStorageSync('userData', JSON
-											.stringify(res
-												.user));
+												if(!res.user.createTime){
+													this.getUserInfo()
+												}else{
+													uni.setStorageSync('userData', JSON
+														.stringify(res
+															.user));
+												}
+										
 										this.userInfo = uni.getStorageSync(
 											'userInfo');
 											this.userData = uni.getStorageSync(
@@ -1278,6 +1301,10 @@
 				return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
 			},
 			startCountdown() {
+				// 如果已经领取过积分,不启动倒计时
+				if (this.hasReceived) {
+					return;
+				}
 				if (!this.liveItem || Array.isArray(this.liveItem) || !this.liveItem.completionPointsEnabled) {
 					return;
 				}
@@ -1304,6 +1331,11 @@
 				}, 1000); // 每秒更新一次
 			},
 			updateCountdown() {
+				// 如果已经领取过积分,停止倒计时
+				if (this.hasReceived) {
+					this.stopCountdown();
+					return;
+				}
 				if (!this.liveItem || Array.isArray(this.liveItem)) {
 					return;
 				}
@@ -1333,6 +1365,10 @@
 						return;
 					}
 				}
+				console.log('this.liveItem.duration', this.liveItem.duration);
+				console.log('this.completionRate', this.completionRate);
+
+
 				console.log('this.completionTime', this.completionTime);
 
 				// 倒计时已结束
@@ -1448,6 +1484,7 @@
 					return 0
 				}
 				if (this.hasReachedTarget || this.pointsRemainingTime <= 0) {
+				console.log("这个比例是多少100",this.pointsRemainingTime)
 					return 100
 				}
 				const completionTime = this.liveItem.duration * this.completionRate * 0.01;
@@ -1456,6 +1493,8 @@
 					return 0
 				}
 				const percentage = (watchedTime / completionTime) * 100
+				console.log("这个比例是多少计算",percentage)
+
 				return Math.min(100, Math.max(0, percentage))
 			},
 			updateCountdownDisplay() {
@@ -1753,16 +1792,16 @@
 				return this.liveItem.originalVideoUrl + separator + 't=' + Date.now()
 			},
 			clearBigData() {
-				if (this.talklist.length > 50) {
+				if (this.talklist && this.talklist.length > 50) {
 					this.talklist = this.talklist.slice(-50)
 				}
-				if (this.liveViewersData.length > 100) {
+				if (this.liveViewersData && this.liveViewersData.length > 100) {
 					this.liveViewersData = this.liveViewersData.slice(-100)
 				}
-				if (this.liveViewers.length > 100) {
+				if (this.liveViewers && this.liveViewers.length > 100) {
 					this.liveViewers = this.liveViewers.slice(-100)
 				}
-				if (this.products.length > 50) {
+				if (this.products && this.products.length > 50) {
 					this.products = this.products.slice(0, 50)
 				}
 				if (typeof gc === 'function') {
@@ -2128,6 +2167,7 @@
 				await getUserInfo().then((res) => {
 						if (res.code == 200) {
 							this.userData = res.user
+							uni.setStorageSync('userData', res.user)
 						} else {
 							uni.showToast({
 								icon: 'none',
@@ -2784,45 +2824,8 @@
 					const totalTime = this.calculateTimeDiff(item)
 				}, 1000);
 			},
-			toggleViewerList() { //加载直播间观众
-				const now = Date.now()
-				if (now - this.lastClickTime > this.clickDelay) {
-					this.showViewerList = !this.showViewerList
-					this.lastClickTime = now;
-				}
-			},
-			closeViewerList() {
-				this.showViewerList = false
-			},
-			openViewerList() {
-				// this.$nextTick(() => {
-				// 	this.calculateScrollHeight()
-				// })
-			},
-			calculateScrollHeight() {
-				// const query = uni.createSelectorQuery().in(this)
-				// query.select('.viewer-list-popup').boundingClientRect((data) => {
-				// 	if (data) {
-				// 		this.scrollHeight = data.height - 120
-				// 	}
-				// }).exec()
-			},
-			openViews() {
-				this.$nextTick(() => {
-					const query = uni.createSelectorQuery().in(this)
-					query.select('.view-box').boundingClientRect((data) => {
-						if (data) {
-							this.scrollHeight = data.height - 80
-						}
-					}).exec();
-				})
-			},
-			async handleViewerLoadMore(page) {
-				if (this.viewLoading) return;
-				this.viewPageNum = page.num;
-				// 调用getliveUser加载更多数据
-				await this.getliveUser(page.num > 1);
-			},
+			
+			
 			async getLiveMsg(liveItem) {
 				if (!liveItem || !this.liveId) {
 					console.error('getLiveMsg 错误:无效的 liveItem')
@@ -2992,9 +2995,10 @@
 							userId: item.userId || '',
 							nickName: item.nickName || '未命名'
 						}));
-						let virtualTotal = res.total * 2 + 50;
-						// 使用虚拟的观众总数
-						this.liveUserTotal = virtualTotal || 0;
+						// let virtualTotal = res.total * 2 + 50;
+						// // 使用虚拟的观众总数
+						// this.liveUserTotal = virtualTotal || 0;
+						this.liveUserTotal = res.total;
 						this.liveTopViewersData = [...array];
 
 					}
@@ -3085,9 +3089,7 @@
 						this.$set(this.liveItem, 'livingUrl', '')
 						this.$set(this.liveItem, 'videoUrl', '')
 					}
-					// if (this.liveItem.configJson) {
-					//    this.completionRate = JSON.parse(this.liveItem.configJson).completionRate * 0.01;
-					//  }
+					
 					this.$set(this.liveItem, 'autoplay', res.data.liveType !== 0)
 					this.$set(this.liveItem, 'showType', res.data.showType)
 					this.storeId = res.storeId
@@ -3103,7 +3105,6 @@
 
 					console.log("是否调用积分列表", this.liveItem.completionPointsEnabled)
 					if (this.liveItem.completionPointsEnabled) {
-						console.log("是否调用积分列表")
 						this.getRemainingTime()
 					}
 					// 初始化累计观看时间
@@ -3726,7 +3727,9 @@
 								msg: socketMessage.msg,
 								status: true
 							}
-						} else if (socketMessage.cmd == 'LotteryDetail') {
+						} else if (socketMessage.cmd == 'userCount') {
+							this.liveUserTotal = socketMessage.data
+						}else if (socketMessage.cmd == 'LotteryDetail') {
 							try {
 								this.prizeInfo = Array.isArray(JSON.parse(socketMessage.data || '[]')) ? JSON.parse(
 									socketMessage.data || '[]') : []

+ 1 - 1
pages_shopping/live/complaint.vue

@@ -4,7 +4,7 @@
 			<view class="color#{$5} ">投诉对象</view>
 			<view class="align-center mt30 mb50">
 				<image class="w100 h100 mr30" style="border-radius: 50%;" src="/static/images/logo.png"></image>
-				<text>芳华选</text>
+				<text>芳华选</text>
 			</view>
 		</view>
 		<view class="container" >

+ 15 - 2
pages_shopping/live/confirmCreateOrder.vue

@@ -432,7 +432,20 @@
 			async submitOrder() {
 			    try {
 			        // 检查本地缓存userData是否有电话号码
-			        const userData = uni.getStorageSync('userData');
+			        let userData = uni.getStorageSync('userData');
+					// 检查userData是否是字符串,如果是,解析为对象
+					if (typeof userData === 'string') {
+						try {
+							userData = JSON.parse(userData);
+						} catch (error) {
+							console.error('解析userData失败:', error);
+							userData = null;
+						}
+					}
+					console.log("跳转登录",userData)
+					console.log("跳转登录",userData?.phone)
+
+
 			        if (!userData || !userData.phone) {
 			            // 跳转到登录页面
 			            uni.showToast({
@@ -440,7 +453,7 @@
 			                icon: 'none'
 			            });
 			            uni.navigateTo({
-			                url: '/pages_user/login/login'
+			                url: '/pages/auth/login'
 			            });
 			            return;
 			        }

+ 49 - 7
pages_shopping/live/refundOrderDetail.vue

@@ -179,7 +179,12 @@
 						</view>
 					</view>
 				</view>
-
+<!-- 按钮 -->
+		<view class="btn-box">
+			<button class="btn cancel contact-btn" open-type="contact">
+				<text>售后客服</text>
+			</button>
+		</view>
 			</view>
 		</view>
 
@@ -187,6 +192,10 @@
 </template>
 
 <script>
+
+import {
+		getDicts
+	} from '@/api/index.js'
 	import {
 		getStoreAfterSalesById,
 		revoke
@@ -207,6 +216,7 @@
 		onLoad(option) {
 			console.log("option是", option)
 			this.id = option.id
+			this.getDicts()
 
 		},
 		onShow() {
@@ -232,7 +242,20 @@
 				return this.sales.createTime;
 			},
 		},
-		methods: { // 日期格式化方法
+		methods: { 
+			getDicts: function() {
+				getDicts().then(
+					res => {
+						if (res.code == 200) {
+							uni.setStorageSync('dicts', JSON.stringify(res));
+						}
+					},
+					rej => {}
+				);
+			},
+			
+			
+			// 日期格式化方法
 			formatDate(date) {
 				const year = date.getFullYear();
 				const month = String(date.getMonth() + 1).padStart(2, '0');
@@ -667,8 +690,14 @@
 	}
 
 	.btn-box {
-		margin-top: 15upx;
+		z-index: 999;
+		bottom: 0;
+		width: 100%;
+		position: fixed;
+		height: 120upx;
 		box-sizing: border-box;
+		background: #FFFFFF;
+		padding: 0 30upx;
 		display: flex;
 		align-items: center;
 		justify-content: flex-end;
@@ -684,15 +713,28 @@
 			border-radius: 32upx;
 			margin-left: 15upx;
 
-			&:first-child {
-				margin-left: 0;
-			}
-
 			&.cancel {
 				border: 1px solid #DDDDDD;
 				color: #666666;
 			}
 
+			&.pay {
+				background: #2BC7B9;
+				color: #FFFFFF;
+			}
+
+				&.contact-btn{
+				background: transparent;
+				border: 1px solid #DDDDDD;
+				color: #666666;
+				padding: 0;
+				margin: 0 15upx 0 0;
+				text-align: center;
+				line-height: 64upx;
+			}
+			&.contact-btn::after{
+				display: none;
+			}
 		}
 	}
 </style>

+ 13 - 16
pages_shopping/live/storeOrderDetail.vue

@@ -246,10 +246,9 @@
 		</view>
 		<!-- 按钮 -->
 		<view class="btn-box">
-			<view class="btn cancel">
+			<button class="btn cancel contact-btn" open-type="contact">
 				<text>售后客服</text>
-				<button class="contact-btn" open-type="contact"></button>
-			</view>
+			</button>
 			<view class="btn cancel" v-if="order.status==1" @click="cancel()">取消订单</view>
 			<view class="btn pay" v-if="order.status==1" @click="pay()">立即付款</view>
 			<!-- <view class="btn cancel"  v-if="(order.status==0||order.status==1)&&order.isPrescribe==1&&prescribe==null"  @click="addPrescribe()">开处方</view> -->
@@ -893,19 +892,17 @@
 				color: #FFFFFF;
 			}
 
-			// 客服button样式修复
-			.contact-btn {
-				position: absolute; // 绝对定位覆盖整个按钮区域
-				top: 0;
-				left: 0;
-				width: 100%;
-				height: 100%;
-				background: transparent; // 透明背景,不遮挡文字
-				border: none; // 去掉默认边框
-				padding: 0; // 去掉默认内边距
-				margin: 0; // 去掉默认外边距
-				opacity: 0; // 透明,只保留点击功能
-				z-index: 1; // 确保在文字上方,能接收到点击事件
+				&.contact-btn{
+				background: transparent;
+				border: 1px solid #DDDDDD;
+				color: #666666;
+				padding: 0;
+				margin: 0 15upx 0 0;
+				text-align: center;
+				line-height: 64upx;
+			}
+			&.contact-btn::after{
+				display: none;
 			}
 		}
 	}

+ 25 - 16
pages_shopping/shopping/confirmCreateOrder.vue

@@ -297,7 +297,16 @@
 			submitOrder() {
 				var that=this;
 				// 检查本地缓存userData是否有电话号码
-				const userData = uni.getStorageSync('userData');
+				let userData = uni.getStorageSync('userData');
+				// 检查userData是否是字符串,如果是,解析为对象
+				if (typeof userData === 'string') {
+					try {
+						userData = JSON.parse(userData);
+					} catch (error) {
+						console.error('解析userData失败:', error);
+						userData = null;
+					}
+				}
 				if (!userData || !userData.phone) {
 					// 跳转到登录页面
 					uni.showToast({
@@ -305,7 +314,7 @@
 						icon: 'none'
 					});
 					uni.navigateTo({
-						url: '/pages_user/login/login'
+					url: '/pages/auth/login'
 					});
 					return;
 				}
@@ -326,20 +335,20 @@
 				}
 				
 				uni.requestSubscribeMessage({
-					tmplIds: this.temps,
-					success(res) {
-						 that.createOrder();
-					},
-					fail(res) {
-						that.createOrder();
-					}
-				})
-				
-			},
-			createOrder(){
-				var that=this;
-				var data=null;
-				var tuiUserId=uni.getStorageSync('tuiUserId');
+				tmplIds: this.temps,
+				success(res) {
+					 that.createOrder();
+				},
+				fail(res) {
+					that.createOrder();
+				}
+			})
+			
+		},
+		createOrder(){
+			var that=this;
+			var data=null;
+			var tuiUserId=uni.getStorageSync('tuiUserId');
 				uni.showLoading({
 					title: '正在处理中...'
 				});

+ 1 - 2
pages_shopping/shopping/confirmPackageOrder.vue

@@ -90,7 +90,7 @@
 						<text class="num" v-if="totalMoney!=null">{{totalMoney.toFixed(2)}}</text>
 					</view>
 				</view>
-				<view :class="isSubmitting?'btnsel btn':'btn '" @click="submitOrder" :disabled="isSubmitting" > {{ isSubmitting ? '提交中...' : '提交订单' }}</view>
+				<view class="btn" @click="submitOrder">提交订单</view>
 			</view>
 		</view>
 		<popupBottom ref="popup" :visible.sync="couponVisible" title=" " bgColor="#f5f5f5"  radius="30"    maxHeight="60%">
@@ -160,7 +160,6 @@
 					mark:null,
 				},
 				postMoney:'',
-				isSubmitting: false // 控制按钮禁用状态
 			}
 		},
 		onLoad(option) {

+ 1 - 6
pages_shopping/shopping/productDetails.vue

@@ -488,13 +488,8 @@
 			},
 			// 确定选择该规格
 			submit() {
-				if (this.isSubmitting) return; // 防止重复点击
-				 this.isSubmitting = true; // 禁用按钮
 				 if(this.isSubmitting){
-				 	// uni.showToast({
-				 	// 	icon:'none',
-				 	// 	title: '不能重复点击',
-				 	// });
+				 
 				 }
 				this.specVisible = false
 				this.doAddCart(this.type);

+ 1 - 1
pages_user/user/pay.vue

@@ -4,7 +4,7 @@
       <view class="inner">
         <view class="pay">
           <view class="title">
-            <text class="name">付款给 芳华选</text>
+            <text class="name">付款给 芳华选</text>
             <text class="desc">微信收款</text>
           </view>
           <view class="pay-money">

+ 34 - 8
pages_user/user/refundOrderDetail.vue

@@ -173,7 +173,11 @@
 						</view>
 					</view>
 				</view>
-			
+				<view class="btn-box">
+			<button class="btn cancel contact-btn" open-type="contact">
+				<text>售后客服</text>
+			</button>
+		</view>
 			</view>
 		</view>
 		
@@ -580,13 +584,20 @@
 		}
 		
 	}
-	.btn-box{
-		margin-top: 15upx;
+	.btn-box {
+		z-index: 999;
+		bottom: 0;
+		width: 100%;
+		position: fixed;
+		height: 120upx;
 		box-sizing: border-box;
+		background: #FFFFFF;
+		padding: 0 30upx;
 		display: flex;
 		align-items: center;
 		justify-content: flex-end;
-		.btn{
+
+		.btn {
 			width: 155upx;
 			height: 64upx;
 			line-height: 64upx;
@@ -596,14 +607,29 @@
 			text-align: center;
 			border-radius: 32upx;
 			margin-left: 15upx;
-			&:first-child{
-				margin-left: 0;
+
+			&.cancel {
+				border: 1px solid #DDDDDD;
+				color: #666666;
+			}
+
+			&.pay {
+				background: #2BC7B9;
+				color: #FFFFFF;
 			}
-			&.cancel{
+
+				&.contact-btn{
+				background: transparent;
 				border: 1px solid #DDDDDD;
 				color: #666666;
+				padding: 0;
+				margin: 0 15upx 0 0;
+				text-align: center;
+				line-height: 64upx;
+			}
+			&.contact-btn::after{
+				display: none;
 			}
-			 
 		}
 	}
 	

+ 1 - 0
pages_user/user/storeOrder.vue

@@ -107,6 +107,7 @@
 </template>
 
 <script>
+	import{getDicts}from '@/api/index.js'
 	import {getMyStoreOrderList,cancelOrder} from '@/api/storeOrder'
 	import MescrollMixin from "@/uni_modules/mescroll-uni/components/mescroll-uni/mescroll-mixins.js";
 	export default {

+ 42 - 8
pages_user/user/storeOrderDetail.vue

@@ -138,10 +138,10 @@
 									</view>
 									<view class="spec ellipsis2">{{JSON.parse(order.packageJson).descs}}</view>
 								</view>
-								 
+								
 							</view>
 						</view>
-					 
+						
 						<!-- 已优惠、小计 -->
 						<view class="sub-total">
 							<view class="discount">
@@ -210,7 +210,7 @@
 							<text class="label">发货时间</text>
 							<text class="text"></text>
 						</view> -->
-						 
+						
 					</view>
 					<!-- 处方信息 -->
 					<view class="order-info" v-if="order.isPrescribe&&prescribe!=null">
@@ -238,9 +238,13 @@
 				</view>
 				
 			</view>
+			
 		</view>
 		<!-- 按钮 -->
 		<view   class="btn-box">
+			<button class="btn cancel contact-btn" open-type="contact">
+				<text>售后客服</text>
+			</button>
 			<!-- <view class="btn cancel">联系客服</view> -->
 			<view class="btn cancel" v-if="order.status==0" @click="cancel()">取消订单</view>
 			<view class="btn pay" v-if="order.status==0" @click="pay()">立即付款</view>
@@ -267,7 +271,7 @@
 				orderCode:'',
 				// 状态栏的高度
 				statusBarHeight: uni.getStorageSync('menuInfo').statusBarHeight,
-		 
+			
 			};
 		},
 		onLoad(option) {
@@ -287,7 +291,7 @@
 			},
 			addPrescribe(){
 				uni.navigateTo({
-				 	url:"/pages/shopping/prescribe?orderId="+this.order.id
+				  	url:"/pages/shopping/prescribe?orderId="+this.order.id
 				})
 			},
 			showImg(){
@@ -377,12 +381,12 @@
 			},
 			pay() {
 				 uni.navigateTo({
-				 	url: '/pages_shopping/shopping/paymentOrder?orderId='+this.order.id
+				  	url: '/pages_shopping/shopping/paymentOrder?orderId='+this.order.id
 				 })
 			},
 			payRemain() {
 				 uni.navigateTo({
-				 	url: '/pages_user/user/paymentOrderRemain?orderId='+this.order.id
+				  	url: '/pages_user/user/paymentOrderRemain?orderId='+this.order.id
 				 })
 			},
 			// 返回上一页
@@ -430,6 +434,24 @@
 		top: 0;
 		left: 0;
 		z-index: 1000;
+		.back-box{
+			height: 88upx;
+			padding-left: 22upx;
+			display: flex;
+			align-items: center;
+			justify-content: space-between;
+			padding: 0 20upx;
+			image{
+				width: 40upx;
+				height: 40upx;
+			}
+			.title{
+				font-size: 36upx;
+				font-family: PingFang SC;
+				font-weight: 500;
+				color: #FFFFFF;
+			}
+		}
 	}
 	.top-cont{
 		width: 100%;
@@ -791,6 +813,18 @@
 				background: #2BC7B9;
 				color: #FFFFFF;
 			}
+			&.contact-btn{
+				background: transparent;
+				border: 1px solid #DDDDDD;
+				color: #666666;
+				padding: 0;
+				margin: 0 15upx 0 0;
+				text-align: center;
+				line-height: 64upx;
+			}
+			&.contact-btn::after{
+				display: none;
+			}
 		}
 	}
-</style>
+</style>

+ 2 - 2
pages_user/user/userTuiAdd.vue

@@ -1,12 +1,12 @@
 <template>
   <view>
 		<view class="form-box">
-			<view class="title">你为什么想成为芳华选健康推广?</view>
+			<view class="title">你为什么想成为芳华选健康推广?</view>
 			<view class="textarea-box">
 				<textarea v-model="question1" value="" placeholder="请输入..." maxlength="200" placeholder-class="textarea-place" />
 				<view class="num-box">{{ question1.length }}/200</view>
 			</view>
-			<view class="title">你是否了解芳华选健康推广大使?</view>
+			<view class="title">你是否了解芳华选健康推广大使?</view>
 			<view class="textarea-box">
 				<textarea v-model="question2" value="" placeholder="请输入..." maxlength="200" placeholder-class="textarea-place" />
 				<view class="num-box">{{ question1.length }}/200</view>

二進制
static/images/logo.png


+ 1 - 1
store/index.js

@@ -15,7 +15,7 @@ const store = new Vuex.Store({
 	 uploadFile: 'https://userapp.cqsft.vip',
 	imgpath: 'https://beiliyo-2025.obs.cn-north-4.myhuaweicloud.com',//倍力优图片请求地址
 	logoname:'芳华臻选生活馆',
-	appid:'wx4d225cc86cc7885d',
+	appid:'wx776d6bd6848eec49',
   },
   getters: {
     coureLogin: (state) => state.coureLogin,