aaa
This commit is contained in:
		
							parent
							
								
									0b023c2a3b
								
							
						
					
					
						commit
						a9d108e752
					
				|  | @ -1,9 +1,12 @@ | |||
| <template> | ||||
| 	<view class="page"> | ||||
| 	<!-- 	<u-navbar  :border-bottom="false" :background="bgc" title-color='#fff' back-icon-color="#fff" | ||||
| 		<!-- 	<u-navbar  :border-bottom="false" :background="bgc" title-color='#fff' back-icon-color="#fff" | ||||
| 			title-size='36' height='50'></u-navbar> --> | ||||
| 		<view class="title"> | ||||
| 		    {{deviceobj.deviceName}} | ||||
| 			{{deviceobj.deviceName}} | ||||
| 			<view class="wz"> | ||||
| 				该设备还剩余时长:{{expireTimeStr + 1}}分钟 | ||||
| 			</view> | ||||
| 		</view> | ||||
| 		<view class="box"> | ||||
| 			<view class="tit"> | ||||
|  | @ -32,14 +35,15 @@ | |||
| 				<view class="tits" style="margin-top: 10rpx;"> | ||||
| 					套餐说明 | ||||
| 				</view> | ||||
| 				<view class="wz"> | ||||
| 					该设备还剩余时长:{{expireTimeStr + 1}}分钟 | ||||
| 				</view> | ||||
| 
 | ||||
| 				<view class=""> | ||||
| 					{{item.description == null ? '无' : item.description}} | ||||
| 				</view> | ||||
| 				<view class="wz"> | ||||
| 					联系客服:2562356565 | ||||
| 				<view class="wz" v-if="deviceobj.storeContactMobile == null"> | ||||
| 					联系客服:<text style="color: #8883F0;" @click="call">{{deviceobj.userMobile}}</text> | ||||
| 				</view> | ||||
| 				<view class="wz" v-else> | ||||
| 					联系客服:<text style="color: #8883F0;" @click="call">{{deviceobj.storeContactMobile}}</text> | ||||
| 				</view> | ||||
| 			</view> | ||||
| 
 | ||||
