<template>
	<view class="box">
	
		<!-- 自定义导航 -->
	<!-- 	<view class="zdyNavBox">
			<view class="status_bar" :style="{height: iStatusBarHeight + 'px'}"></view>
			<view class="zdyNav">
				<view class="zdyNavLeft">
					<image src="../../../static/img/nav_icon_back.png" mode="aspectFit" class="backImg" @click="goback"></image>
					<image src="../../../static/img/nav_icon_home.png" mode="" class="homeImg" @click="gohome"></image>
				</view>
				<view class="zdyNavTitle">订单详情</view>
				<view style="width: 100px;"></view>
			</view>
		</view>
		<view class="status_bar" :style="{height: iStatusBarHeight + 'px'}"></view>
		<view style="height: 44px;"></view> -->
		<homenav :iStatusBarHeight="iStatusBarHeight" :title="'订单详情'" :cj="4"></homenav>
		
		<view class="top" :style="{background:'#'+themeColor}">
			<view class="orderState">
				<image src="../../static/img/icon_order_def.png" mode="" style="width: 44rpx;height: 44rpx;"></image>


				<view class="SheetState" v-if="orderData.openShopHelpSheet.sheetState == 0">待确认</view>
				<view class="SheetState" v-if="orderData.openShopHelpSheet.sheetState == 1">已接单</view>
				<view class="SheetState" v-if="orderData.openShopHelpSheet.sheetState == 2">已出发</view>
				<view class="SheetState" v-if="orderData.openShopHelpSheet.sheetState == 3">已完成</view>
                <view class="SheetState" v-if="orderData.openShopHelpSheet.sheetState == 4">已取消</view>
				<view class="SheetState" v-if="orderData.openShopHelpSheet.sheetState == 5">已评价</view>
			</view>


		</view>
		<!-- 拼团信息 -->
		

		<!-- 店铺信息 -->
		<view class="shopBox" ><!-- :class="{shopBoxpt:orderData.data.sheetState == 5}" -->
			<image src="../../static/img/icon_store.png" mode="" class="shopBoximg"></image>
			<view class="shopCont">
				<view class="shopName">{{orderData.shopInfo.shopName}}</view>
				<view class="Address">
					{{orderData.shopInfo.provinceName}}{{orderData.shopInfo.cityName}}{{orderData.shopInfo.areaName}}{{orderData.shopInfo.address}}
				</view>

			</view>
			<view class="shopRightBox" @click="map">

				<image src="../../static/img/icon_ditu.png" mode="" class="shopRightImg"></image>

				<view class="shopRihgtTxt">地图</view>
			</view>
			<view class="shopsx"></view>
			<view class="shopRightBox" @click="call">

				<image src="../../static/img/icon_phone.png" mode="" class="shopRightImg"></image>

				<view class="shopRihgtTxt">电话</view>
			</view>
		</view>

		
		<!-- 救援信息 -->
		<view class="information">
			<view class="detailedTitle">救援信息</view>
			<view class="informationLine">
				<view class="informationTxt">救援单号:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.code}}<span class="codeCopy"
						@click="copy(orderData.openShopHelpSheet.code)">复制</span></view>
			</view>
			<view class="informationLine">
				<view class="informationTxt">救援时间:</view>
				<view class="informationNum" v-if="orderData.openShopHelpSheet.orderType==1">立刻</view>
				<view class="informationNum" v-else>{{orderData.openShopHelpSheet.hTime}}</view>
			</view>
			<view class="informationLine">
				<view class="informationTxt">救援类型:</view>
				<view class="informationNum2" v-if="orderData.openShopHelpSheet.helpType==1">搭电</view>
				<view class="informationNum2" v-if="orderData.openShopHelpSheet.helpType==2">拖车</view>
				<view class="informationNum2" v-if="orderData.openShopHelpSheet.helpType==3">换胎</view>
				<view class="informationNum2" v-if="orderData.openShopHelpSheet.helpType==4">未知原因</view>
				<view class="informationNum2">-</view>
				<view class="informationNum2" v-if="orderData.openShopHelpSheet.hscene==1">地面</view>
				<view class="informationNum2" v-if="orderData.openShopHelpSheet.hscene==2">车库</view>
				<view class="informationNum2" v-if="orderData.openShopHelpSheet.hscene==3">其他</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.plateNumber">
				<view class="informationTxt">车牌号:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.plateNumber}}</view>
			</view>
			<view class="informationLine">
				<view class="informationTxt">车型:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.carModel}}</view>
			</view>
			<view class="informationLine">
				<view class="informationTxt">救援联系人:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.customerName}}/{{orderData.openShopHelpSheet.mobilePhone}}</view>
			</view>
			
			<view class="informationLine" >
				<view class="informationTxt">起点:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.hStartAddress}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.helpType==2">
				<view class="informationTxt">终点:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.hEndAddress}}</view>
			</view>
			

		</view>

		<!-- 支付信息 -->
		<view class="information">
			<view class="detailedTitle">订单信息</view>
			
			<view class="informationLine">
				<view class="informationTxt">下单时间:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.createTime}}</view>
			</view>
			<view class="informationLine">
				<view class="informationTxt">下单人:</view>
				<view class="informationNum" >{{orderData.openUser.nickName|| '未知'}}/{{orderData.openUser.mobilePhone}}</view>
			</view>
			
			<view class="informationLine" v-if="orderData.openShopHelpSheet.confirmTime">
				<view class="informationTxt">确认时间:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.confirmTime}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.confirmOperator">
				<view class="informationTxt">确认人:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.confirmOperator}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.evaluateTime">
				<view class="informationTxt">评价时间:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.evaluateTime}}</view>
			</view>
				
			
			<view class="informationLine" v-if="orderData.openShopHelpSheet.goingOperator">
				<view class="informationTxt">出发人:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.goingOperator}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.finishTime">
				<view class="informationTxt">完成时间:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.finishTime}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.finishOperator">
				<view class="informationTxt">完成人:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.finishOperator}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.finishComment">
				<view class="informationTxt">完成备注:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.finishComment}}</view>
			</view>
		<view class="informationLine" v-if="orderData.openShopHelpSheet.evaluateComment">
			<view class="informationTxt">评价内容:</view>
			<view class="informationNum">{{orderData.openShopHelpSheet.evaluateComment}}</view>
		</view>
		<view class="informationLine" v-if="orderData.openShopHelpSheet.goingTime">
			<view class="informationTxt">出发时间:</view>
			<view class="informationNum" >{{orderData.openShopHelpSheet.goingTime}}</view>
		</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.cancelTime">
				<view class="informationTxt">取消时间:</view>
				<view class="informationNum">{{orderData.openShopHelpSheet.cancelTime}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.cancelOperator">
				<view class="informationTxt">取消人:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.cancelOperator}}</view>
			</view>
			<view class="informationLine" v-if="orderData.openShopHelpSheet.cancelComment">
				<view class="informationTxt">取消备注:</view>
				<view class="informationNum" >{{orderData.openShopHelpSheet.cancelComment}}</view>
			</view>

		</view>
		
		

		<view style="height: 50rpx;background-color: #F4F5F7;"></view>

		<view class="bottom"  v-if="orderData.openShopHelpSheet.sheetState != 5">
           <!-- <view class="cancel" @click="cancelBespeak" v-if="orderData.data.groupType==1">取消订单</view> -->
			<view class="cancel" v-if="orderData.openShopHelpSheet.sheetState == 0" @click="cancelBespeak" >取消订单</view>
		<!--  -->	<view class="defer" v-if="orderData.openShopHelpSheet.sheetState == 3||orderData.openShopHelpSheet.sheetState == 1||orderData.openShopHelpSheet.sheetState == 2"  :style="{border:'1rpx solid #'+themeColor,color:'#'+themeColor}" @click="orderevaluate">评价</view>
			<!-- <view class="defer"  v-if="orderData.openShopHelpSheet.sheetState == 5" :style="{border:'1rpx solid #'+themeColor,color:'#'+themeColor}" @click="seeevaluate">查看评价</view> -->
		</view>
		


