zhengkaixin il y a 1 an
Parent
commit
7070a2bff1

+ 27 - 0
apis/otherRecharge.js

@@ -16,4 +16,31 @@ export function rechargeDetails(data) {
 		data: data,
 		url: url
 	})
+}
+
+export function findByCard(data) {
+	var url='/mobile/otherRecharge/findByCard';
+	return requestWhite({
+		method: 'post',
+		data: data,
+		url: url
+	})
+}
+
+export function bindCard(data) {
+	var url='/mobile/otherRecharge/bindCard';
+	return requestWhite({
+		method: 'post',
+		data: data,
+		url: url
+	})
+}
+
+export function findByPhone(data) {
+	var url='/mobile/otherRecharge/findByPhone';
+	return requestWhite({
+		method: 'post',
+		data: data,
+		url: url
+	})
 }

+ 6 - 0
assets/img/byphone/iconPark-copy-link.svg

@@ -0,0 +1,6 @@
+<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 48 48" width="52" height="52" style="border-color: rgba(0,0,0,0);border-width: bpx;border-style: undefined" filter="drop-shadow(0px 2px 6px rgba(0,0,0,0.4))">
+    
+    <g>
+    <g fill="rgba(255,255,255,1)"><path d="M0 0H48V48H0V0Z" fill="rgba(255,255,255,1)" fill-opacity="0.01" stroke="none"></path><g fill="rgba(255,255,255,1)"><g fill="rgba(255,255,255,1)"><rect width="48" height="48" fill="rgba(255,255,255,1)" fill-opacity="0.01" stroke="none"></rect><path d="M12 9.92704V7C12 5.34315 13.3431 4 15 4H41C42.6569 4 44 5.34315 44 7V33C44 34.6569 42.6569 36 41 36H38.0174" stroke="rgba(255,255,255,1)" stroke-width="4" fill="none"></path><rect x="4" y="10" width="34" height="34" rx="3" fill="none" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linejoin="round"></rect></g><g fill="rgba(255,255,255,1)"><g fill="rgba(255,255,255,1)"><path d="M18.4396 23.1098L23.7321 17.6003C25.1838 16.1486 27.5693 16.1806 29.0604 17.6717C30.5515 19.1628 30.5835 21.5483 29.1319 23L27.2218 25.0228" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" fill="none"></path><path d="M13.4661 28.7469C12.9558 29.2573 11.9006 30.2762 11.9006 30.2762C10.4489 31.7279 10.4095 34.3152 11.9006 35.8063C13.3917 37.2974 15.7772 37.3294 17.2289 35.8777L22.3931 31.1894" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" fill="none"></path><path d="M18.6631 28.3283C17.9705 27.6357 17.5927 26.7501 17.5321 25.8547C17.4624 24.8225 17.8143 23.7774 18.5916 23" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" fill="none"></path><path d="M22.3218 25.8611C23.8129 27.3522 23.8449 29.7377 22.3932 31.1894" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" fill="none"></path></g></g></g></g>
+    </g>
+  </svg>

+ 6 - 0
assets/img/byphone/iconPark-wallet.svg

@@ -0,0 +1,6 @@
+<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 48 48" width="52" height="52" style="border-color: rgba(0,0,0,0);border-width: bpx;border-style: undefined" filter="drop-shadow(0px 2px 6px rgba(0,0,0,0.4))">
+    
+    <g>
+    <rect width="48" height="48" fill="rgba(255,255,255,1)" fill-opacity="0.01" stroke="none"></rect><path fill-rule="evenodd" clip-rule="evenodd" d="M17.9821 11.9689L31.7847 4L36.3971 11.9889L17.9821 11.9689Z" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linecap="round" stroke-linejoin="round" fill="none"></path><path d="M4 14C4 12.8954 4.89543 12 6 12H42C43.1046 12 44 12.8954 44 14V42C44 43.1046 43.1046 44 42 44H6C4.89543 44 4 43.1046 4 42V14Z" fill="none" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linejoin="round"></path><path d="M35.25 33H44V23H35.25C32.3505 23 30 25.2386 30 28C30 30.7614 32.3505 33 35.25 33Z" fill="none" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linejoin="round"></path><path d="M44 16.5V40.5" stroke="rgba(255,255,255,1)" stroke-width="4" stroke-linecap="round" fill="none"></path>
+    </g>
+  </svg>

