Przeglądaj źródła

Merge branch 'master' of http://1.14.104.71:10880/liujiaxin/zhibo

puyao 2 dni temu
rodzic
commit
5b5ad2e289

+ 10 - 1
pages.json

@@ -826,7 +826,16 @@
 						}
 					}
 				},
-
+{
+					"path": "live/complaintList",
+					"style": {
+						"navigationBarTitleText": "反馈与投诉",
+						"navigationBarTextStyle": "black",
+						"app-plus": {
+							"bounce": "none"
+						}
+					}
+				},
 				{
 					"path": "live/goods",
 					"style": {

+ 67 - 17
pages_course/living.vue

@@ -24,17 +24,17 @@
 								<text class="text-white text-xs">{{ getNicknameInitial(item.nickName) }}</text>
 							</view>
 						</view>
-						<view class="sum">{{ liveUserTotal || 0 }}</view>
+						<view class="sum">{{formattedWatchCount || 0 }}</view>
 					</view>
 				</view>
 
-				<!-- <view class="complaint-box" @click="navgetTo('/pages_shopping/live/complaint')">
-					<image class="image w32 h32 mr10"  src="/static/images/complaint.png" mode="widthFix" />
+				<view class="complaint-box" @click="navgetTo('/pages_shopping/live/complaintList')">
+					<image class="image w32 h32 mr10" src="/static/images/complaint.png" mode="widthFix" />
 					<view class="fs26">投诉</view>
-				</view> -->
+				</view>
 
 				<!-- 右边的side -->
-				<view class="side-group" :class="{ 
+				<view v-show="!isFocus" class="side-group" :class="{ 
 								'top2': (!isShowRed && !(isShowLottery && countdown)),
 								'top3': (isShowRed || (isShowLottery && countdown))
 							}">
@@ -55,7 +55,7 @@
 
 					<view class="side-item" @click="onLike">
 						<LikeButton :initialCount="100" :heartsPerClick="5" @like="onLike" />
-						<view style="font-size: 30rpx;">{{ (liveViewData && liveViewData.like) || 0 }}</view>
+						<view style="font-size: 30rpx;">{{ formattedLikeCount || 0 }}</view>
 					</view>
 					<view class="side-item">
 						<button open-type="share" class="button button-reset">
@@ -720,7 +720,7 @@
 						this.isOnload = true;
 						// 然后获取聊天记录
 						await this.getLiveMsg(this.liveId);
-						await this.getliveViewData(this.liveItem);
+						await this.getliveViewData();
 					}
 				}
 			} catch (error) {
@@ -764,12 +764,21 @@
 						this.keyboardHeight = 0;
 					}
 				} else {
+					console.log("手机型号是>>>>", 	)
+					console.log("手机型号是>>>>", this.systemInfo.model)
 					// Android处理保持原有逻辑
 					if (res.height > 0) {
 						this.isKeyboardShow = true;
 						const safeAreaBottom = this.systemInfo.safeAreaInsets ? this.systemInfo.safeAreaInsets
 							.bottom : 0;
-						this.keyboardHeight = (res.height * 1.78) + 20;
+						// this.keyboardHeight = (res.height * 2)-50;
+						// this.keyboardHeight = res.height * 2;
+						if (this.systemInfo.brand == 'vivo') {
+							this.keyboardHeight = res.height * 2;
+						} else {
+							this.keyboardHeight = (res.height * 1.78) + 20;
+						}
+						console.log("高度是", this.keyboardHeight)
 					} else {
 						this.isKeyboardShow = false;
 						this.keyboardHeight = 0;
@@ -792,7 +801,7 @@
 				await this.getLiveMsg(this.liveItem);
 			}
 			if (!this.liveViewData) {
-				this.getliveViewData(this.liveItem);
+				this.getliveViewData();
 			}
 			if (!this.userData) {
 				await this.getUserInfo();
@@ -831,7 +840,8 @@
 			}
 			// 恢复播放和连接
 			await this.resumePageActivity();
-			this.userinfo = JSON.parse(uni.getStorageSync('userInfo'));
+			// this.userinfo = JSON.parse(uni.getStorageSync('userInfo'));
+			this.userinfo = uni.getStorageSync('userInfo');
 			this.isAgreement = uni.getStorageSync('isAgreement');
 
 			this.$nextTick(() => {
@@ -868,8 +878,22 @@
 					console.error('分享失败', err);
 				}
 			};
+		},// 分享到朋友圈
+		onShareTimeline() {
+			return {
+				title: '邀请你来观看直播:' + this.liveItem.liveName,
+				query: 'companyId=-2&companyUserId=' + this.userData.userId + '&liveId=' + this.liveId
+			};
 		},
 		computed: {
+			// 观看人数
+			formattedWatchCount() {
+				return this.formatNumber(this.liveUserTotal || 0);
+			},
+			//点赞人数
+			formattedLikeCount() {
+				return this.formatNumber(this.liveViewData.like || 0);
+			},
 			filteredViewers() {
 				const safeLiveViewers = Array.isArray(this.liveViewersData) ? this.liveViewersData : [];
 				// 截取前3项
@@ -913,6 +937,9 @@
 			//  清除所有定时器(使用增强清理)
 			// this.clearAllTimersEnhanced();
 			// this.stopHeartBeat();
+			if (this.trafficTimer) {
+				clearInterval(this.trafficTimer);
+			}
 
 			// 页面隐藏时清理部分数据,减少内存占用
 			if (this.talklist && this.talklist.length > 20) {
@@ -1000,7 +1027,30 @@
 			}
 		},
 		methods: {
-
+			formatNumber(num) {
+				if (typeof num !== 'number') {
+					num = Number(num) || 0;
+				}
+				if (num < 10000) {
+					return num.toString();
+				}
+				// 处理万以上的数字
+				const wan = num / 10000;
+				if (wan < 10) {
+					// 1万-10万之间,保留2位小数
+					const rounded = Math.round(wan * 100) / 100;
+					return rounded.toFixed(2).replace(/\.?0+$/, '') + 'w';
+				} else if (wan < 10000) {
+					// 10万-1亿之间,保留1位小数
+					const rounded = Math.round(wan * 10) / 10;
+					return rounded.toFixed(1).replace(/\.0$/, '') + 'w';
+				} else {
+					// 1亿以上,转换为亿单位
+					const yi = wan / 10000;
+					const rounded = Math.round(yi * 100) / 100;
+					return rounded.toFixed(2).replace(/\.?0+$/, '') + '亿';
+				}
+			},
 			// 重置所有状态
 			resetAllStates() {
 				this.liveUserCalled = false;
@@ -2198,7 +2248,7 @@
 			},
 			// 录播时间点
 			onVideoMetaLoaded(e) {
-				console.log("录播时间点",e)
+				console.log("录播时间点", e)
 				this.videoProgressKey = `videoProgress_${this.liveId}`;
 				this.setVideoProgress();
 			},
@@ -2972,7 +3022,6 @@
 					this.$set(this.liveItem, 'autoplay', res.data.liveType !== 0);
 					this.$set(this.liveItem, 'showType', res.data.showType);
 					this.storeId = res.storeId;
-					//  启动“30秒刷新直播间数据”的定时器
 					this.startLiveViewDataTimer();
 					this.playVideo();
 				} catch (err) {
@@ -3025,8 +3074,8 @@
 			},
 
 			//直播间点赞、关注、在线人数数据
-			getliveViewData(liveItem) {
-				if (!liveItem || !this.liveId) return;
+			getliveViewData() {
+				if (!this.liveId) return;
 				getLiveViewData(this.liveId).then((res) => {
 					if (res.code == 200) {
 						// 强制响应式更新,确保数据实时显示
@@ -3048,10 +3097,11 @@
 					clearInterval(this.liveViewDataTimer);
 					this.liveViewDataTimer = null;
 				}
+				this.getliveViewData();
 				this.liveViewDataTimer = setInterval(() => {
 					// 安全校验:确保liveItem和liveId存在(避免无效请求)
-					if (this.liveItem && this.liveId) {
-						this.getliveViewData(this.liveItem);
+					if (this.liveId) {
+						this.getliveViewData();
 					}
 				}, 20000);
 			},

+ 246 - 235
pages_shopping/live/complaint.vue

@@ -1,27 +1,27 @@
 <template>
 	<view>
-		<view class="header-nav" :style="{height: `calc(88rpx + ${statusBarHeight}px)`,paddingTop: statusBarHeight + 'px'}">
-			<view class="arrow-left" :style="{top: statusBarHeight + 'px'}" @click="goBack">返回</view>
-			<view class="header-title" :style="{height:menuButtonH+'px',lineHeight:menuButtonH+'px'}">投诉反馈</view>
+		<view class="mt60 p34">
+			<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>
+			</view>
 		</view>
-		<view class="container" :style="{paddingTop: `calc(88rpx + ${statusBarHeight}px)`}">
-			<view class="formbox" v-if="isLastChild==1">
+		<view class="container" >
+			<view class="formbox">
 				<view class="formbox-title">{{ text }}</view>
 				<view class="form">
-					<u-form labelPosition="top" labelWidth='auto' :model="formdata" :rules="rules" ref="uForm" errorType="toast">
+					<u-form labelPosition="top" labelWidth='auto' :model="formdata" :rules="rules" ref="uForm"
+						errorType="toast">
 						<u-form-item label=" " prop="complaintContent">
-							<u--textarea v-model="formdata.complaintContent" border="none" :clearable="true" placeholder="请填写反馈内容" count maxlength='200'></u--textarea>
+							<u--textarea v-model="formdata.complaintContent" border="none" :clearable="true"
+								placeholder="请填写反馈内容" count maxlength='200'></u--textarea>
 						</u-form-item>
 						<view class="box">
 							<u-form-item label="图片(最多9张)">
 								<view class="imgitem">
-									<u-upload
-										:fileList="fileList1"
-										@afterRead="afterRead"
-										@delete="deletePic"
-										name="1"
-										:maxCount="9"
-									></u-upload>
+									<u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1"
+										:maxCount="9"></u-upload>
 								</view>
 							</u-form-item>
 						</view>
@@ -29,18 +29,6 @@
 				</view>
 				<view class="footer-btn">
 					<button class="submit-btn" @click="submit">提交</button>
-					<!-- <button class="submit-btn back-btn" @click="goBack">返回</button> -->
-				</view>
-			</view>
-			<view class="container" v-else>
-				<view class="list-item title">请选择反馈类型</view>
-				<view class="list-item" v-for="(item, index) in feedbackItems" :key="index"
-					@click="handleClick(item,index)">
-					<view>{{ item.complaintTypeName }}</view>
-					<uni-icons type="right" size="20" color="rgba(0,0,0,.3)" v-if="isLastChild==0"></uni-icons>
-				</view>
-				<view class="list-item" v-if="pageIndex!=0&&isLastChild==0" @click="goBack">
-					返回上一层
 				</view>
 			</view>
 		</view>
@@ -48,24 +36,29 @@
 </template>
 
 <script>
-	import { mapGetters } from 'vuex';
-	import{ getTypeTree, complaintRecord,loginByMp } from "@/api/course.js"
+	import {
+		mapGetters
+	} from 'vuex';
+	// complaintRecord
+	import {
+		getTypeTree,
+		loginByMp
+	} from "@/api/course.js"
 	export default {
 		data() {
 			return {
-				statusBarHeight: uni.getSystemInfoSync().statusBarHeight,
 				menuButtonH: 45,
 				pageIndex: 0,
 				list: [],
 				feedbackItems: [],
 				userId: '',
-				courseId: '',
-				videoId: '',
+				// courseId: '',
+				// videoId: '',
 				formdata: {
 					complaintContent: ""
 				},
 				rules: {
-					complaintContent:[{
+					complaintContent: [{
 						required: true,
 						message: '投诉反馈内容不能为空',
 						trigger: ["change", "blur"]
@@ -77,60 +70,60 @@
 				isLastChild: 0,
 				isLogin: false,
 				fileList1: [],
-				projectCode:'',
-				code:''
+				code: ''
 			};
 		},
-		computed: {
-			...mapGetters(['coureLogin']),
-		},
-		watch: {
-		    coureLogin: {
-		      immediate: true,          // 页面一进入就检查一次
-		      handler(val) {
-		        if (val == 2) {
-					console.log("AppToken失效,请重新登录")
-					this.isLogin = false
-					this.goLogin()
-		        }
-		      }
-		    }
-		},
+		// computed: {
+		// 	...mapGetters(['coureLogin']),
+		// },
+		// watch: {
+		// 	coureLogin: {
+		// 		immediate: true, // 页面一进入就检查一次
+		// 		handler(val) {
+		// 			if (val == 2) {
+		// 				console.log("AppToken失效,请重新登录")
+		// 				this.isLogin = false
+		// 				this.goLogin()
+		// 			}
+		// 		}
+		// 	}
+		// },
 		onLoad(option) {
-			this.userId = option.userId || ''
-			this.courseId = option.courseId || ''
-			this.videoId = option.videoId || ''
-			this.projectCode = option.projectCode || ''
-			uni.$on('usercode',(data)=>{
-				if(data) {
-					this.code=data.code
-					this.goLogin(data)
-				}
-			})
-			this.utils.getDomain({projectCode:this.projectCode}).then(res=>{
-				if(res.code == 200) {
-					uni.setStorageSync('addressUrl',res.addressUrl)
-					this.utils.isLoginCourseAuto().then(
-						res => {
-							if(res){
-								this.isLogin = true
-								this.getMenuButton()
-								this.getList()
-							} else{
-								this.isLogin = false
-								this.goLogin()
-							}
-						},
-						rej => {}
-					);
-				}
-			})
+			this.text=option.selectText
+			// this.userId = option.userId || ''
+			// this.courseId = option.courseId || ''
+			// this.videoId = option.videoId || ''
+			// this.projectCode = option.projectCode || ''
+			// uni.$on('usercode', (data) => {
+			// 	if (data) {
+			// 		this.code = data.code
+			// 		this.goLogin(data)
+			// 	}
+			// })
+			// this.utils.getDomain({projectCode:this.projectCode}).then(res=>{
+			// 	if(res.code == 200) {
+			// 		uni.setStorageSync('addressUrl',res.addressUrl)
+			// 		this.utils.isLoginCourseAuto().then(
+			// 			res => {
+			// 				if(res){
+			// 					this.isLogin = true
+			// 					this.getMenuButton()
+			// 					this.getList()
+			// 				} else{
+			// 					this.isLogin = false
+			// 					this.goLogin()
+			// 				}
+			// 			},
+			// 			rej => {}
+			// 		);
+			// 	}
+			// })
 		},
 		onUnload() {
 			uni.$off('usercode')
 		},
 		methods: {
-			getMenuButton(){
+			getMenuButton() {
 				const menuButtonInfo = uni.getMenuButtonBoundingClientRect()
 				this.menuButtonH = menuButtonInfo.height
 			},
@@ -155,111 +148,101 @@
 							this.templateId = list.complaintTypeId
 						}
 					}
-				
+
 				}
 			},
 			findGrandparentOrAllData(data, targetId) {
 				// 递归函数,用于查找目标节点的父级节点
 				function findParent(node, targetId) {
 					if (!node || !node.childrenType) return null;
-			
+
 					for (let child of node.childrenType) {
 						if (child.complaintTypeId === targetId) {
 							return node; // 找到目标节点的父级节点
 						}
-			
+
 						const result = findParent(child, targetId); // 递归查找子节点
 						if (result) return result;
 					}
-			
+
 					return null;
 				}
-			
+
 				// 遍历顶层节点,查找目标节点的父级和祖父级节点
 				for (let root of data) {
 					if (root.complaintTypeId === targetId) {
 						return data; // 如果目标节点是顶层节点,返回所有数据
 					}
-			
+
 					const parent = findParent(root, targetId); // 查找目标节点的父级节点
 					if (parent) {
 						const grandparent = findParent(root, parent.complaintTypeId); // 查找父级节点的父级节点
 						return grandparent || data; // 如果找到祖父节点返回祖父节点,否则返回所有数据
 					}
 				}
-			
+
 				return data; // 如果没有找到目标节点,返回所有数据
 			},
-			handleClick(item,index) {
-				if (this.isLastChild == 1) return
-				if (this.pageIndex >= 0) {
-					this.pageIndex++
-					let children = this.feedbackItems[index].childrenType || [];
-					this.templateId = this.feedbackItems[index].complaintTypeId
-					this.formdata = {
-						complaintContent: ""
-					}
-					this.text = this.feedbackItems[index].complaintTypeName
-					if (children.length > 0) {
-						this.isLastChild = 0
-						this.feedbackItems = children
-						this.templateId = this.feedbackItems[0].complaintTypeId
-					} else {
-						this.isLastChild = 1
-						this.formdata = {
-							complaintContent: ""
-						}
-						setTimeout(() => {
-							this.$refs.uForm.setRules(this.rules)
-						}, 200)
-					}
-				}
-			},
-			getList(){
-				getTypeTree().then(res=>{
-					if(res.code == 200) {
-						this.list = res.data
-						this.pageIndex = 0
-						this.feedbackItems = this.list
-					}
-				})
-			},
+			// handleClick(item, index) {
+			// 	if (this.isLastChild == 1) return
+			// 	if (this.pageIndex >= 0) {
+			// 		this.pageIndex++
+			// 		let children = this.feedbackItems[index].childrenType || [];
+			// 		this.templateId = this.feedbackItems[index].complaintTypeId
+			// 		this.formdata = {
+			// 			complaintContent: ""
+			// 		}
+			// 		this.text = this.feedbackItems[index].complaintTypeName
+			// 		if (children.length > 0) {
+			// 			this.isLastChild = 0
+			// 			this.feedbackItems = children
+			// 			this.templateId = this.feedbackItems[0].complaintTypeId
+			// 		} else {
+			// 			this.isLastChild = 1
+			// 			this.formdata = {
+			// 				complaintContent: ""
+			// 			}
+			// 			setTimeout(() => {
+			// 				this.$refs.uForm.setRules(this.rules)
+			// 			}, 200)
+			// 		}
+			// 	}
+			// },
+			// getList() {
+			// 	getTypeTree().then(res => {
+			// 		if (res.code == 200) {
+			// 			this.list = res.data
+			// 			this.pageIndex = 0
+			// 			this.feedbackItems = this.list
+			// 		}
+			// 	})
+			// },
 			submit() {
-				if(this.fileList1.some(item=>item.status == 'uploading')) {
+				if (this.fileList1.some(item => item.status == 'uploading')) {
 					uni.showToast({
 						title: '等待图片上传中',
 						icon: 'none'
 					})
 					return
 				}
-				var images=[];
+				var images = [];
 				this.fileList1.forEach(function(element) {
 					images.push(element.url)
 				});
 				this.$refs.uForm.validate().then(res => {
 					if (res) {
-						const param = {
-							userId: this.userId,
-							complaintTypeId: this.templateId,
-							complaintContent: this.formdata.complaintContent,
-							courseId: this.courseId,
-							videoId: this.videoId,
-							complaintUrl: images.toString()
-						}
-						complaintRecord(param).then(res=>{
-							uni.showModal({
-								title: '',
-								content: '我们已收到您的反馈,谢谢',
-								showCancel: false,
-								success: function (res) {
-									if (res.confirm) {
-										uni.navigateBack()
-									} else if (res.cancel) {
-										uni.navigateBack()
-									}
+						uni.showModal({
+							title: '',
+							content: '我们已收到您的反馈,谢谢',
+							showCancel: false,
+							success: function(res) {
+								if (res.confirm) {
+									uni.navigateBack()
+								} else if (res.cancel) {
+									uni.navigateBack()
 								}
-							});
-						})
+							}
+						});
 					}
 				})
 			},
@@ -292,7 +275,8 @@
 				const projectCode = uni.getStorageSync('projectCode')
 				return new Promise((resolve, reject) => {
 					let a = uni.uploadFile({
-						url: uni.getStorageSync('addressUrl_'+projectCode)+ '/app/common/uploadOSS', // 仅为示例,非真实的接口地址
+						url: uni.getStorageSync('addressUrl_' + projectCode) +
+						'/app/common/uploadOSS', // 仅为示例,非真实的接口地址
 						filePath: url,
 						name: 'file',
 						success: (res) => {
@@ -304,121 +288,142 @@
 					});
 				})
 			},
-			goLogin(data) {
-				if(!this.projectCode){
-					uni.showToast({
-						title: '链接有误',
-						icon: 'none'
-					});
-					return
-				} 
-				this.loginFsUserWx(data)
-				return
-				this.utils.getProvider().then(provider=>{
-					console.log('当前的环境商',provider)
-					if (!provider) {
-					  reject()
-					}
-					uni.login({
-						provider: provider,
-						success: async loginRes => {
-							console.log(loginRes)
-							uni.getUserInfo({
-							   provider: provider,
-							   success: (infoRes)=> {
-								    uni.showToast({
-										title: '处理中...',
-										icon: 'loading'
-								    });
-									loginByMp({code: loginRes.code,encryptedData:infoRes.encryptedData,iv:infoRes.iv,appId:getApp().globalData.appId}).then(res=>{
-										 uni.hideLoading();
-										 if (res.code == 200) {
-											 this.$store.commit('setCoureLogin', 1);
-											uni.setStorageSync(this.utils.TOKEN_KEYAuto, res.token);
-											uni.setStorageSync('auto_userInfo', JSON.stringify(res.user));
-											this.userId = res.user.userId || ''
-											this.isLogin = true
-											this.getMenuButton()
-											this.getList()
-										 } else {
-											uni.showToast({
-												title: res.msg,
-												icon: 'none'
-											});
-										 }
-									 }).catch(err=>{
-										uni.hideLoading();
-										uni.showToast({
-											icon:'none',
-											title: "登录失败,请重新登录",
-										});
-									});
-							   }
-							});
-						}
-					})
-				}).catch(err => {})
-			},
+			// goLogin(data) {
+			// 	if (!this.projectCode) {
+			// 		uni.showToast({
+			// 			title: '链接有误',
+			// 			icon: 'none'
+			// 		});
+			// 		return
+			// 	}
+			// 	this.loginFsUserWx(data)
+			// 	return
+			// 	this.utils.getProvider().then(provider => {
+			// 		console.log('当前的环境商', provider)
+			// 		if (!provider) {
+			// 			reject()
+			// 		}
+			// 		uni.login({
+			// 			provider: provider,
+			// 			success: async loginRes => {
+			// 				console.log(loginRes)
+			// 				uni.getUserInfo({
+			// 					provider: provider,
+			// 					success: (infoRes) => {
+			// 						uni.showToast({
+			// 							title: '处理中...',
+			// 							icon: 'loading'
+			// 						});
+			// 						loginByMp({
+			// 							code: loginRes.code,
+			// 							encryptedData: infoRes.encryptedData,
+			// 							iv: infoRes.iv,
+			// 							appId: getApp().globalData.appId
+			// 						}).then(res => {
+			// 							uni.hideLoading();
+			// 							if (res.code == 200) {
+			// 								this.$store.commit('setCoureLogin', 1);
+			// 								uni.setStorageSync(this.utils
+			// 									.TOKEN_KEYAuto, res.token);
+			// 								uni.setStorageSync('auto_userInfo',
+			// 									JSON.stringify(res.user));
+			// 								this.userId = res.user.userId || ''
+			// 								this.isLogin = true
+			// 								this.getMenuButton()
+			// 								this.getList()
+			// 							} else {
+			// 								uni.showToast({
+			// 									title: res.msg,
+			// 									icon: 'none'
+			// 								});
+			// 							}
+			// 						}).catch(err => {
+			// 							uni.hideLoading();
+			// 							uni.showToast({
+			// 								icon: 'none',
+			// 								title: "登录失败,请重新登录",
+			// 							});
+			// 						});
+			// 					}
+			// 				});
+			// 			}
+			// 		})
+			// 	}).catch(err => {})
+			// },
 			// H5授权绑定关系
-			async loginFsUserWx(data){
-				if(data){
-					let token = uni.getStorageSync('TOKEN_WEXIN');
-					let user = uni.getStorageSync('userInfo')
-					
-					uni.setStorageSync(this.utils.TOKEN_KEYAuto, token);
-					uni.setStorageSync('auto_userInfo', JSON.stringify(user));
-					this.userId = user.userId || ''
-					this.isLogin = true
-					this.getMenuButton()
-					this.getList()
-				}else{
-					uni.setStorageSync('H5course',{
-						companyId: this.urlOption.companyId,
-						companyUserId:this.urlOption.companyUserId,
-						type: 1, //1自动,其他手动
-					})
-					uni.showLoading({ title: '加载中' });
-										
-					try {
-					  await this.utils.getDomain({ projectCode: this.projectCode}); // code 换成你的业务标识
-					  await this.utils.getConfigKey();
-					  uni.navigateTo({
-					  	url:'/pages_course/webview?H5course='+uni.getStorageSync('H5course')
-					  })
-					} catch (err) {
-					  console.error('初始化失败', err);
-					  uni.showToast({ title: '请求失败', icon: 'none' });
-					} finally {
-					  uni.hideLoading();
-					}
-				}
-			}
+			// async loginFsUserWx(data) {
+			// 	if (data) {
+			// 		let token = uni.getStorageSync('TOKEN_WEXIN');
+			// 		let user = uni.getStorageSync('userInfo')
+
+			// 		uni.setStorageSync(this.utils.TOKEN_KEYAuto, token);
+			// 		uni.setStorageSync('auto_userInfo', JSON.stringify(user));
+			// 		this.userId = user.userId || ''
+			// 		this.isLogin = true
+			// 		this.getMenuButton()
+			// 		this.getList()
+			// 	} else {
+			// 		uni.setStorageSync('H5course', {
+			// 			companyId: this.urlOption.companyId,
+			// 			companyUserId: this.urlOption.companyUserId,
+			// 			type: 1, //1自动,其他手动
+			// 		})
+			// 		uni.showLoading({
+			// 			title: '加载中'
+			// 		});
+
+			// 		try {
+			// 			await this.utils.getDomain({
+			// 				projectCode: this.projectCode
+			// 			}); // code 换成你的业务标识
+			// 			await this.utils.getConfigKey();
+			// 			uni.navigateTo({
+			// 				url: '/pages_course/webview?H5course=' + uni.getStorageSync('H5course')
+			// 			})
+			// 		} catch (err) {
+			// 			console.error('初始化失败', err);
+			// 			uni.showToast({
+			// 				title: '请求失败',
+			// 				icon: 'none'
+			// 			});
+			// 		} finally {
+			// 			uni.hideLoading();
+			// 		}
+			// 	}
+			// }
 		}
 	};
 </script>
 
 <style scoped lang="scss">
+	
 	.container {
 		background-color: #fff;
 	}
+
 	.formbox-title {
 		padding-bottom: 30rpx;
 		border-bottom: 1px solid #f4f4f4;
 	}
+
 	.formbox {
 		border-top: 1px solid #f4f4f4;
 		padding: 30rpx;
 	}
+
 	.box {
 		padding-bottom: 24rpx;
 		border-top: 1px solid #f4f4f4;
+
 		.imgitem {
 			padding-top: 20rpx;
 		}
 	}
+
 	.footer-btn {
 		margin-top: 50rpx;
 	}
+
 	.submit-btn {
 		width: 50%;
 		height: 88rpx;
@@ -427,20 +432,23 @@
 		font-size: 30rpx;
 		font-family: PingFang SC;
 		color: #FFFFFF;
-		background: rgb(0,178,106);
+		background: rgb(0, 178, 106);
 		border-radius: 16rpx;
-		border: 1rpx solid ;
+		border: 1rpx solid;
 		margin-bottom: 30rpx;
+
 		&::after {
 			border: none;
 		}
 	}
+
 	.back-btn {
 		color: #bbb;
 		background: transparent;
 		border-radius: 16rpx;
 		border: 1rpx solid #999;
 	}
+
 	.header-nav {
 		height: 88rpx;
 		display: flex;
@@ -453,19 +461,21 @@
 		position: fixed;
 		top: 0;
 		left: 0;
+
 		.header-title {
 			flex: 1;
 			text-align: center;
 			overflow: hidden;
 			white-space: nowrap;
 			text-overflow: ellipsis;
-			font-family: PingFang SC,PingFang SC;
+			font-family: PingFang SC, PingFang SC;
 			font-weight: 500;
 			font-size: 15px;
 			color: #000;
 			box-sizing: border-box;
 		}
 	}
+
 	.arrow-left {
 		position: absolute;
 		left: 24rpx;
@@ -475,6 +485,7 @@
 		justify-content: center;
 		overflow: hidden;
 	}
+
 	.list-item {
 		background-color: #fff;
 		padding: 24rpx;
@@ -486,4 +497,4 @@
 	.title {
 		background-color: #f4f4f4;
 	}
-</style>
+</style>

+ 67 - 0
pages_shopping/live/complaintList.vue

@@ -0,0 +1,67 @@
+<template>
+	<view class="bg">
+		<view class="title">请选择投诉原因</view>
+		<view class="list">
+			<view class="item" @click="toComplaint(item)" v-for="(item,index) in list" :key="index">
+				<view>{{item}}</view>
+				<image class="w16" src="/static/images/arrow_gray.png" mode="widthFix"></image>
+			</view>
+
+		</view>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				list: ['广告诈骗', '反动政治', '侮辱谩骂', '直播侵权', '违法违规', '低俗恶俗', '暴力色情', '其他问题'],
+
+			};
+		},
+		methods: {
+
+
+			toComplaint(item) {
+				uni.navigateTo({
+					url: '/pages_shopping/live/complaint?selectText=' + item
+				})
+			}
+		}
+	};
+</script>
+
+<style scoped lang="scss">
+	.bg {
+		background-color: #ececec;
+		padding-top: 100rpx;
+		height: 100%;
+
+		.title {
+			text-align: center;
+			font-size: 40rpx;
+			font-weight: 500;
+		}
+
+		.list {
+			margin: 60rpx 20rpx 0;
+			border-radius: 16rpx;
+			padding: 24rpx;
+			background-color: #fff;
+
+			.item {
+				padding: 24rpx;
+				display: flex;
+				justify-content: space-between;
+				align-items: center;
+				border-bottom: #efefef 1rpx solid;
+
+				&:last-child {
+					border: none;
+				}
+
+			}
+
+		}
+	}
+</style>