Browse Source

bug修改

twt 2 years ago
parent
commit
a0d3162b21
2 changed files with 107 additions and 24 deletions
  1. 39 12
      pages/europeOrder/eorderDetail.vue
  2. 68 12
      pages/europeOrder/europeOrder.vue

+ 39 - 12
pages/europeOrder/eorderDetail.vue

@@ -57,20 +57,18 @@
 		 			   <view class="timeLeft">
 		 				   <span v-if="orderData.sheetState==1||orderData.sheetState==2||orderData.sheetState==0">预约到店:{{orderData.orderTime}}</span>
 						   <span v-else>服务时间:{{orderData.serviceTime}}</span>
-		 				   <image v-if="orderData.sheetState==1||orderData.sheetState==2" src="../../static/img/icon_edit.png" mode="" class="timeEditImg" @click="timeShowClick"></image>
+		 				   <image v-if="orderData.sheetState==2" src="../../static/img/icon_edit.png" mode="" class="timeEditImg" @click="timeShowClick"></image>
 		 			   </view>
-		 			   <view class="timeRight" @click="qrcodeClick">订单码</view>
+		 			<!--   <view class="timeRight" @click="qrcodeClick">订单码</view> -->
 		 		   </view>
 		 		   <view class="shopBox">
 		 			   <image src="../../static/img/icon_store.png" mode="" class="shopBoximg"></image>
 		 			   <view class="shopCont">
 		 				   <view class="shopName">{{orderData.shopName}}</view>
-		 				   <view class="Address">
-		 					   {{orderData.ProvinceName}}{{orderData.CityName}}{{orderData.AreaName}}{{orderData.Address}}
-		 				   </view>
+		 				 
 		 				  
 		 			   </view>
-		 			   <view class="shopRightBox" @click="map">
+		 			   <!-- <view class="shopRightBox" @click="map">
 		 					   <view> <image src="../../static/img/icon_ditu2.png" mode="" class="shopRightImg"></image> </view>
 		 					   <view class="shopRihgtTxt">地图</view>
 		 			   </view>
@@ -78,7 +76,7 @@
 		 			   <view class="shopRightBox" @click="call">
 		 				   <view> <image src="../../static/img/icon_phone2.png" mode="" class="shopRightImg"></image> </view>
 		 				   <view class="shopRihgtTxt">电话</view>
-		 			   </view>
+		 			   </view> -->
 		 		   </view>
 		 		   <view class="people">
 		 			     <image src="../../static/img/icon_ren.png" mode="" class="shopBoximg"></image>
@@ -89,8 +87,8 @@
 		 			   <image src="../../static/img/icon_che.png" mode="" class="shopBoximg"></image>
 		 			   <view class="">
 		 				   <view class="PlateNumberBoxTop">
-		 					   <view class="PlateNumbercx">  <span v-if="orderData.brand">{{orderData.brand}}</span> 
-		 					      <span style="padding-left: 20rpx;" v-if="orderData.series">{{orderData.series}}</span>
+		 					   <view class="PlateNumbercx">  <span v-if="orderData.carInfo.brand">{{orderData.carInfo.brand}}</span> 
+		 					      <span style="padding-left: 20rpx;" v-if="orderData.carInfo.series">{{orderData.carInfo.series}}</span>
 		 					   </view>
 		 					   <view class="PlateNumber">{{orderData.plateNumber}}</view>
 		 				   </view>
@@ -104,7 +102,7 @@
 		 <view class="detailedBox itemBox" v-if="orderData.goodsList.length!=0">
 		 		   <view class="detailedTitle">商品明细</view>
 		 		   <view class="detailedLineBox">
-		 			   <view class="detailedLine" v-for="(item,index) in orderData.goods">
+		 			   <view class="detailedLine" v-for="(item,index) in orderData.goodsList">
 		 				   <view>
 		 					   <image :src="item.Url" mode="" class="detailedImg" v-if="item.Url"></image>
 		 					    <image src="../../static/img/noimg.png" mode="" class="detailedImg" v-else></image>
@@ -124,7 +122,7 @@
 		 		<view class="detailedBox itemBox" v-if=" orderData.itemList.length!=0">
 		 			   <view class="detailedTitle">项目明细</view>
 		 			   <view class="detailedLineBox">
-		 				   <view class="detailedLine" v-for="(item,index) in orderData.items">
+		 				   <view class="detailedLine" v-for="(item,index) in orderData.itemList">
 		 					   <view>
 		 						   <image :src="item.Url" mode="" class="detailedImg" v-if="item.Url"></image>
 		 						   <image src="../../static/img/noitem.png" mode="" class="detailedImg" v-else></image>
@@ -212,7 +210,7 @@
 		 				<view class="payBtn" @click="evaluate">立即评价</view>
 		 		</view> -->
 				<view class="orderBottom" v-if="orderData.sheetState==2">
-					<view class="cancelBtn" style="margin-right: 16rpx;" @click="">核销</view>
+					<view class="cancelBtn" style="margin-right: 16rpx;" @click="goHeXiao">核销</view>
 				</view>
 		 		<!-- 二维码 -->
 		 		<view v-if="qrcodeShow" class="qrcodeBox" @click="qrcodeShow=false">