+ 14 - 0
pages.json

@@ -114,6 +114,20 @@
 			{
 				"enablePullDownRefresh" : false
 			}
+		},
+		{
+			"path" : "pages/user/rechargeIndex",
+			"style" : 
+			{
+				"enablePullDownRefresh" : false
+			}
+		},
+		{
+			"path" : "pages/user/rechargeSubmit",
+			"style" : 
+			{
+				"enablePullDownRefresh" : false
+			}
 		}
 		
     ],

+ 1 - 1
pages/user/index.vue

@@ -40,7 +40,7 @@
 				</view>
 				
 				<view
-				@click="gotoUrl('pages/user/rechargeByPhone?site=1')"
+				@click="gotoUrl('pages/user/rechargeIndex?site=1')"
 				
 				class="user-cell-item">
 					<view class="user-cell-title">

+ 204 - 72
pages/user/rechargeByPhone.vue

@@ -1,6 +1,6 @@
 <template>
 	<view>
-		<ujp-navbar title="帮人充值"  :isBack="isBack">
+		<ujp-navbar title="帮人充值"  :isBack="isBack" :customBack="customBack">
 			<view class="slot-wrap">
 			
 				<span class="navBtn "  @click="toRefundList">	<u-icon name="clock"></u-icon>充值记录</span>
@@ -8,8 +8,13 @@
 		</ujp-navbar>
 		<view class="recharge">
 			<view class="recharge-text">
-				<p>充值账户</p>
-				<u-input v-model="phone"
+				<p v-show="!queryCard.query">充值手机号
+				
+				</p >
+				<p v-show="queryCard.query">
+					用户姓名:{{queryCard.name}}
+				</p>
+				<u-input v-model="phone" v-show="!queryCard.query"
 				:custom-style="{
 					'font-size': '48rpx',
 					'line-height': '48rpx',
@@ -21,49 +26,87 @@
 				}"
 				 height="82" placeholder="请输入充值手机号" ></u-input>
 			</view>
+			<view   class="rechargePhone" v-show="queryCard.query">
+				<view>
+					<h1 style="font-size: 48rpx;line-height: 48rpx;height:82rpx;    display: flex;align-items: center;"   >{{phone}}</h1>
+					
+				</view>
+				<view
+				 @click="queryCard.query=false,phone=''"
+				class="recharge-btn">
+					更换
+				</view>
+			</view>
+		</view>
+	
+		<view style="padding: 30rpx;" v-show="!queryCard.query"  >
 			
+			<u-button type="primary" @click="findByPhone" :custom-style="customStyle" shape="square">查询用户</u-button>
 		</view>
-		<view class="charge">
-			<view class="chargeTit">
-				选择充值金额
-			</view>
-			<view class="chargeMain">
-				<template v-for="(item,i) in list">
-				
-				<view  :key="i" :class="{
-					'active':amount==item
-				}"  @click="amount=item"
-				class="chargeMain-item "><p>{{item}}元</p></view>
+		<view class="rechargeBk" v-show="queryCard.query">
+			<view class="rechargeBkInfo" >
 				
 				
-				</template>
+				<view class="recharge-text">
+					<p>账户余额(元)</p>
+					<h1>{{queryCard.amount}}</h1>
+				</view>
+				<view class="recharge-text">
+					<p>充电卡号</p>
+					<h1>{{queryCard.cardNo}}</h1>
+				</view>
 			</view>
+				
+			
+			
+			
 		</view>
-		<view style=" padding-bottom: 120px; ">
-			<view class="charge">
-			<view class="chargeRadio">
-				<view class="u-flex">
-					<u-icon name="weixinzhifu" custom-prefix="custom-icon" color="#22ac38" size="80"></u-icon>
-					<view class="chargeRadio-text">
-						<h4>微信支付</h4>
-						<p>推荐微信支付</p>
+		
+		
+		<view v-show="queryCard.query">
+			<view class="charge" >
+				<view class="chargeTit">
+					选择充值金额
+				</view>
+				<view class="chargeMain">
+					<template v-for="(item,i) in list">
+					
+					<view  :key="i" :class="{
+						'active':amount==item
+					}"  @click="amount=item"
+					class="chargeMain-item "><p>{{item}}元</p></view>
+					
+					
+					</template>
+				</view>
+			</view>
+			<view style=" padding-bottom: 240rpx; " >
+				<view class="charge">
+				<view class="chargeRadio">
+					<view class="u-flex">
+						<u-icon name="weixinzhifu" custom-prefix="custom-icon" color="#22ac38" size="80"></u-icon>
+						<view class="chargeRadio-text">
+							<h4>微信支付</h4>
+							<p>推荐微信支付</p>
+						</view>
 					</view>
