no message

This commit is contained in:
2025-11-11 10:35:43 +08:00
parent a415522359
commit 83a7d6ef3c
16 changed files with 948 additions and 103 deletions
+26 -97
View File
@@ -1,27 +1,21 @@
<template>
<view class="content">
<TopSafe bgColor="rgba(0,0,0,0)"></TopSafe>
<Header title="账户管理" bgColor="rgba(0,0,0,0)" />
<Header bgColor="rgba(0,0,0,0)" />
<view class="setting-view">
<view class="tab-view">
<view class="tab-list" v-for="(item,index) in tabList" :key="index" @click="onTab(index)">
<text class="text-fu text-28" :style="{color:type == index ? '#7934F6' :'#666' }">{{item}}</text>
<view class="tab-line" v-if="type == index"></view>
</view>
</view>
<view class="mid-view">
<AccountItem :type="type" :itemData="item" @ok="onItemOk" v-for="(item,index) in dataList" :key="index"></AccountItem>
</view>
<u-icon size="54" name="checkmark-circle-fill" style="margin-top:84rpx" color="#7934F6" ></u-icon>
<text class="text-zu text-32 mt-24">提现成功 ¥{{money || 0}}</text>
<text class="text-fu1 text-28 mt-24" style="text-align: center;">由于第三方结算原因,提现成功后可能存在一定延迟请关注提现账户变动情况~</text>
</view>
<view class="bottom-btn">
<MyBtn :text="type == 0 ? '添加支付宝账户' : '添加微信账户'" @ok="onJump"></MyBtn>
<MyBtn text="好的我知道了" @ok="onAdd"></MyBtn>
</view>
<up-toast ref="uToastRef"></up-toast>
</view>
</template>
<script>
import { getWithdraw,unbindWithdraw } from '@/api/common.js';
import { bindWithdraw } from '@/api/common.js';
import Header from '@/components/common/header.vue';
import { clear } from '@/utils/auth.js';
import TopSafe from '@/components/common/top-safe.nvue'
@@ -33,76 +27,18 @@ export default {
components: { Header, TopSafe,MyBtn,AccountItem },
data() {
return {
type:0,
tabList:['支付宝账户','微信账户'],
dataList:[]
money:''
};
},
onLoad(option){
if(option.id){
this.type = option.id == '1' ? 0 : 1;
onLoad(option) {
if(option && option.money){
this.money = Number(option.money);
}
},
onShow() {
this.init();
// this.userinfo();
},
methods: {
init() {
// this.userinfo()
// #ifdef WEB
this.tabList = ['支付宝账户'];
// #endif
this.getList();
},
onItemOk(item){
let params = {
bindId:item.id
}
unbindWithdraw(params).then(res=>{
if (res.bizcode === 100) {
this.$refs.uToastRef.show({
type: 'success',
message:'解绑成功',
});
this.init();
return null;
} else {
this.$refs.uToastRef.show({
type: 'error',
message: res.msg,
});
return null;
}
})
},
getList(){
getWithdraw({platform:this.type == 0?1:2}).then(res=>{
if (res.bizcode === 100) {
this.dataList = res.data;
this.dataList.forEach(item=>{
item.name = item.accountName;
item.account = item.accountNumber;
})
} else {
this.$refs.uToastRef.show({
type: 'error',
message: res.msg,
});
return null;
}
})
},
onTab(index){
if(index != this.type){
this.type = index;
this.init();
}
},
onJump(){
uni.navigateTo({
url:`/pages/rwa_package/account/bind?type=${this.type}`
})
onAdd(){
uni.navigateBack()
}
}
}
@@ -132,34 +68,27 @@ export default {
position: relative;
.mid-view{
width:100%;
height:calc(100% - 88rpx);
display: flex;
flex-direction: column;
overflow-y: auto;
padding-bottom: 24rpx;
box-sizing: border-box;
}
.tab-view{
width:100%;
height:88rpx;
display: flex;
flex-direction: row;
// align-items: center;
.tab-list{
margin-right:32rpx;
height:55rpx;
background-color: #fff;
border-radius: 16rpx;
padding: 48rpx 32rpx;
margin-top:24rpx;
.input-view{
width:100%;
height:100rpx;
background-color: #f5f5f5;
border-radius: 20rpx;
margin-top:32rpx;
display: flex;
flex-direction: column;
flex-direction: row;
align-items: center;
justify-content: space-between;
.tab-line{
width:50rpx;
height:4rpx;
min-height:4rpx;
background-color: #7934F6;
}
}
}
}
</style>