@@ -306,6 +304,7 @@ export default {
 			orderTimeIndex1:0,
 			orderTimeIndex2:-1,
 			isShowMa: true,
+			iOSInfo:'',
 		}
 	},
 	onLoad(opt) {
@@ -315,6 +314,12 @@ export default {
 		this.getData()
 		this.type=opt.type;
 		 this.getOrderTimes();
+		 var qxnum = uni.getStorageSync("quanxian");
+		 if (qxnum == 1) {
+		 	this.iOSInfo = JSON.parse(JSON.stringify(window.iOSInfo));
+		 }else if(qxnum==2){
+		 	 window.getAndroid=this.getAndroid;
+		  }
 	},
 	onShow() {
 		if(this.id){
@@ -322,6 +327,9 @@ export default {
 		}
 	},
 	methods: {
+		getAndroid(e){
+			this.iOSInfo=e		
+		},
 		showMa() {
 			this.isShowMa = !this.isShowMa
 		},
@@ -342,7 +350,25 @@ export default {
 			}
 			
 		},
+		goHeXiao() {
+		    console.log(this.id)
+			//app交互
+			var standalone = window.navigator.standalone
+			var userAgent = window.navigator.userAgent.toLowerCase()
+			var safari = /safari/.test(userAgent)
+			var ios = /iphone|ipod|ipad|mac/.test(userAgent)
+			var android = /android/.test(userAgent)
+			if (ios) {
+				if (true) { //!standalone&& !safari
+					window.webkit.messageHandlers.europewriteoff.postMessage({
+						"id": this.id ? this.id : ''
+					})
+				}
+			} else if (android) {
+				window.android.europewriteoff(this.id)
+			}
 		
+		},
 		map(){
 			console.log("打开地图")
 			var that=this;
@@ -652,6 +678,7 @@ export default {
 	.shopName{
 		font-size: 28rpx;
 		color: #3C3C3C;
+		font-weight: 500;
 	}
 	.Address{
 		color: #999999;font-size: 26rpx;padding-top: 10rpx;

+ 68 - 12
pages/europeOrder/europeOrder.vue

@@ -20,6 +20,13 @@
 			<view class="tabLine" :class="{tabActive:tabIndex==2}"  @click="tabClick(2)">待服务</view>
 			<view class="tabLine" :class="{tabActive:tabIndex==4}"  @click="tabClick(3)">已完成</view>
 		</view>
+		<view class="topss">
+			<view class="inputBox">
+				<img src="../../static/img/icon_search.png" alt="" class="searchImg">
+				<input v-model="code" type="text" placeholder="请输入订单单号" class="topInput" @confirm="inputconfirm">
+			
+			</view>
+		</view>
 		<view class="main">
 		  <view class="itemLine" v-for="(item,index) in items" @click="goDetail(item.ID)">
 			  <view class="flex2 itemlineTOp">
@@ -86,21 +93,29 @@ export default {
 			page:1,
 			state:'',
 			num:'',
-			tabIndex:'',
+			tabIndex:5,
 			items:[],
 			isload:false,
+			iOSInfo:'',
+			code:'',
 		}
 	},
 	onLoad(opt) {
-        var num=opt.num;
-		this.tabIndex=num;
-		this.items=[]
-       if(num==5){
-		   this.state=''
-	   }else{
-		   this.state=num
-	   }
+  //       var num=opt.num;
+		// this.tabIndex=num;
+		// this.items=[]
+  //      if(num==5){
+		//    this.state=''
+	 //   }else{
+		//    this.state=num
+	 //   }
 		this.getData()
+		var qxnum = uni.getStorageSync("quanxian");
+		if (qxnum == 1) {
+			this.iOSInfo = JSON.parse(JSON.stringify(window.iOSInfo));
+		}else if(qxnum==2){
+			 window.getAndroid=this.getAndroid;
+		 }
 	},
 	onShow() {
 		console.log(this.tabIndex)
@@ -113,6 +128,13 @@ export default {
 		
 	},
 	methods: {
+		inputconfirm(){
+			this.items=[]
+			this.getData()
+		},
+		getAndroid(e){
+			this.iOSInfo=e		
+		},
 		goback(){
 			
 				//app交互
@@ -209,13 +231,15 @@ export default {
 				var padata={
 					page:this.page,
 					limit:10,
-					evaluateState:1
+					evaluateState:1,
+					
 				}
 			}else{
 				var padata={
 					page:this.page,
 					limit:10,
-					sheetState:this.state
+					sheetState:this.state,
+					code:this.code,
 				}
 			}
 		
@@ -284,6 +308,38 @@ export default {
 </script>
 
 <style scoped>
+	.topss{
+		position: fixed;
+		left: 0;
+		top: calc(44px + 89rpx);
+		width: 750rpx;
+		z-index: 11;
+		height: 90rpx;
+		background-color: #FFFFFF;
+		padding-top: 10rpx;
+	}
+	.searchImg{
+		width: 40rpx;
+		height: 40rpx;
+		margin-top: 16rpx;
+		margin-left: 20rpx;
+	}
+	.inputBox{
+		width: 702rpx;
+		height: 72rpx;
+		background: #F4F5F7;
+		border-radius: 36rpx;
+		margin-left: 24rpx;
+		display:flex;
+		position: relative;
+	}
+	.topInput{
+		font-size: 28rpx;
+		height: 72rpx;
+		line-height: 72rpx;
+		padding-left: 16rpx;
+		width: 500rpx;
+	}
 	.zdyNavBox {
 		width: 100vw;
 		background: #FFFFFF;
@@ -346,7 +402,7 @@ export default {
 		z-index: 11;
 	}
 	.main{
-		padding-top:88rpx;
+		padding-top:188rpx;
 		padding-left: 24rpx;
 		padding-right: 24rpx;
 	}