+					<u-radio-group>
+						<u-radio></u-radio>
+					</u-radio-group>
 				</view>
-				<u-radio-group>
-					<u-radio></u-radio>
-				</u-radio-group>
 			</view>
-		</view>
+				
+			</view>
 			
-		</view>
-		
-		<view class="foot-btn">
-			<view class="foot-pirce">
-				<u-icon name="tikuan" custom-prefix="custom-icon" color="#FF9502" size="48"></u-icon>
-				<span>支付 {{amount}} 元</span>
+			<view class="foot-btn"  >
+				<view class="foot-pirce">
+					<u-icon name="tikuan" custom-prefix="custom-icon" color="#FF9502" size="48"></u-icon>
+					<span>支付 {{amount}} 元</span>
+				</view>
+				<u-button type="primary" @click="submit" :custom-style="customStyle" shape="square">确定充值</u-button>
 			</view>
-			<u-button type="primary" @click="submit" :custom-style="customStyle" shape="square">确定充值</u-button>
 		</view>
+		
 	</view>
 </template>
 
@@ -75,18 +118,20 @@
 	import {
 		wxPayJs
 	} from '@/utils/wxpay'
-	import * as API from '@/apis/index.js'
+	import * as API from '@/apis/otherRecharge.js'
 	
 	
 	export default {
 		data() {
 			return {
+				queryCard:{},
+				
 				isReady:false,
 				customStyle: {
 					background: '#1677ff'
 				},
 				detail:{},
-				isBack:false,
+				isBack:true,
 				chargingMarketingId:'',
 				selectItem:{},
 				list:[5,10,20,50,100,200],
@@ -95,15 +140,57 @@
 			}
 		},
 		onLoad(op){
-			if(op.site){
-				this.isBack=true;
-			}
-			
+			 if(op.phone){
+				 this.phone=op.phone
+				 this.findByPhone()
+			 }
 		},
 		onReady() {
 		
 		},
 		methods: {
+			findByPhone(){
+				var checkPhoneResult = checkPhone(this.phone);
+				
+				if ( checkPhoneResult !== true) {
+					uni.showToast({
+						title: checkPhoneResult,
+				
+					})
+					return;
+				}
+				uni.showLoading({
+					title: "加载中",
+					mask: true,
+				})
+				API.findByPhone({
+					phone: this.phone,
+				
+				}).then((response) => {
+					
+					var data = response.data
+					uni.hideLoading()
+					this.queryCard={
+						query:true,
+						amount:data.userAccount.availableBalance,
+						name:data.chargingCard.realName,
+						cardNo:data.chargingCard.cardNo
+					}
+				
+				}).catch(error => {
+					uni.hideLoading()
+					uni.showModal({
+						title:"提示",
+						content:error,
+						showCancel:false,
+					})
+				})
+			},
+			customBack(){
+				uni.reLaunch({
+						url: '/pages/user/rechargeIndex'
+				})
+			},
 			toRefundList() {
 				uni.navigateTo({
 					url: '/pages/user/rechargeListByPhone'
@@ -141,8 +228,11 @@
 					wxPayJs(data);
 						
 				}).catch(error => {
-					uni.showToast({
-						title: error
+					uni.hideLoading()
+					uni.showModal({
+						title:"提示",
+						content:error,
+						showCancel:false,
 					})	
 				})
 			},
@@ -166,35 +256,77 @@
 	}
 	.navBtn{
 		float: right;
-		margin-right: 15px;
+		margin-right: 30rpx;
 		color:#1677FF ;
 	}
-	.recharge{
-		padding: 15px;
-		//background-color: #1677FF;
-		background-color: #fff;
-		margin-bottom: 10px;
+	
+	.rechargePhone{
 		display: flex;
 		justify-content: space-between;
 		align-items: center;
+		//padding: 15px;
+		//background-color: #1677FF;
+		background-color: #fff;
+		.recharge-btn{
+			width: 120rpx;
+			height: 60rpx;
+			text-align: center;
+			line-height: 60rpx;
+			background-color: #589EFF;
+			color:#fff;
+			border-radius: 15px;
+		}
+	}
+	.rechargeBk{
+		.rechargeBkInfo{
+			display: flex;
+			justify-content: space-around;
+			align-items: center;
+			 
+		}
+		.recharge-text-name{
+			width: 200rpx;
+			white-space: nowrap;
+			 overflow: hidden; 
+			 text-overflow: ellipsis;
+		}
+		padding: 30rpx;
+		background-color: #1677FF;
+	
+		margin-bottom: 20rpx;
+		.recharge-text{
+			color:#fff;
+			    // width: 100%;
+				white-space: pre;
+		}
+	
+		
+	}
+	
+	.recharge{
+		padding: 30rpx;
+		//background-color: #1677FF;
+		background-color: #fff;
+		
+		
 		.recharge-text{
 			//color:#fff;
 			    width: 100%;
 		}
 		.recharge-btn{
-			width: 60px;
-			height: 30px;
+			width: 120rpx;
+			height: 60rpx;
 			text-align: center;
-			line-height: 30px;
+			line-height: 60rpx;
 			background-color: #589EFF;
 			color:#fff;
 			border-radius: 15px;
 		}
 	}
 	.charge{
-		padding: 15px;
+		padding: 30rpx;
 		background-color: #fff;
-		margin-bottom: 10px;
+		margin-bottom: 40rpx;
 	}
 	.chargeRadio{
 		display: flex;
@@ -202,50 +334,50 @@
 		align-items: center;
 		width: 100%;
 		.chargeRadio-text{
-			margin-left: 5px;
+			margin-left: 10rpx;
 			h4{
 				font-weight: normal;
-				font-size: 15px;
+				font-size: 30rpx;
 			}
 			p{
-				font-size: 12px;
+				font-size: 24rpx;
 				color:#999;
-				margin-top: 5px;
+				margin-top: 10rpx;
 			}
 		}
 	}
 	.chargeTit{
 		border-bottom: 1px solid #f7f7f7;
-		padding-bottom: 10px;
-		font-size: 15px;
+		padding-bottom: 20rpx;
+		font-size: 30rpx;
 	}
 	.chargeMain{
 		display: flex;
 		flex-wrap: wrap;
 		justify-content: space-between;
-		margin-top: 20px;
+		margin-top: 40rpx;
 		.chargeMain-item{
 			width: 32%;
 			text-align: center;
-			padding: 10px 10px;
+			padding: 20rpx;
 			border: 1px solid rgba(22, 119, 255, 1);
-			margin-bottom: 10px;
+			margin-bottom: 20rpx;
 			border-radius: 5px;
 			color:#333;
 			color: rgba(22, 119, 255, 1);
 			position: relative;
 			p{
-				font-size: 20px;
+				font-size: 40rpx;
 			}
 			span{
 				background-color: #ff8d00;
 				color:#fff;
-				padding: 2px 10px;
+				padding: 4rpx 20rpx;
 				border-radius:0 10px 0 10px;
 				position: absolute;
-				font-size: 12px;
-				right: -2px;
-				top: -2px;
+				font-size: 24rpx;
+				right: -4rpx;
+				top: -4rpx;
 			}
 		}
 		.active{
@@ -265,7 +397,7 @@
 		}
 	}
 	.foot-btn{
-		padding: 10px;
+		padding: 20rpx;
 		position: fixed;
 		left: 0;
 		right: 0;
@@ -275,12 +407,12 @@
 			display: flex;
 			align-items: center;
 			span{
-				margin-left: 5px;
-				font-size: 16px;
+				margin-left: 10rpx;
+				font-size: 32rpx;
 			}
-			padding-bottom: 10px;
+			padding-bottom: 20rpx;
 			border-bottom: 1px solid #f7f7f7;
-			margin-bottom: 10px;
+			margin-bottom: 20rpx;
 		}
 	}
 </style>

+ 27 - 3
pages/user/rechargeDeatilsByPhone.vue

@@ -28,6 +28,11 @@
 				<p>{{detail.orderInfo.transactionId}}</p>
 			</view>
 		</view>
+		<view class="foot-btn"  >
+			
+			<u-button type="primary"  @click="gotoUrl('pages/user/rechargeByPhone?phone='+detail.otherRecharge.phone)" :custom-style="customStyle" shape="square">再次充值</u-button>
+		</view>
+		
 	</view>
 </template>
 
@@ -80,20 +85,39 @@
 	.chargeDetails{
 		background-color: #FFFFFF;
 		.chargeDetails-item{
-			margin:0 10px;
+			margin:0 20rpx;
 			border-bottom: 1px solid #F7F7F7;
 			display: flex;
 			align-items: center;
 			justify-content: space-between;
-			padding: 15px;
+			padding: 30rpx;
 			span{
 				color:#999;
 			}
 		}
 		.price{
-			font-size: 20px;
+			font-size: 40rpx;
 			color:#FF3D00;
 			font-weight: bold;
 		}
 	}
+	.foot-btn{
+		padding: 20rpx;
+		position: fixed;
+		left: 0;
+		right: 0;
+		bottom: 0;
+		background-color: #fff;
+		.foot-pirce{
+			display: flex;
+			align-items: center;
+			span{
+				margin-left: 10rpx;
+				font-size: 32rpx;
+			}
+			padding-bottom: 20rpx;
+			border-bottom: 1px solid #f7f7f7;
+			margin-bottom: 20rpx;
+		}
+	}
 </style>

+ 139 - 0
pages/user/rechargeIndex.vue

@@ -0,0 +1,139 @@
+<template>
+	<view>
+		<ujp-navbar title="帮人充值"  :isBack="isBack" :customBack="customBack">
+		
+		</ujp-navbar>
+		<view class="item1 item" @click="gotoUrl('pages/user/rechargeSubmit')">
+			<img src="@/assets/img/byphone/iconPark-copy-link.svg">
+			绑定充电卡
+		</view>
+		<view class="item2 item"  @click="gotoUrl('pages/user/rechargeByPhone')" >
+			<img src="@/assets/img/byphone/iconPark-wallet.svg">
+			充电卡充值
+		</view>
+		
+	</view>
+</template>
+
+<script>
+	import * as Pay from '@/apis/weixin.js'
+	 import {
+	 	checkPhone
+	 } from '@/utils'
+	import {
+		wxPayJs
+	} from '@/utils/wxpay'
+	import * as API from '@/apis/index.js'
+	
+	
+	export default {
+		data() {
+			return {
+				isReady:false,
+				customStyle: {
+					background: '#1677ff'
+				},
+				detail:{},
+				isBack:false,
+				chargingMarketingId:'',
+				selectItem:{},
+				list:[5,10,20,50,100,200],
+				amount:5,
+				phone:"",
+			}
+		},
+		onLoad(op){
+			if(op.site){
+				this.isBack=true;
+			}
+			
+		},
+		onReady() {
+		
+		},
+		methods: {
+			customBack(){
+				uni.reLaunch({
+						url: '/pages/user/index'
+				})
+			},
+			toRefundList() {
+				uni.navigateTo({
+					url: '/pages/user/rechargeListByPhone'
+				})
+			},
+			submit(){
+				var checkPhoneResult = checkPhone(this.phone);
+				
+				if ( checkPhoneResult !== true) {
+					uni.showToast({
+						title: checkPhoneResult,
+				
+					})
+					return;
+				}
+				
+				uni.showLoading({
+					title: "加载中",
+					mask: true,
+				})
+				Pay.wxJsapiPayByPhone({
+					openId:this.carhelp.getOpenId(),
+					phone:this.phone,
+					amount:this.amount
+				}).then((response) => {
+					if(!response.result){		
+						uni.showToast({
+							title:  response.message
+						})
+						return
+					}
+					var data = response.data
+					uni.hideLoading()
+					console.log("Pay+"+new Date().getTime())		
+					wxPayJs(data);
+						
+				}).catch(error => {
+					uni.showToast({
+						title: error
+					})	
+				})
+			},
+			
+			
+		},onShow(){
+			if(this.isReady){
+				
+			}
+		}
+	}
+</script>
+<style>
+	page{
+		background-color: #f7f7f7;
+	}
+</style>
+<style lang="scss" scoped>
+	.item{
+		margin: 32rpx;
+		border-radius: 8px;
+		font-size: 80rpx;
+		color: rgba(255, 255, 255, 1);
+		padding:  88rpx 0;
+		    display: flex;
+		    align-items: center;
+		    justify-content: center;
+		img{
+			width: 104rpx;
+			height:104rpx;
+		}
+
+	}
+	.item1{
+		background: linear-gradient(180deg, rgba(31,85,255,1) 0%,rgba(39,171,255,1) 100%);
+	}
+	.item2{
+		background: linear-gradient(-0.11deg, rgba(79,226,157,1) 0.3%,rgba(0,173,222,1) 101.1%);
+	}
+	
+</style>

+ 11 - 11
pages/user/rechargeListByPhone.vue

@@ -11,7 +11,7 @@
 			<span>{{month}}月</span>
 			<u-icon name="arrow-down-s-fill" custom-prefix="custom-icon" color="#B3B3B3" size="32"></u-icon>
 		</view>
-		<view style="text-align: center;margin-top: 100px" v-if="!accountList.length">
+		<view style="text-align: center;margin-top: 200rpx" v-if="!accountList.length">
 		
 			<img src="@/assets/img/blankpage.png">
 			<p>暂无充值记录</p>
@@ -117,7 +117,7 @@
 	}
 	.navBtn{
 		float: right;
-		margin-right: 15px;
+		margin-right: 30rpx;
 		color:#3fbd70;
 	}
 	.carNone{
@@ -130,25 +130,25 @@
 			height: 100%;
 		}
 		p{
-			margin-top: -60px;
+			margin-top: -120rpx;
 		}
 	}
 	.rechargeTime{
 		background-color: #fff;
-		height: 44px;
+		height: 88rpx;
 		display: flex;
 		align-items: center;
-		padding: 12px 16px;
+		padding: 24rpx 32rpx;
 		border-bottom: 1px solid #f7f7f7;
 		span{
-			margin-right: 4px;
+			margin-right: 8rpx;
 		}
 	}
 	.rechargeList{
 		background-color: #fff;
-		padding-left: 16px;
+		padding-left: 32rpx;
 		.rechargeList-item{
-			padding: 12px 16px 12px 0;
+			padding: 24rpx 32rpx 24rpx 0;
 			border-bottom: 1px solid #f7f7f7;
 			&:last-child{
 				border-bottom: none;
@@ -159,11 +159,11 @@
 			align-items: center;
 			justify-content: space-between;
 			h4{
-				font-size: 16px;
+				font-size: 32rpx;
 			}
 			p{
-				font-size: 12px;
-				margin-top: 4px;
+				font-size: 24rpx;
+				margin-top: 8rpx;
 				color:#888;
 			}
 		}

+ 251 - 0
pages/user/rechargeSubmit.vue

@@ -0,0 +1,251 @@
+<template>
+	<view>
+		<ujp-navbar title="绑定充电卡" :isBack="isBack">
+
+		</ujp-navbar>
+		<view class="recharge" v-show="!queryInfo">
+			<view class="recharge-text">
+				<view class="recharge-title">绑定卡号</view>
+				<view class="recharge-value">
+					<u-input v-model="cardNo" :custom-style="customStyle" :placeholder-style="placeholderStyle"
+						:height="height" placeholder="请填写绑定卡号"></u-input>
+
+				</view>
+
+			</view>
+			<view class="recharge-text">
+				<view class="recharge-title">用户姓名</view>
+				<view class="recharge-value">
+					<u-input v-model="name" :custom-style="customStyle" :placeholder-style="placeholderStyle"
+						:height="height" placeholder="请填写用户姓名"></u-input>
+			
+				</view>
+			
+			</view>
+			<view class="recharge-text">
+				<view class="recharge-title">手机号码</view>
+				<view class="recharge-value">
+					<u-input v-model="phone" :custom-style="customStyle" :placeholder-style="placeholderStyle"
+						:height="height" placeholder="请填写绑定手机号"></u-input>
+
+				</view>
+
+			</view>
+		
+			<view class="recharge-text">
+				<view class="recharge-title">绑定状态</view>
+				<view class="recharge-value FF7B00 ">
+					未绑定
+				</view>
+
+			</view>
+			<view class="foot-btn">
+
+				<u-button type="primary" @click="submit" shape="square">确定绑定</u-button>
+			</view>
+		</view>
+		<view class="recharge" v-show="queryInfo">
+			<view class="recharge-text">
+				<view class="recharge-title">绑定卡号</view>
+				<view class="recharge-value">
+					{{cardNo}}
+				</view>
+		
+			</view>
+			<view class="recharge-text">
+				<view class="recharge-title">用户姓名</view>
+				<view class="recharge-value">
+					{{name}}
+				</view>
+			
+			</view>
+			<view class="recharge-text">
+				<view class="recharge-title">手机号码</view>
+				<view class="recharge-value">
+					{{phone}}
+				</view>
+		
+			</view>
+		
+			<view class="recharge-text">
+				<view class="recharge-title">绑定状态</view>
+				<view class="recharge-value color3a7cf6 ">
+					已绑定
+				</view>
+		
+			</view>
+			<view class="foot-btn">
+		
+				<u-button type="success" @click="gotoUrl('pages/user/rechargeByPhone?phone='+phone)" shape="square">前往充值</u-button>
+			</view>
+		</view>
+
+
+	</view>
+</template>
+
+<script>
+	
+	import {
+		checkPhone
+	} from '@/utils'
+	import * as API from '@/apis/otherRecharge.js'
+
+	export default {
+		data() {
+			return {
+				isReady: true,
+				height: 82,
+				customStyle: {
+					'font-size': '42rpx',
+					'line-height': '42rpx',
+				},
+				placeholderStyle: {
+					'font-size': '42rpx',
+					'line-height': '42rpx',
+					'color': ' rgba(204, 204, 204, 1)',
+				},
+				cardNo:"",
+				name:"",
+				phone:"",
+				queryCard:{},
+				queryInfo:false,
+			}
+		},
+		onLoad(op) {
+
+
+		},
+		onReady() {
+
+		},
+		methods: {
+			submitApi() {
+				uni.showLoading({
+					title: "加载中",
+					mask: true,
+				})
+				API.bindCard({
+					cardNo: this.cardNo,
+					phone: this.phone,
+					name: this.name
+				}).then((response) => {
+					
+					var data = response.data
+					uni.hideLoading()
+					this.queryInfo=true
+				
+				}).catch(error => {
+					uni.showToast({
+						title: error
+					})
+				})
+			},
+			submit() {
+				if (!this.cardNo) {
+					uni.showToast({
+						title: "请填写绑定卡号",
+					})
+					return;
+				}
+				if (!this.name) {
+					uni.showToast({
+						title: "请填写用户姓名",
+					})
+					return;
+				}
+				if (!this.phone) {
+					uni.showToast({
+						title: "请填写绑定手机号",
+					})
+					return;
+				}
+				
+				
+				var checkPhoneResult = checkPhone(this.phone);
+
+				if (checkPhoneResult !== true) {
+					uni.showToast({
+						title: checkPhoneResult,
+
+					})
+					return;
+				}
+
+				uni.showLoading({
+					title: "加载中",
+					mask: true,
+				})
+				API.findByCard({
+					cardNo: this.cardNo,
+				
+				}).then((response) => {
+					
+					var data = response.data
+					uni.hideLoading()
+					if(data.regUser){
+						uni.showModal({
+							title:"提示",
+							content:"当前卡号已被其他用户绑定",
+							showCancel:false,
+						})
+					}
+					this.submitApi()
+				
+				}).catch(error => {
+					uni.hideLoading()
+					uni.showModal({
+						title:"提示",
+						content:error,
+						showCancel:false,
+					})
+				})
+			},
+
+
+		},
+		onShow() {
+			if (this.isReady) {
+
+			}
+		}
+	}
+</script>
+<style>
+	page {
+		background-color: #f7f7f7;
+	}
+</style>
+<style lang="scss" scoped>
+	.FF7B00 {
+		color: #FF7B00;
+	}
+	.color3a7cf6{
+		color: #58ba73;
+	}
+	
+	.foot-btn{
+		margin-top: 80rpx;
+	}
+	.recharge {
+		padding:0 30rpx 30rpx 30rpx;
+		//background-color: #1677FF;
+		background-color: #fff;
+		margin-bottom: 20rpx;
+
+		.recharge-text {
+			font-size: 36rpx;
+			padding:12rpx;
+			width: 100%;
+			display: flex;
+			align-items: center;
+			border-bottom: 1px solid #eeeeee;
+
+			.recharge-title {
+				width: 30%;
+				    color: rgb(96, 98, 102);
+			}
+		}
+
+	}
+</style>