<!-- 手机号授权 -->
	<view class="authorizBox" v-if="authorizShow" @click="authorizShow=false">
		<view class="authorizCont" @click.stop="">
			<view class="authorizName">{{wxOpenData.miniAppName}}</view>
			<view class="authorizMs">您好,欢迎访问本店,授权手机号登录能获取我们最新的促销活动哦~</view>
			<button class="authorizContbutton" type="default" open-type="getPhoneNumber" @getphonenumber="decryptPhoneNumber">授权</button>
		</view>
		<view style="text-align: center;padding-top: 56rpx;">
			<image src="../../../static/timg/icon_guanbi@2x.png" mode="" class="authorizCloseImg"></image>
		</view>
	</view>
	
	<view class="authorizBox" v-if="evaluateShow">
		<view class="evaluateBox">
			<view class="evaluateTitle">评价</view>
			<view class="textareaBox">
				<textarea placeholder-style="color:#999999" placeholder="说说哪里满意,帮大家选择~" v-model="evaluateComment"
					class="textareaCont" maxlength="-1" auto-height="true"  />
			</view>
			<view class="evaluateBtnBox">
				<view class="evaluatecancel cancel" @click="evaluatecancel">取消</view>
				<view class="evaluateDetermine defer" @click="evaluateDetermine">确定</view>
			</view>
		</view>
	</view>
	
	<view class="authorizBox" v-if="evaluateContShow">
		<view class="evaluateBox">
			<view class="evaluateTitle">查看评价</view>
			<view class="textareaBox">
				<view class="evaluateCont">
					{{orderData.openShopHelpSheet.evaluateComment}}
					<view class="evaluateTime">{{orderData.openShopHelpSheet.evaluateTime}}</view>
				</view>
				
			</view>
			<view class="evaluateBtnBox">
				<view class="evaluateDetermine defer" @click="evaluatexs">确定</view>
			</view>
		</view>
	</view>
	
  </view>
</template>

