征信小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
zhengxinApplets/pages/user/withdrawal.vue

244 lines
5.1 KiB

3 months ago
<template>
<view class="site">
<view class="site-bd">
<view class="item">
<view class="a">提现至</view>
<view class="b">
3 months ago
<image src="https://zhengxin.njrenzhou.cn/static/icon-card.png"></image>
3 months ago
银行卡
</view>
</view>
</view>
<view class="site-bd">
<view class="item">
<view class="a">持卡人</view>
<view class="b">
3 months ago
<input v-model="cardname" type="text" placeholder="请输入持卡人姓名" />
3 months ago
</view>
</view>
<view class="item">
<view class="a">卡号</view>
<view class="b">
3 months ago
<input v-model="cardno" type="text" placeholder="请填写卡号" />
3 months ago
</view>
</view>
<view class="item">
<view class="a">支行信息</view>
<view class="b">
3 months ago
<input v-model="address" type="text" placeholder="请输入支行信息" />
3 months ago
</view>
</view>
<view class="item">
<view class="a">提现</view>
<view class="b">
3 months ago
<input v-model="money" type="text" placeholder="最低提现金额0" />
3 months ago
</view>
</view>
<view class="items">
3 months ago
当前可提现金额<text>{{userInfo.money}}</text>
3 months ago
</view>
</view>
<view class="site-bd">
<view class="title">提现说明</view>
<view class="desc">
<text>1单次最低提现100元最高提现1000元\n2每日最多可提现次数不限每日最多提现金额()不限\n3每笔收取提现手续 3%\n4提现结果请查收对应渠道服务通知\n5如有疑问请及时联系客服</text>
</view>
</view>
3 months ago
<view class="btn" @click="toSubmit()">提现</view>
3 months ago
<view class="history" @click="openPage()">提现记录</view>
</view>
</template>
<script>
export default {
data() {
return {
3 months ago
userInfo: {},
cardname: "",
cardno: "",
address: "",
money: ""
3 months ago
};
},
onShow() {
3 months ago
this.getUserInfo();
3 months ago
},
methods: {
3 months ago
//获取用户信息
async getUserInfo() {
const { code, data , msg } = await this.$api.getMemberInfo({token: uni.getStorageSync("token")});
if(code == 1){
this.userInfo = data.user;
}else{
uni.showToast({
title: msg,
icon: "none",
})
}
},
3 months ago
openPage() {
uni.navigateTo({
url: "/pages/user/verificationList"
})
},
async toSubmit() {
3 months ago
if (!this.cardname) {
3 months ago
uni.showToast({
3 months ago
title: '请输入持卡人姓名',
3 months ago
icon: 'none',
})
return
}
3 months ago
if (!this.cardno) {
3 months ago
uni.showToast({
3 months ago
title: '请填写卡号',
3 months ago
icon: 'none',
})
return
}
3 months ago
if (!this.address) {
3 months ago
uni.showToast({
3 months ago
title: '请输入支行信息',
3 months ago
icon: 'none',
})
return
}
3 months ago
if (!this.money) {
uni.showToast({
title: '请输入提现金额',
icon: 'none',
})
return
}
if (this.money<=0) {
uni.showToast({
title: '最低提现金额0',
icon: 'none',
})
return
}
const { code, data, message } = await this.$api.settixianmomey({
token: uni.getStorageSync("token"),
type: 1,
cardname: this.cardname,
cardno: this.cardno,
address: this.address,
money: this.money
3 months ago
});
3 months ago
if(code == 1){
3 months ago
uni.showToast({
title: "提交成功"
})
setTimeout(()=>{
3 months ago
this.openPage();
3 months ago
},1000)
}
3 months ago
}
3 months ago
}
}
</script>
<style lang="scss" scoped>
.site{
padding: 0 25rpx 25rpx;
overflow: hidden;
.btn{
width: 702rpx;
line-height: 90rpx;
background: #00C6A9;
box-shadow: 0px 3rpx 10rpx 0px rgba(9,44,39,0.05);
border-radius: 90rpx;
text-align: center;
font-weight: 500;
font-size: 30rpx;
color: #FFFFFF;
margin: 0 auto;
margin-top: 120rpx;
}
.history{
text-align: center;
font-weight: 500;
font-size: 30rpx;
margin-top: 40rpx;
color: #00C6A9;
}
&-bd{
width: 100%;
background: #FFFFFF;
box-shadow: 0px 3rpx 10rpx 0px rgba(9,44,39,0.05);
border-radius: 20rpx;
margin: 0 auto;
padding: 0 30rpx;
box-sizing: border-box;
position: relative;
margin-top: 20rpx;
.title{
padding: 35rpx 0;
font-weight: 400;
font-size: 30rpx;
color: #09090B;
}
.desc{
font-weight: 400;
font-size: 24rpx;
color: #999999;
line-height: 42rpx;
padding-bottom: 30rpx;
}
.items{
display: flex;
align-items: center;
border-top: 1px solid #EAEAEA;
padding: 35rpx 0;
overflow: hidden;
position: relative;
font-weight: 500;
font-size: 30rpx;
color: #999999;
text{
color: #D80C0C;
}
}
.item{
display: flex;
align-items: center;
justify-content: space-between;
border-top: 1px solid #EAEAEA;
padding: 35rpx 0;
overflow: hidden;
position: relative;
&:first-child{
border-color: #FFFFFF;
}
.a{
width: 160rpx;
display: flex;
align-items: center;
font-weight: 500;
font-size: 30rpx;
color: #222222;
}
.b{
flex: 1;
display: flex;
align-items: center;
font-weight: 500;
font-size: 30rpx;
color: #333333;
input{
flex: 1;
font-weight: 500;
font-size: 30rpx;
color: #999999;
}
image{
width: 42rpx;
height: 28rpx;
margin-right: 20rpx;
}
}
}
}
}
</style>