|  | @ -83,7 +87,6 @@ | |||
| 			} | ||||
| 		}, | ||||
| 		onLoad(option) { | ||||
| 			console.log(option.q) | ||||
| 			if (option.q) { | ||||
| 				function getQueryParam(url, paramName) { | ||||
| 					let regex = new RegExp(`[?&]${paramName}=([^&]*)`); | ||||
|  | @ -97,13 +100,11 @@ | |||
| 				this.startTimer() | ||||
| 				this.gettaoc() | ||||
| 				this.getmac() | ||||
| 	            this.gettrue() | ||||
| 			} else { | ||||
| 				this.id = option.id | ||||
| 				this.startTimer() | ||||
| 				this.gettaoc() | ||||
| 				this.getmac() | ||||
| 	            this.gettrue() | ||||
| 			} | ||||
| 			// 一开始搜索设备 | ||||
| 			xBlufi.initXBlufi(1) | ||||
|  | @ -128,10 +129,10 @@ | |||
| 
 | ||||
| 		}, | ||||
| 		onShow() { | ||||
| 			this.getuserinfo() | ||||
| 			if (this.orderno) { | ||||
| 				this.gethuidaio() | ||||
| 			} | ||||
| 			this.getuserinfo() | ||||
| 		}, | ||||
| 		onUnload: function() { | ||||
| 			if (this.timer) { | ||||
|  | @ -156,22 +157,45 @@ | |||
| 			}); | ||||
| 		}, | ||||
| 		methods: { | ||||
| 			gettrue(){ | ||||
| 			call() { | ||||
| 				let phoneNumber = '' | ||||
| 				if(this.deviceobj.storeContactMobile == null){ | ||||
| 					phoneNumber = this.deviceobj.userMobile | ||||
| 				}else{ | ||||
| 					phoneNumber = this.deviceobj.storeContactMobile | ||||
| 				} | ||||
| 				uni.makePhoneCall({ | ||||
| 					phoneNumber: phoneNumber,  | ||||
| 					success: function(res) { | ||||
| 						console.log('拨打电话成功', res); | ||||
| 					}, | ||||
| 					fail: function(err) { | ||||
| 						console.error('拨打电话失败', err); | ||||
| 						uni.showToast({ | ||||
| 							title: '拨打电话失败', | ||||
| 							icon: 'none' | ||||
| 						}) | ||||
| 					} | ||||
| 				}) | ||||
| 				 | ||||
| 			}, | ||||
| 
 | ||||
| 			gettrue() { | ||||
| 				this.$u.get("/app/device/isBind?deviceNo=" + this.id).then((res) => { | ||||
| 					if (res.data == false) { | ||||
|                         uni.navigateTo({ | ||||
|                         	url:'/pages/shouye/index?flag=' + true + '&id=' + this.id | ||||
|                         }) | ||||
| 					}  | ||||
| 						uni.navigateTo({ | ||||
| 							url: '/pages/shouye/index?flag=' + true + '&id=' + this.id | ||||
| 						}) | ||||
| 					} | ||||
| 				}) | ||||
| 			}, | ||||
| 			getuserinfo() { | ||||
| 				this.$u.get("/app/user/userInfo").then((res) => { | ||||
| 					if (res.code == 200) { | ||||
| 						 | ||||
| 						this.gettrue() | ||||
| 					} else { | ||||
| 						uni.navigateTo({ | ||||
| 							url:'/pages/login/login?id=' + 1 | ||||
| 							url: '/pages/login/login?id=' + 1 | ||||
| 						}) | ||||
| 					} | ||||
| 				}) | ||||
|  | @ -244,7 +268,7 @@ | |||
| 											uni.reLaunch({ | ||||
| 												url: '/pages/shouye/index' | ||||
| 											}) | ||||
| 											uni.setStorageSync('time',that.expireTimeStr) | ||||
| 											uni.setStorageSync('time', that.expireTimeStr) | ||||
| 										}, | ||||
| 										fail(err) { | ||||
| 											// 支付失败逻辑 | ||||
|  | @ -293,7 +317,7 @@ | |||
| 								} | ||||
| 							} | ||||
| 						}) | ||||
| 					}else{ | ||||
| 					} else { | ||||
| 						let that = this | ||||
| 						let data = { | ||||
| 							deviceNo: that.id, | ||||
|  | @ -324,7 +348,7 @@ | |||
| 												uni.reLaunch({ | ||||
| 													url: '/pages/shouye/index' | ||||
| 												}) | ||||
| 												uni.setStorageSync('time',that.expireTimeStr) | ||||
| 												uni.setStorageSync('time', that.expireTimeStr) | ||||
| 											}, | ||||
| 											fail(err) { | ||||
| 												// 支付失败逻辑 | ||||
|  | @ -456,7 +480,7 @@ | |||
| 	// 	padding-bottom: 41rpx; | ||||
| 	// } | ||||
| 	page { | ||||
| 		// background: linear-gradient(180deg, #fff 0%, rgba(255, 255, 255, 0) 100%); | ||||
| 		background: linear-gradient(180deg, #8883F0 0%, rgba(255, 255, 255, 0) 100%); | ||||
| 	} | ||||
| 
 | ||||
| 	.active { | ||||
|  | @ -531,9 +555,15 @@ | |||
| 			padding-left: 32rpx; | ||||
| 			font-weight: 600; | ||||
| 			font-size: 40rpx; | ||||
| 			color: #383838; | ||||
| 			color: #fff; | ||||
| 			margin-bottom: 30rpx; | ||||
| 			margin-top: 110rpx; | ||||
| 
 | ||||
| 			.wz { | ||||
| 				font-weight: 400; | ||||
| 				font-size: 32rpx; | ||||
| 				margin-top: 30rpx; | ||||
| 			} | ||||
| 		} | ||||
| 
 | ||||
| 		.box { | ||||
|  | @ -573,7 +603,7 @@ | |||
| 
 | ||||
| 			.shuom { | ||||
| 				width: 648rpx; | ||||
| 				height: 286rpx; | ||||
| 				height: 230rpx; | ||||
| 				background: #FFFFFF; | ||||
| 				box-shadow: 0rpx 16rpx 40rpx 0rpx rgba(42, 130, 228, 0.1); | ||||
| 				filter: blur(0px); | ||||
|  |  | |||
|  | @ -144,9 +144,9 @@ | |||
| 								} | ||||
| 							}) | ||||
| 						} else if (res.cancel) { | ||||
| 							uni.navigateTo({ | ||||
| 								url: '/pages/shouye/index' | ||||
| 							}) | ||||
| 							// uni.navigateTo({ | ||||
| 							// 	url: '/pages/shouye/index' | ||||
| 							// }) | ||||
| 						} | ||||
| 					} | ||||
| 				}) | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	Block a user