<script>
	import tkiQrcode from "@/components/tki-qrcode/tki-qrcode.vue"
	import homenav from "@/components/homenav/nav.vue"
	export default {
		components: {
			tkiQrcode,homenav
		},
		data() {
			return {

				id: '',
				iStatusBarHeight:'',
				
				orderData: '',

				onval: true, // val值变化时自动重新生成二维码
				loadMake: true, // 组件加载完成后自动生成二维码
				size: 500,
				qrcodeShow: false,
				qrcodeTop: '-100vh',
				qrcodeTopVal: '',
				ifShow: false,
				val: '二维码', // 要生成的二维码值
				unit: 'upx', // 单位
				background: '#b4e9e2', // 背景色
				foreground: '#309286', // 前景色
				pdground: '#262637', // 角标色
				icon: '', // 二维码图标
				iconsize: 40, // 二维码图标大小
				lv: 3, // 二维码容错级别 , 一般不用设置,默认就行
				src: '', // 二维码生成后的图片地址或base64
				isShowMa: false,
				quanMaList:[],
				 themeColor:'',
                authorizShow:false,
                userInfo:'',
                ext:'',
                wxOpenData:'',
				dh:'',
				dm:'',
				ds:'',
				seeTyshow:false,
				isShowTui:false,
				index:0,
				tuicauseList: [],
				tuikuanContent: '',
				swiperIndex:0,
				evaluateComment:'',
				evaluateShow:false,
				evaluateContShow:false,
			}
		},
		//0拼团取消1拼团失败 2拼团中3拼团成功4自动成团 groupState
		onLoad(opt) {
			 this.iStatusBarHeight = uni.getSystemInfoSync().statusBarHeight;
			this.id = opt.id
			this.themeColor = uni.getStorageSync("themeColor");
            this.userInfo=this.$store.state.userInfo;
            this.ext=this.$common.getExtStoreId();
            if(this.userInfo){
            	if (this.id) {
            		this.getData();
					this.getTuiKuanData()
            	}
            }else{
            	this.$common.automaticlogin().then(val => {
            		this.userInfo=this.$store.state.userInfo;
            		this.wxOpenData=this.$store.state.wxOpenData;
            		this.themeColor = uni.getStorageSync("themeColor");
            		if (this.id) {
            			this.getData();
						this.getTuiKuanData()
            		}
					if(!this.userInfo){
						this.authorizShow=true
					}
            	})
            }
			
			

		},
		

		methods: {
			orderevaluate(){
				this.evaluateShow=true;
			},
			seeevaluate(){
				this.evaluateContShow=true
			},
			evaluatexs(){
				this.evaluateContShow=false
			},
			evaluatecancel(){
				this.evaluateShow=false;
			},
			evaluateDetermine(){
				this.$http('openShopHelpSheetOrder/appraiseShop', {
					id:this.id,evaluateComment:this.evaluateComment,
				},'POST').then(res => {
					this.evaluateShow=false
					if(res.code==0){
						uni.showToast({
							title: '评价成功',
							icon: 'none',
							duration: 3000
						});
						this.getData();
						
					}else{
						uni.showToast({
							title: res.msg,
							icon: 'none',
							duration: 3000
						});
					}
				 })
			},
			isShowTuiHide(){
				this.isShowTui=false;
			},
			bindChange(e) {
				console.log(e);
				this.index = e.detail.value
			},
			getTuiKuanData() {
				console.log("退款原因")
				this.$http('openMallOrder/getOpenReason', {
			
					// id: this.id,
				}, 'GET').then(res => {
				
					this.tuicauseList = res.data;
			
				})
			},
			goTui(){
				var that=this;
				uni.showLoading({
					title: '加载中'
				})
				let yuanyin = this.tuicauseList[this.index].contents
				that.$http('openMallOrder/cancelOrder', {
				    realMoney:that.orderData.data.realMoney,
					sheetId: that.id,
					refundReason:yuanyin,
					refundComment:this.tuikuanContent,
				}, 'POST').then(res => {
					uni.hideLoading();
					// var list = res.data.Items
					this.isShowTui=false;
					uni.showToast({
						title: '取消成功',
						icon: 'none',
						duration: 2000
					});
					setTimeout(function() {
						that.getData();
					}, 1000);
				})
			},
			cancelOrder(){
				this.isShowTui=true;
			},
			seeTyHide(){
				this.seeTyshow=false;
			},
			seeTyshowBtn(){
				this.seeTyshow=true;
			},
			decryptPhoneNumber: function(e) {
			  console.log(e);
			  this.code=e.detail.code
			  this.wxPhoneLogin()
			  this.authorizShow=false;
			},
			wxPhoneLogin(){
					 var that=this;
					 this.$http('miniApp2/sys/wxPhoneLogin', {
					   appId:this.ext.appId,
					   unionId:this.ext.unionId,
					   code:this.code,
					   openId:this.wxOpenData.openid
					  },'POST').then(res => {
						var data = res.data;
						if(data.loginInfo){
							this.userInfo=data.loginInfo.openUser;
							this.wxOpenData=data.loginInfo;
							this.$store.commit('mutationswxOpenData', data)
							this.$store.commit('mutationsuserInfo', this.userInfo)
						    this.getData()
						}	
					  })
			},
			isShowMaSHow(index){
				this.swiperIndex=index
				 this.isShowMa=true
			},
			isShowMaHide(){
				this.isShowMa=false
			},
			goDetail(id) {
				console.log('id--',id);
				uni.navigateTo({
					
					url: '../../activity/jkDetail?id=' + id
				})
			},
			pay(){
				this.$http('openMallOrder/unifiedPay', {
					sheetId:this.id
				},'POST').then(res => {
					
					if(res.code==0){
						
						this.requestPayment(res.data)
					}else{
						uni.showToast({
							title: res.msg,
							icon: 'none',
							duration: 3000
						});
					}
				 })
			},
			requestPayment(res){
				var payInfo=res;
				//console.log(payInfo)
				//console.log(String(Date.now()))
				var that=this;
				uni.requestPayment({
					provider: 'wxpay',
					//timeStamp: String(Date.now()),
					timeStamp: payInfo.timeStamp,
					nonceStr: payInfo.nonceStr,
					package:payInfo.package,
					signType: payInfo.signType,
					paySign: payInfo.paySign,
					appid:payInfo.appId,	
				
				    success: function (res) {
				        console.log('success:' + JSON.stringify(res));
						 uni.showToast({
							 title: '支付成功',
							 icon:'none',
							 duration: 2000
						 });
						that.getData()
				    },
				    fail: function (err) {
					  console.log(err)
				      uni.showToast({
						 title: '支付失败',
						 icon:'none',
						 duration: 2000
				      });
					
				    }
				}); 
			},
			copy(txt) {
				uni.setClipboardData({
					data: txt,
					success: function() {
						uni.showToast({
							title: '复制成功',
							icon: 'none',
							duration: 2000
						});
					}
				});
			},
			upTime() {
				uni.showLoading({
					title: '加载中'
				})
				var that = this
				this.$http('openreservation/carOwner/updateTimeOfAppointment', {

					id: this.id,
					shopId: this.orderData.shopInfo.id,
					billDate: this.billDate
				}, 'POST').then(res => {
					uni.hideLoading();
					// var list = res.data.Items
					var list = res.data
					console.log("result+=", res.data);
					uni.showToast({
						title: '延期成功',
						icon: 'none',
						duration: 2000
					});
					setTimeout(function() {
						that.getData();
					}, 1000);


				})
			},
			
			cancelBespeak(){
				var that = this
				uni.showModal({
				    title: '提示',
				    content: '是否取消该订单',
					cancelText:'否',
					confirmText:'是',
				    success: function (res) {
				        if (res.confirm) {
							
								uni.showLoading({
									title: '加载中'
								})
								
								that.$http('openShopHelpSheetOrder/cancelOrder', {
							
									id: that.id,
							
								}, 'POST').then(res => {
									uni.hideLoading();
									// var list = res.data.Items
									
									uni.showToast({
										title: '取消成功',
										icon: 'none',
										duration: 2000
									});
									setTimeout(function() {
										that.getData();
									}, 1000);
								})
							
				          
				        } else if (res.cancel) {
				           
				        }
				    }
				});
			},
			
			map() {
				console.log("打开地图")
				var that = this;
				if (!that.orderData.shopInfo.lat || !that.orderData.shopInfo.lng) {
					uni.showToast({
						title: '该店铺未设置定位',
						icon: 'none',
						duration: 3000
					});
				} else {
					uni.openLocation({
						latitude: Number(that.orderData.shopInfo.lat),
						longitude: Number(that.orderData.shopInfo.lng),
						name: that.orderData.shopInfo.shopName,
						address: that.orderData.shopInfo.provinceName + that.orderData.shopInfo.cityName + that
							.orderData.shopInfo.areaName + that.orderData.shopInfo.address,
						success: function() {
							console.log('success');
						},
						fail(err) {
							console.log(err)
						}
					});
				}

			},

			call() {
				uni.makePhoneCall({
					phoneNumber: this.orderData.shopInfo.mobilePhone
				});
			},


			getData() {
				uni.showLoading({
					title: '加载中'
				});

				this.$http('openShopHelpSheetOrder/getOpenShopHelpSheetOrderInfo', {

					id: this.id,
				}, 'GET').then(res => {
					uni.hideLoading();
					this.orderData = res.data;
					if (this.quanMaList) {
						this.quanMaList = [];
					}
					let maList = this.orderData.OpenSheetQRCode;
					if (maList) {
						maList.forEach(item =>{
							if (item.writeoffState==1) {
								this.quanMaList.push(item.qrCode);
							}
						})
					}
					//this.clock()
					console.log('可用券码--',this.quanMaList);
					
				})
			},
			getData2() {
				uni.showLoading({
					title: '加载中'
				});
				this.$http('openOrderManagement/queryOpenSheet', {
			
					id: this.id,
				}, 'GET').then(res => {
					uni.hideLoading();
					this.orderData = res.data;
					if (this.quanMaList) {
						this.quanMaList = [];
					}
					let maList = this.orderData.OpenSheetQRCode;
					if (maList) {
						maList.forEach(item =>{
							if (item.writeoffState==1) {
								this.quanMaList.push(item.qrCode);
							}
						})
					}
					
					
				})
			},
			clock(){
			  
			  let _this = this
			  let today = new Date() // 当前时间
			  let h = today.getHours()
			  let m = today.getMinutes()
			  let s = today.getSeconds()
			  let startTime = new Date(_this.orderData.openGroup.endTime.replace(/-/g, '/')) // 结束时间
			  if (Number(new Date(_this.orderData.openGroup.endTime).getTime()) < Number(new Date().getTime())) {
			    //this.activityNoOpen = true
				this.dh=0;
				this.dm=0;
				this.ds=0;
				_this.getData2();
			    return false
			  }
			
			  let stopH = startTime.getHours()
			  let stopM = startTime.getMinutes()
			  let stopS = startTime.getSeconds()
			  let shenyu = startTime.getTime() - today.getTime() // 倒计时毫秒数
			  //console.log(shenyu)
			  let shengyuD = parseInt(shenyu / (60 * 60 * 24 * 1000)) // 转换为天
			 // let D = parseInt(shenyu) - parseInt(shengyuD * 60 * 60 * 24 * 1000)// 除去天的毫秒数
			  let D = parseInt(shenyu)
			  let shengyuH = parseInt(D / (60 * 60 * 1000)) // 除去天的毫秒数转换成小时
			  let H = D - shengyuH * 60 * 60 * 1000 // 除去天、小时的毫秒数
			  let shengyuM = parseInt(H / (60 * 1000)) // 除去天的毫秒数转换成分钟
			  let M = H - shengyuM * 60 * 1000// 除去天、小时、分的毫秒数
			  let S = parseInt((shenyu - shengyuD * 60 * 60 * 24 * 1000 - shengyuH * 60 * 60 * 1000 - shengyuM * 60 * 1000) / 1000)// 除去天、小时、分的毫秒数转化为秒
			 //console.log(S)
			 // this.daojishi = '报名倒计时:' + shengyuD + '天' + shengyuH + '小时' + shengyuM + '分' + S + '秒'
			  // setTimeout("clock()",500);
			  this.dh=shengyuH;
			  this.dm=shengyuM;
			  this.ds=S;
			  if(this.dh<10){
				  this.dh='0'+this.dh
			  }
			  if(this.dm<10){
			  	 this.dm='0'+this.dm
			  }
			  if(this.ds<10){
			  	 this.ds='0'+this.ds
			  }
			 
			  setTimeout(_this.clock, 1000)
			},
			goback() {
				uni.navigateBack({
				 	delta: 1
				})
			},
			gohome(){
				uni.switchTab({
					url:'../../index/index'
				})
			},

		},
		onPullDownRefresh() {
			this.getData()
			setTimeout(function() {
				uni.stopPullDownRefresh();
			}, 1000);
		},
		onShareAppMessage(res) {
			console.log(this.userInfo)
			var img='';
			/* if(this.info.ImgList.length>0){
				img=this.info.ImgList[0].url
			} */
			return {
				title: this.orderData.data.sheetContent,
				//imageUrl:this.mainImg,
				imageUrl:'http://dmsphoto.66km.com.cn/thFiles/83074F71-F5C9-4C8E-B23F-2D195788960B.png',
				path: 'pages/subPack/jkDetail?id=' + this.orderData.openSheetDetail[0].itemId+'&shareId='+this.userInfo.openId+'&groupID='+this.orderData.data.groupID+'&shareName='+this.userInfo.nickName,
				success(res){
					uni.showToast({
						title:'分享成功'
					})
				},
				fail(res){
					uni.showToast({
						title:'分享失败',
						icon:'none',
						duration: 3000
					})
				}
			}
		},

	}
