|
@@ -1,5 +1,11 @@
|
|
|
<template>
|
|
<template>
|
|
|
<view>
|
|
<view>
|
|
|
|
|
+ <u-modal :mask-close-able="true" confirm-text="确定提现" @confirm="confirm" v-model="passwordShow" title="提示">
|
|
|
|
|
+ <view class="slot-content" style="padding: 20rpx;">
|
|
|
|
|
+ <u-input v-model="withdrawPassword" placeholder="请填写提现密码" type="password" />
|
|
|
|
|
+ </view>
|
|
|
|
|
+ </u-modal>
|
|
|
|
|
+
|
|
|
<view class="bg-img flex justify-center align-center" style="background-image: url('https://upload-file-data.obs.cn-south-1.myhuaweicloud.com/97d63ec49f544a33a6a8cc3c0b64b17a-songRankBgImg.png');height: 302upx;">
|
|
<view class="bg-img flex justify-center align-center" style="background-image: url('https://upload-file-data.obs.cn-south-1.myhuaweicloud.com/97d63ec49f544a33a6a8cc3c0b64b17a-songRankBgImg.png');height: 302upx;">
|
|
|
<view class="text-white" >
|
|
<view class="text-white" >
|
|
|
<text class="text-lg">提现金额:</text>
|
|
<text class="text-lg">提现金额:</text>
|
|
@@ -27,13 +33,11 @@
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
<view class="" style="height: 140rpx;"></view>
|
|
<view class="" style="height: 140rpx;"></view>
|
|
|
- <view class="footer-fixed flex align-center justify-between padding bg-white" style="border-top: 1rpx solid #e5e5e5;z-index: 9;">
|
|
|
|
|
- <view class="flex align-center" style="width: 60%;">
|
|
|
|
|
- <view>提现密码:</view>
|
|
|
|
|
- <u-input v-model="password" type="password" :password-icon="true" placeholder="请输入提现密码" :clearable="false" />
|
|
|
|
|
- </view>
|
|
|
|
|
|
|
+ <view
|
|
|
|
|
+ class="footer-fixed flex align-center justify-end padding bg-white"
|
|
|
|
|
+ style="padding: 30rpx;;border-top: 1rpx solid #e5e5e5;z-index: 9;">
|
|
|
<button class="cu-btn round text-white theme-bg-color" style="width: 180upx;height: 80upx;"
|
|
<button class="cu-btn round text-white theme-bg-color" style="width: 180upx;height: 80upx;"
|
|
|
- @click="withdraw">确认提现</button>
|
|
|
|
|
|
|
+ @click="withdraw">提现</button>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
</template>
|
|
</template>
|
|
@@ -62,10 +66,11 @@
|
|
|
},
|
|
},
|
|
|
data() {
|
|
data() {
|
|
|
return {
|
|
return {
|
|
|
- password: '',
|
|
|
|
|
userId:'',
|
|
userId:'',
|
|
|
list:[],
|
|
list:[],
|
|
|
- withdrawList:[]
|
|
|
|
|
|
|
+ withdrawList:[],
|
|
|
|
|
+ withdrawPassword:'',
|
|
|
|
|
+ passwordShow:false
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
onLoad(options) {
|
|
onLoad(options) {
|
|
@@ -97,13 +102,22 @@
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
withdraw(){
|
|
withdraw(){
|
|
|
|
|
+ this.passwordShow=true
|
|
|
|
|
+ },
|
|
|
|
|
+ confirm(){
|
|
|
|
|
+ if (this.$u.test.isEmpty(this.withdrawPassword)) {
|
|
|
|
|
+ this.$u.toast("请填写提现密码")
|
|
|
|
|
+ return
|
|
|
|
|
+ }
|
|
|
if (this.total<=0) {
|
|
if (this.total<=0) {
|
|
|
this.$u.toast("请输入正确的兑换金额")
|
|
this.$u.toast("请输入正确的兑换金额")
|
|
|
return
|
|
return
|
|
|
}
|
|
}
|
|
|
- this.$u.api.user.withdraw(this.withdrawList).then(res=>{
|
|
|
|
|
- if (res) {
|
|
|
|
|
- this.$dialog.showModal(res+",请耐心等待",false).then(res=>{
|
|
|
|
|
|
|
+ this.$u.api.user.withdraw(this.withdrawList,md5Libs.md5(this.withdrawPassword)).then(res=>{
|
|
|
|
|
+ if (res.code==400) {
|
|
|
|
|
+ this.$dialog.showModal(res.msg,false)
|
|
|
|
|
+ }else{
|
|
|
|
|
+ this.$dialog.showModal(res,false).then(res=>{
|
|
|
uni.navigateBack({
|
|
uni.navigateBack({
|
|
|
delta:1
|
|
delta:1
|
|
|
})
|
|
})
|