</script>

<style scoped>
.evaluateBox{
	width: 600rpx;
	height: 600rpx;
	margin-top: 30vh;
	margin-left: 75rpx;
	background: #ffffff;
	border-radius: 16rpx;
}
.evaluateCont{
	font-size: 30rpx;color: #333333;height: 300rpx;
}
.evaluateTime{
	font-size: 30rpx;color: #999999;padding-top: 24rpx;
}
.textareaBox{
	padding: 24rpx;
}
.evaluateTitle{
	color: #333333;
	line-height: 42rpx;
	font-size: 30rpx;
	padding-left: 24px;
	padding-top: 30rpx;
}
.evaluateBtnBox{
	display: flex;justify-content: space-around;padding-top: 30rpx;
}
.textareaCont {
		padding: 20rpx;
		min-height: 300rpx;
		width:512rpx ;
		border-radius: 10rpx;
		font-size: 28rpx;
		background: #eaeaea;
}
.groupStateIcon{
	width: 28rpx;height: 28rpx;
}
.groupStateTxt{
	font-weight: 400;padding-left: 8rpx;
	color: #3C3C3C;line-height: 28rpx;
	font-size: 26rpx;
}
.groupStateBox{
	display: flex;
}
.detailedTitle{
	display: flex;justify-content: space-between;
}
.grouptk{
	width: 638rpx;
	height: 750rpx;
	background: #FFFFFF;
	border-radius: 24rpx;
	margin-top: 300rpx;
	margin-left: 56rpx;
}
.grouptkLIneLeft{
	display: flex;
}
.groupTz{
	border-radius: 15rpx;padding: 0 10rpx;margin-right: 8rpx;
	border: 1rpx solid #FF9D00;color: #FF9D00;font-size: 22rpx;
}
.groupTy{
	border-radius: 15rpx;padding: 0 10rpx;margin-right: 8rpx;
	border: 1rpx solid #764D49;color: #764D49;font-size: 22rpx;
}
.grouptkLIne{
	display: flex;padding: 15rpx 24rpx;
	justify-content: space-between;font-weight: 400;
color: #3C3C3C;font-size: 26rpx;line-height: 32rpx;
}
.grouptk .maTitle{
	 padding-left: 4rpx; 
	 color: #333333;font-weight: 500;
}
.ptCont{
	width: 702rpx;
	height: 297rpx;
	background: linear-gradient(180deg, #FFFFFF 0%, #FFFFFF 100%);
	border-radius: 10rpx;
	margin-left: 24rpx;
	margin-top: -60rpx;
}
.ptTimeBox{
	display: flex;font-weight: 400;justify-content: center;padding-top: 24rpx;
}
.ptTimeTxt{
	font-weight: 400;font-size: 24rpx;line-height: 42rpx;
	color: #764D49;padding-right: 18rpx;
}
.ptdd{
	font-size: 24rpx;padding:0 8rpx;
	line-height: 42rpx;
	font-weight: 400;
	color: #764D49;
}
.ptTime{
	width: 42rpx;font-size: 24rpx;
	height: 42rpx;text-align: center;line-height: 42rpx;
	background: #FF0000;
	border-radius: 6rpx;
	font-weight: 500;
	color: #FFFFFF;
}
.DiffBNumber{
	color: #764D49;font-size: 24rpx;text-align: center;padding-top:16rpx;padding-bottom: 30rpx;
}
.ptmobilePhoneLine{
	display: flex;font-weight: 400;justify-content: center;
color: #764D49;font-size: 26rpx;padding-top:20rpx;
}
.vipIcon{
	width: 32rpx;height: 32rpx;margin-right: 8rpx;
}
.seeTy{
	width: 260rpx;line-height: 62rpx;text-align: center;
	height: 62rpx;color: #FF0000;
	border-radius: 36rpx;font-size: 26rpx;
	border: 2rpx solid #FF0000;
	margin-right: 15rpx;
}
.ptBtnBox{
	display: flex;
	justify-content: center;
}
.yqhypt{
	width: 260rpx;color: #FFFFFF;line-height: 66rpx;text-align: center;
	height: 66rpx;font-size: 26rpx;
	background: linear-gradient(132deg, #FD5C05 0%, #FD0323 100%);
	border-radius: 36rpx;
	margin-left: 15rpx;
}
	.box {
		min-height: 100vh;
		background: #F4F5F7;
		padding-bottom: 135rpx;
	}
	.zdyNavBox{
		width: 100vw;
		background: #FFFFFF;
		position: fixed;
		top: 0;
		left: 0;
		z-index: 9999999;
	}
	.zdyNav{
		height: 44px;
		display: flex;
		justify-content: space-between;
		
		align-items: center;
	}
	
	.backImg{
		width: 44rpx;
		height: 44rpx;
		margin-left: 10rpx;
		margin-right: 20rpx;
	}
	.homeImg{
		width: 44rpx;
		height: 44rpx;
		
	}
	.zdyNavLeft{
		display: flex;
		align-items: center;
	}
	.zdyNavTitle{
		width: 100vw;
		height: 44px;
		background: #FFFFFF;
		text-align: center;
		font-size: 34rpx;
		line-height: 44px;
	}
	

	.top {
		height: 190rpx;
		background: #FF0000;

	}

	.orderState {
		display: flex;
		justify-content: center;
		align-items: center;
		padding-top: 40rpx;
	}

	.SheetState {
		display: flex;
		justify-content: center;
		font-size: 36rpx;
		font-weight: 500;
		color: #FFFFFF;
		margin-left: 15rpx;

	}



	.timeEditImg {
		width: 25rpx;
		height: 25rpx;
		padding-left: 20rpx;
	}



	.shopBoximg {
		width: 40rpx;
		height: 40rpx;
	}

	.shopRightImg {
		width: 44rpx;
		height: 45rpx;
	}

	.shopsx {
		width: 1px;
		height: 50rpx;
		background: #EEEEEE;
		margin-top: 30rpx;
		margin-left: 28rpx;
	}

	.shopBox {

		display: flex;
		padding: 30rpx 20rpx;
		margin: 0rpx 24rpx;
		margin-top: -60rpx;
		background-color: #FFFFFF;
		border-radius: 10rpx;

	}

	.shopCont {
		width: 405rpx;
		padding-left: 20rpx;

	}

	.shopName {
		font-size: 30rpx;
		font-weight: bold;
		color: #3C3C3C;
		line-height: 42rpx;
	}

	.Address {
		color: #999999;
		font-size: 24rpx;
		margin-top: 10rpx;
	}

	.shopRihgtTxt {
		color: #999999;
		font-size: 24rpx;

	}

	.shopRightBox {

		padding-left: 28rpx;
	}





	.detailedTitle {
		padding: 23rpx 20rpx;
		display: flex;
		text-align: center;
		align-content: flex-start;
		border-bottom: 1rpx solid #EEEEEE;

		font-size: 30rpx;
		font-weight: bold;
		color: #3C3C3C;
	}


	.detailedLine {
		display: flex;
		padding: 16rpx 20rpx;
		justify-content: space-between;
		align-items: center;
	}

	.detailedImg {
		width: 120rpx;
		height: 120rpx;
		border-radius: 10rpx;
	}



	.detailedName {
		display: flex;
		align-items: center;


	}

	.code {
		font-size: 26rpx;
		color: #333333;
		font-weight: bold;
		width: 180rpx
	}

	.old {
		color: #999999;

		font-weight: 400;
		text-decoration: line-through;
	}

	.redPoint {
		width: 10rpx;
		height: 10rpx;
		background: #FF0000;
		border-radius: 10rpx;
		margin-right: 10rpx;
	}

	.quanState {
		font-size: 22rpx;
		color: #F19D01;
		padding: 0 10rpx;

		border: 1rpx solid #F19D01;

		border-radius: 4rpx;
		margin-left: 20rpx;
	}
	.quanState2{
		font-size: 22rpx;
		color: #999999;
		padding: 0 10rpx;
		
		border: 1rpx solid #DDDDDD;
		
		border-radius: 4rpx;
		margin-left: 20rpx;
	}



	.information {

		background: #FFFFFF;
		border-radius: 10rpx;

		margin: 20rpx 24rpx;
		padding-bottom: 15rpx;
	}

	.informationLine {
		display: flex;

		padding: 15rpx 20rpx;
	}

	.informationLine2 {
		display: flex;
		justify-content: space-between;
		font-size: 26rpx;
		padding: 20rpx;
		align-items: center;
		padding-bottom: 0;
	}

	.salePrice {
		    padding-left: 20rpx;
		    padding-top: 15rpx;
		font-size: 26rpx;
		font-weight: 500;
		color: #333333;
		line-height: 45rpx;
	}

	.money {
		background: #FFFFFF;
		border-radius: 10rpx;

		margin: 20rpx 24rpx;

		display: flex;
		justify-content: space-between;
		font-size: 26rpx;
		padding: 30rpx 20rpx;
	}

	.informationTxt {
		width: 190rpx;
		font-size: 26rpx;
		color: #999999;
	}

	.line {
		height: 20rpx;
		background-color: #FFFFFF;
		border-bottom: 1rpx solid #EEEEEE;
	}

	.goodsName {
		width: 70%;
		color: #333333;
		font-size: 26rpx;
		
	}
	.huodong{
		display: flex;
		align-items: center;
	}
	.goodsName3{
		color: #333333;
		font-size: 26rpx;
		
	}
	.goodsName2{
		padding: 20rpx 20rpx 15rpx;
		
		color: #333333;
		font-size: 26rpx;
	}

	.informationNum {
		color: #333333;
		font-size: 26rpx;
		width: 500rpx;
	}
.informationNum2{
	color: #333333;
	font-size: 26rpx;
}
	.codeCopy {
		width: 77rpx;
		height: 36rpx;
		background: #F4F5F7;
		border-radius: 22rpx;
		font-size: 24rpx;
		color: #333333;
		text-align: center;
		line-height: 33rpx;
		padding: 0 15rpx;
		margin-left: 20rpx;
	}

	.orderBottom {
		width: 750rpx;
		height: 98rpx;
		background: #FFFFFF;
		position: fixed;
		left: 0;
		bottom: 0;
		display: flex;
		justify-content: flex-end;
	}






	.bottom {
		display: flex;
		justify-content: flex-end;
		padding: 20rpx;
		background-color: #FFFFFF;
		align-items: center;
		height: 98rpx;
		width: 100vw;
		position: fixed;
		bottom: 0rpx;
		padding-bottom: constant(safe-area-inset-bottom);
		padding-bottom: env(safe-area-inset-bottom);
	}

	.cancel {
		color: #3C3C3C;
		font-size: 28rpx;
		width: 150rpx;
		height: 56rpx;
		border-radius: 36rpx;
		border: 1rpx solid #DDDDDD;
		text-align: center;
		line-height: 56rpx;
		margin-right: 40rpx;
	}
	.evaluatecancel{
		width: 200rpx;
	}

	.defer {
		color: #D53533;
		font-size: 28rpx;
		width: 150rpx;
		height: 56rpx;
		border-radius: 36rpx;
		border: 1rpx solid #D53533;
		text-align: center;
		line-height: 56rpx;
		margin-right: 40rpx;
	}
.evaluateDetermine{
	width: 200rpx;
}
	.itemBox {
		margin: 20rpx;
		border-radius: 10rpx;
		border: 2rpx solid #EEEEEE;
	}

	.itemTop {
		padding: 18rpx 20rpx;
		padding-right: 0;
		background-color: #FFEFD5;

		display: flex;
		justify-content: space-between;
		align-content: center;
	}

	.topTitle {
		width: 104rpx;
		font-size: 26rpx;
		color: #333333;
		margin-right: 20rpx;
		text-align: right;
	}
	

	.leftItem {
		font-size: 26rpx;
		color: #333333;
		margin-right: 20rpx;
		flex-grow: 1;
		/* 隐藏文字显示 ...不换行 */
		overflow: hidden;
		text-overflow: ellipsis;
		white-space: nowrap;
	}

	.itemContent {
		padding: 20rpx;
		padding-right: 0;
		background-color: #FFFFFF;

		display: flex;
		justify-content: space-between;
		align-content: center;
	}

	.maBox {
		width: 100%;
		height: 100vh;
		background: rgba(0, 0, 0, 0.4);
		position: fixed;
		left: 0;
		top: 0;
		z-index: 9999;
	}

	.querenMa {
		width: 578;
		height: 640rpx;
		background: #ffffff;
		margin: 0 86rpx;
		margin-top: 50%;
		border-radius: 24rpx;
	}

	.maTop {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 30rpx 20rpx 15rpx;
	}


	.maTitle {
		color: #666666;
		font-size: 26rpx;
		text-align: center;
		padding-left: 100rpx;
	}
	.swiper{
		width: 100%;
		height: 85%;
		background: #FFFFFF;
		
	}
	.swiper-item{
		width: 100%;
		height: 100%;
	}
	
	
	.maCode {

		font-size: 30rpx;
		font-weight: 500;
		color: #333333;
		line-height: 42rpx;
		margin-bottom: 40rpx;
		text-align: center;
	}

	.maBoximg {
		width: 400rpx;
		height: 400rpx;
		margin-left: 86rpx;
	}
	.authorizBox{
			width: 100vw;
			height: 100vh;
			background: rgba(0, 0, 0, 0.5);
			position: fixed;
			top: 0;
			left: 0;
		}
		.authorizCont{
			margin-top: 30vh;
			width: 564rpx;
			height: 408rpx;
			background: #FFFFFF;
			border-radius: 24rpx;
			margin-left: 93rpx;
			position: relative;
		}
		.authorizCloseImg{
			width: 62rpx;
			height: 62rpx;
		}
		.sqLogoBox{
			width: 180rpx;
			height: 180rpx;
			background: #FFFFFF;
			border-radius: 90rpx;
			text-align: center;
			position: absolute;
			top: -50rpx;
			left: 192rpx;
		}
		.authorizName{
			color: #333333;
			line-height: 42rpx;
			font-size: 30rpx;
			text-align: center;
			padding-top: 58rpx;
		}
		.authorizMs{
			color: #999999;
			line-height: 36rpx;
			font-size: 26rpx;
			width: 452rpx;
			padding-top: 24rpx;
			text-align: center;
			margin-left: 56rpx;
		}
		.authorizContbutton{
			width: 422rpx;
			height: 88rpx;
			background: #D53533;
			border-radius: 44rpx;
			line-height: 88rpx;
			text-align: center;
			font-size:30rpx;
			color: #FFFFFF;
			margin-top: 62rpx;
			margin-left:71rpx;
		}
		.shopBoxpt{
			margin-top: 20rpx;
		}
		button::after{
		 	border: none;
		}
		button{
			position: relative;
			display: block;
			margin-left: 0;
			margin-right: 0;
			padding-left: 0px;
			padding-right: 0px;
			box-sizing: border-box;
			// font-size: 18px;
			text-align: center;
			text-decoration: none;
			// line-height: 1;
			line-height: 1.35;
			// border-radius: 5px;
			-webkit-tap-highlight-color: transparent;
			overflow: hidden;
			color: #000000;
			background-color: #fff;
			
			height: 100%;
			}
			
.tuikuanBox {
		width: 100%;
		height: 100vh;
		background: rgba(0, 0, 0, 0.4);
		position: fixed;
		left: 0;
		top: 0;
		z-index: 999;
	}
	
	.tuikuan {
		width: 638rpx;
		height: 664rpx;
		background: #ffffff;
		margin: 0 36rpx;
		margin-top: 50%;
		border-radius: 24rpx;
		padding: 30rpx 20rpx;
	}
	
	.tuiTop {
		display: flex;
		justify-content: space-between;
		margin-bottom: 36rpx;
	}
	
	.tuiTitle {
		width: 56rpx;
		height: 40rpx;
		font-size: 28rpx;
		font-weight: 500;
		color: #3C3C3C;
		line-height: 40rpx;
	
	}
	
	.contLine {
		display: flex;
		justify-content: space-between;
		font-size: 28rpx;
		padding: 30rpx 0;
		border-bottom: 1px solid #EEEEEE;
	}
	
	.contlineLeft {
		color: #666666;
		line-height: 40rpx;
		align-items: center;
	}
	
	.star {
		width: 14rpx;
		height: 14rpx;
		padding-bottom: 5rpx;
	}
	
	.carModel {
		width: 350rpx;
		text-align: left;
	}
	
	.noColor {
		color: #CCCCCC;
	}
	
	.carModelRight {
		display: flex;
		justify-content: flex-start;
		align-items: center;
	}
	
	.contlineRight {
		color: #333333;
		line-height: 40rpx;
	
		width: 400rpx;
		text-align: right;
	}
	
	.contlineRightInput {
		color: #333333;
		text-align: left;
		font-size: 28rpx;
		min-height: 182rpx;
		width: 400rpx;
	}
	
	.contlineRightJt {
		width: 30rpx;
		height: 30rpx;
	
	}
	
	.tuiBtns {
		display: flex;justify-content: space-around;
		padding: 40rpx 20rpx 10rpx;
	
	}
	.btn {
		width: 250rpx;
		height: 70rpx;
		background: #F4F5F7;
		border-radius: 10rpx;
		font-size: 28rpx;
		font-weight: 500;
		color: #3C3C3C;
		line-height: 70rpx;
		text-align: center;
	}
	
	.btn2 {
		width: 250rpx;
		height: 70rpx;
		background: #3F90F7;
		border-radius: 10rpx;
		font-size: 28rpx;
		font-weight: 500;
		color: #FFFFFF;
		line-height: 70rpx;
		text-align: center;
	}
	.writeoffLine{
		display: flex;justify-content: space-between;
		color: #999999;font-size: 24rpx;
		line-height: 33rpx;padding-top: 8rpx;
	}
	.writeoffLineBox{
		padding: 0 20rpx;
	}
	
	.detailedLineBox .detailedLine{
		padding-bottom: 0rpx;
	}
	.writeoffXx .informationNum{
		width: 500rpx;
	}
	.detailedLineBox{
		padding-bottom: 10rpx;
	}
</style>