first commit

This commit is contained in:
PC-202306242200\Administrator
2026-03-28 23:09:02 +08:00
commit dac42e3b0c
3512 changed files with 181637 additions and 0 deletions

137
pages/mine/addBankCard.vue Normal file
View File

@@ -0,0 +1,137 @@
<template>
<view class="addBankCard p30">
<view style="height: 30rpx"></view>
<view>
<view class="addBankCard_input_tit">请输入{{ enterprise.type == 1 ? '姓名' : '企业名称' }}</view>
<view class="addBankCard_input">
<up-input :border="false" placeholder="请输入" v-model="enterprise.name"></up-input>
</view>
<!-- <view v-if="enterprise.type == 2">
<view class="addBankCard_input_tit">请输入纳税人识别号</view>
<view class="addBankCard_input">
<up-input :border="false" placeholder="请输入" v-model="enterprise.taxNo"></up-input>
</view>
</view> -->
<view v-if="enterprise.type == 1">
<view class="addBankCard_input_tit">请输入手机号</view>
<view class="addBankCard_input">
<up-input :border="false" placeholder="请输入" v-model="enterprise.phone"></up-input>
</view>
</view>
<view v-if="enterprise.type == 1">
<view class="addBankCard_input_tit">请输入身份证号</view>
<view class="addBankCard_input">
<up-input :border="false" placeholder="请输入" v-model="enterprise.idCard"></up-input>
</view>
</view>
<!--
<view class="addBankCard_input_tit">请输入开户行名称</view>
<view class="addBankCard_input">
<up-input :border="false" placeholder="请输入" v-model="enterprise.bankName"></up-input>
</view> -->
<view class="addBankCard_input_tit" v-if="enterprise.type == 2">请输入开户行</view>
<view class="addBankCard_input" v-if="enterprise.type == 2">
<up-input :border="false" placeholder="请输入" v-model="enterprise.subbranchName"></up-input>
</view>
<view class="addBankCard_input_tit">请输入银行卡卡号</view>
<view class="addBankCard_input">
<up-input :border="false" placeholder="请输入" v-model="enterprise.bankCard"></up-input>
</view>
</view>
<view style="margin: 30rpx 0">
<view style="font-size: 28rpx; color: coral">请仔细核对信息填写错误会导致提现失败</view>
</view>
<view style="display: flex; justify-content: center">
<view class="addBankCard_btn" @click="addBank">确定</view>
</view>
</view>
</template>
<script setup>
import { reactive, ref } from 'vue';
import { onLoad } from '@dcloudio/uni-app';
import { addUsersAccountInfo, smsCode } from '@/api/api.js';
let tips = ref('');
let uCode = ref(null);
let codeChange2 = (text) => {
tips.value = text;
};
let enterprise = reactive({
type: 1
});
onLoad((options) => {
enterprise.type = options.type;
});
let getCode2 = () => {
if (!enterprise.phone) return uni.showToast({ title: '请输入手机号', icon: 'none' });
if (uCode.value.canGetCode) {
// 模拟向后端请求验证码
uni.showLoading({
title: '正在获取验证码'
});
smsCode({
phone: enterprise.phone
}).then((res) => {
uni.hideLoading();
uni.$u.toast('验证码已发送');
uCode.value.start();
});
} else {
uni.$u.toast('倒计时结束后再发送');
}
};
let addBank = async () => {
if (enterprise.type == 2) {
enterprise.taxNo = '';
enterprise.bankName = ''
}else{
enterprise.bankName = ''
}
let _res = await addUsersAccountInfo(enterprise);
uni.showToast({ title: '添加成功', icon: 'none' });
setTimeout(() => {
uni.navigateBack();
}, 1500);
};
</script>
<style scoped lang="scss">
.addBankCard {
// @include flex();
&_input {
width: 690rpx;
height: 70rpx;
background: #ffffff;
border-radius: 8rpx 8rpx 8rpx 8rpx;
@include flex;
margin-bottom: 30rpx;
padding: 0 30rpx;
&_tit {
width: 100%;
font-weight: bold;
font-size: 26rpx;
color: #232323;
margin-bottom: 20rpx;
}
}
&_btn {
width: 488rpx;
height: 86rpx;
background: #4874e5;
border-radius: 44rpx 44rpx 44rpx 44rpx;
@include flex($space: center);
font-weight: bold;
font-size: 28rpx;
color: #ffffff;
}
}
</style>

126
pages/mine/bankCard.vue Normal file
View File

@@ -0,0 +1,126 @@
<template>
<view class="bankCard">
<z-paging ref="paging" v-model="dataList" @query="queryList">
<view class="p30">
<view class="bankCard_add" @click="addBank">
<up-icon name="plus" color="#333" size="28"></up-icon>
<view style="font-size: 26rpx; color: #333; margin-top: 15rpx">添加银行卡</view>
</view>
</view>
<view style="height: 30rpx"></view>
<view v-for="(item, index) in dataList" :key="index" @click="bankSele(item)">
<view class="p30">
<view style="background-color: #ffffff; border-radius: 12rpx; padding: 20rpx; margin-bottom: 20rpx">
<view class="u-flex u-flex-y-center" style="font-size: 28rpx">
<view>
<u-tag :text="item.type == 1 ? '个人' : '企业'" size="mini" :type="item.type == 1 ? 'success' : 'error'" plain plainFill></u-tag>
</view>
<view style="width: 30rpx"></view>
<view style="font-size: 26rpx">{{ item.name }}</view>
<view style="width: 30rpx"></view>
<view style="font-size: 26rpx">{{ item.phone || '' }}</view>
</view>
<view style="height: 20rpx"></view>
<view style="color: #232323">
<!-- <view style="font-size: 28rpx">开户行{{ item.bankName }}</view>
<view style="height: 10rpx"></view> -->
<view style="font-size: 28rpx" v-if="item.type == 2">开户行{{ item.subbranchName }}</view>
<view style="height: 10rpx"></view>
<view style="font-size: 28rpx">银行卡号{{ item.bankCard }}</view>
<view style="height: 10rpx"></view>
<!-- <view style="font-size: 28rpx" v-if="item.type == 2 && item.taxNo">纳税人识别号{{ item.taxNo}}</view>
<view style="height: 10rpx"></view> -->
</view>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script setup>
import { reactive, ref } from 'vue';
import { getUsersAccountInfo } from '@/api/api.js';
import { onShow, onLoad } from '@dcloudio/uni-app';
const paging = ref(null);
let dataList = ref([]);
let numiNDE = ref(1);
let type = ref('');
onShow(() => {
if (numiNDE.value != 1) {
paging.value.reload();
}
numiNDE.value++;
});
onLoad((options) => {
type.value = options.type;
});
let addBank = () => {
uni.showActionSheet({
itemList: ['个人', '企业'],
success: (res) => {
if(res.tapIndex + 1 == 0){
console.log('选中了第' + (res.tapIndex + 1) + '个按钮');
}else{
uni.navigateTo({
url: `/pages/mine/addBankCard?type=${res.tapIndex + 1}`
});
}
},
fail: function (res) {
console.log(res.errMsg);
}
});
};
const queryList = (pageNo, pageSize) => {
const params = {
current: pageNo,
pageSize: pageSize
};
getUsersAccountInfo(params)
.then((res) => {
paging.value.complete(res);
})
.catch((res) => {
paging.value.complete(false);
});
};
function maskCardNumber(cardNumber) {
if (!cardNumber || typeof cardNumber !== 'string') {
throw new Error('Invalid card number');
}
const sanitizedNumber = cardNumber.replace(/\D/g, '');
if (sanitizedNumber.length < 4) {
throw new Error('Card number is too short');
}
const lastFourDigits = sanitizedNumber.slice(-4);
const maskedNumber = '*'.repeat(sanitizedNumber.length - 4) + lastFourDigits;
return maskedNumber;
}
let bankSele = (e) => {
if (type.value) {
uni.$emit('bank', e);
uni.navigateBack();
}
};
</script>
<style scoped lang="scss">
.bankCard {
&_add {
width: 690rpx;
height: 174rpx;
background: #eeeeee;
border-radius: 16rpx 16rpx 16rpx 16rpx;
@include flex($direction: column, $space: center);
margin-top: 30rpx;
}
}
</style>

163
pages/mine/incomeList.vue Normal file
View File

@@ -0,0 +1,163 @@
<template>
<view class="earnings p30">
<z-paging ref="paging" v-model="dataList" use-page-scroll @query="queryList">
<view class="mt30 wallet_list" v-for="(item, index) in dataList" :key="index">
<view class="wallet_list_left">
<view>{{ item.recordName || '-' }}</view>
<view>{{ item.createTime }}</view>
</view>
<view class="wallet_list_right" style="display: flex; flex-direction: column; align-items: flex-end">
<view style="margin-bottom: 10rpx; width: 130rpx">
<view></view>
<up-tag v-if="item.pointType == 2" size="mini" text="增值收益" type="warning" plain plainFill></up-tag>
<up-tag v-if="item.pointType == 1" size="mini" text="基础收益" plain plainFill></up-tag>
</view>
<view>{{ item.amount }}</view>
</view>
</view>
</z-paging>
</view>
</template>
<script setup>
import { reactive, ref, computed } from 'vue';
import { onPullDownRefresh, onPageScroll, onReachBottom } from '@dcloudio/uni-app';
import { timeFormat } from '@/uni_modules/uview-plus';
import { getUsersPointRecord } from '@/api/api.js';
import { onLoad, onShow } from '@dcloudio/uni-app';
import { useNav } from '@/hooks/useNav.js';
import moneyJson from '@/common/money.json';
let range = computed(() => {
return moneyJson.map((item, index) => {
return {
text: item.name,
value: item.id
};
});
});
const changeSele = (e) => {
paging.value.reload();
};
const { nav, navTo } = useNav();
let getInfo = ref({});
const paging = ref(null);
let dataList = ref([]);
let dataFrom = reactive({
type: ''
});
let isPagingRefNotFound = () => {
return !paging.value;
};
let result = (e) => {
console.log(e);
};
onPullDownRefresh(() => {
if (isPagingRefNotFound()) return;
paging.value.reload().catch(() => {});
});
onPageScroll((e) => {
if (isPagingRefNotFound()) return;
paging.value.updatePageScrollTop(e.scrollTop);
e.scrollTop < 10 && paging.value.doChatRecordLoadMore();
});
onReachBottom(() => {
if (isPagingRefNotFound()) return;
paging.value.pageReachBottom();
});
const queryList = (pageNo, pageSize) => {
const params = {
current: pageNo,
pageSize: pageSize,
...dataFrom
};
getUsersPointRecord(params)
.then((res) => {
paging.value.complete(res);
})
.catch((res) => {
paging.value.complete(false);
});
};
</script>
<style scoped lang="scss">
.wallet_pall {
width: 690rpx;
height: 272rpx;
border-radius: 16rpx 16rpx 16rpx 16rpx;
padding: 40rpx;
background: #ffffff;
&_header {
font-weight: bold;
font-size: 26rpx;
color: #002ea4;
}
&_ye {
display: flex;
align-items: center;
justify-content: space-between;
height: 70%;
view:nth-child(1) {
font-weight: bold;
font-size: 68rpx;
color: #002ea4;
}
view:nth-child(2) {
width: 128rpx;
height: 58rpx;
background: rgba(0, 46, 164, 0.07);
border-radius: 32rpx 32rpx 32rpx 32rpx;
display: flex;
align-items: center;
justify-content: center;
font-size: 26rpx;
color: #002ea4;
}
}
}
.wallet_list {
width: 690rpx;
// height: 120rpx;
background: #ffffff;
border-radius: 8rpx 8rpx 8rpx 8rpx;
padding: 15rpx 30rpx;
@include flex($space: space-between);
&_left {
view:nth-child(1) {
font-weight: bold;
font-size: 28rpx;
color: #232323;
margin-bottom: 10rpx;
}
view:nth-child(2) {
font-size: 24rpx;
color: #232323;
}
view:nth-child(3) {
font-size: 24rpx;
color: #232323;
}
view:nth-child(4) {
font-size: 24rpx;
color: #232323;
}
}
&_right {
font-weight: bold;
font-size: 28rpx;
color: #ff2727;
}
}
</style>

176
pages/mine/piles.vue Normal file
View File

@@ -0,0 +1,176 @@
<template>
<view class="p30 piles">
<z-paging ref="paging" v-model="dataList" use-page-scroll @query="queryList">
<!-- <view class="piles_card">
<view class="piles_card_title">充电桩汇总</view>
<view class="piles_card_view">
<view>
<text>{{ count.installCount || 0 }}</text>
<text>已安装</text>
</view>
<view>
<text>{{ count.installNotCount || 0 }}</text>
<text>未安装数量</text>
</view>
</view>
</view>
<up-subsection :list="list" keyName="name" :current="current" @change="upChange"></up-subsection> -->
<view class="order_view" v-for="i in dataList" :key="i">
<view class="piles_list">
<view class="piles_list_title">电站名称{{ i.stationName || '-' }}</view>
<view class="piles_list_view">
<view>设备号</view>
<view>{{ i.deviceNo }}</view>
</view>
<view class="piles_list_view">
<view>设备功率</view>
<view>{{ i.deviceType }}KW</view>
</view>
<view class="piles_list_view">
<view>设备类型</view>
<view>{{ i.deviceTypeName }}</view>
</view>
<view class="piles_list_view">
<view>创建时间</view>
<view>{{ timeFormat(new Date(i.createTime).getTime(), 'yyyy-mm-dd hh:MM') }}</view>
</view>
</view>
</view>
</z-paging>
</view>
</template>
<script setup>
import { getDeviceInfo, getDeviceCount } from '@/api/api.js';
import { reactive, ref } from 'vue';
import { onPullDownRefresh, onPageScroll, onReachBottom, onLoad } from '@dcloudio/uni-app';
import { timeFormat } from '@/uni_modules/uview-plus';
const paging = ref(null);
let dataList = ref([]);
let dataFrom = reactive({
deviceStatus: 1
});
let count = ref({});
// onLoad(async () => {
// count.value = await getDeviceCount();
// });
let isPagingRefNotFound = () => {
return !paging.value;
};
onPullDownRefresh(() => {
if (isPagingRefNotFound()) return;
paging.value.reload().catch(() => {});
});
onPageScroll((e) => {
if (isPagingRefNotFound()) return;
paging.value.updatePageScrollTop(e.scrollTop);
e.scrollTop < 10 && paging.value.doChatRecordLoadMore();
});
onReachBottom(() => {
if (isPagingRefNotFound()) return;
paging.value.pageReachBottom();
});
const queryList = (pageNo, pageSize) => {
const params = {
current: pageNo,
pageSize: pageSize,
...dataFrom
};
getDeviceInfo(params)
.then((res) => {
paging.value.complete(res);
})
.catch((res) => {
paging.value.complete(false);
});
};
const list = ref([
{
name: '已安装',
id: 1
},
{
name: '待安装',
id: 0
}
]);
const current = ref(0);
const upChange = (e) => {
current.value = e;
dataFrom.deviceStatus = list.value[e].id;
paging.value.reload();
};
</script>
<style scoped lang="scss">
.piles {
&_card {
width: 690rpx;
height: 192rpx;
background: linear-gradient(179deg, #4874e5 0%, #3864d6 100%);
border-radius: 8rpx 8rpx 0rpx 0rpx;
padding: 30rpx;
&_title {
font-weight: bold;
font-size: 28rpx;
color: #ffffff;
margin-bottom: 20rpx;
}
&_view {
padding: 0 150rpx;
flex-direction: column;
@include flex($space: space-between);
view {
@include flex($direction: column, $space: space-between);
text:nth-child(1) {
font-weight: bold;
font-size: 32rpx;
color: #ffffff;
margin-bottom: 15rpx;
}
text:nth-child(2) {
font-size: 26rpx;
color: #ffffff;
}
}
}
}
&_list {
padding: 25rpx;
width: 690rpx;
background: #ffffff;
border-radius: 16rpx 16rpx 16rpx 16rpx;
margin-top: 30rpx;
&_title {
font-weight: bold;
font-size: 28rpx;
color: #232323;
}
&_view {
@include flex;
color: #555555;
font-size: 28rpx;
margin-top: 15rpx;
view:nth-child(2) {
font-weight: bold;
font-size: 28rpx;
color: #232323;
}
text {
color: #ff2727;
}
}
}
}
</style>

251
pages/mine/withdraw.vue Normal file
View File

@@ -0,0 +1,251 @@
<template>
<view class="withdraw p30">
<!-- #ifdef MP-ALIPAY -->
<view style="height: 30rpx;"></view>
<!-- #endif -->
<view class="withdraw_k" @click="toNav">
<view class="withdraw_k_tit">提现到</view>
<view class="withdraw_k_input">请选择银行卡</view>
<image class="withdraw_k_img" src="/static/icon/xia.png"></image>
</view>
<view v-if="bank">
<view style="background-color: #ffffff; border-radius: 12rpx; padding: 20rpx; margin-bottom: 20rpx">
<view class="u-flex u-flex-y-center" style="font-size: 28rpx">
<view>
<u-tag :text="bank.type == 1 ? '个人' : '企业'" size="mini" :type="bank.type == 1 ? 'success' : 'error'" plain plainFill></u-tag>
</view>
<view style="width: 30rpx"></view>
<view style="font-size: 26rpx">{{ bank.name }}</view>
<view style="width: 30rpx"></view>
<view style="font-size: 26rpx">{{ bank.phone || '' }}</view>
</view>
<view style="height: 20rpx"></view>
<view style="color: #232323">
<!-- <view style="font-size: 28rpx">开户行{{ bank.bankName }}</view>
<view style="height: 10rpx"></view> -->
<view style="font-size: 28rpx" v-if="bank.type == 2">开户行{{ bank.subbranchName }}</view>
<view style="height: 10rpx"></view>
<view style="font-size: 28rpx">银行卡号{{ bank.bankCard }}</view>
<view style="height: 10rpx"></view>
<!-- <view style="font-size: 28rpx" v-if="bank.type == 2">纳税人识别号{{ bank.taxNo ? maskCardNumber(bank.taxNo) : '' }}</view>
<view style="height: 10rpx"></view> -->
</view>
</view>
</view>
<view class="withdraw_mon">
<view class="withdraw_mon_tit">提现金额</view>
<view class="withdraw_mon_input">
<view class="withdraw_mon_input_fu"></view>
<view>
<up-input fontSize="36rpx" placeholder="请输入金额" :border="false" v-model="dataFrom.amount"></up-input>
</view>
<view class="withdraw_mon_input_note" @click="dataFrom.amount = getInfo.balance">全部提现</view>
</view>
<view>
<up-input :border="false" disabled v-model="getInfo.phone"></up-input>
</view>
<view class="withdraw_mon_input">
<up-input placeholder="请输入验证码" :border="false" v-model="dataFrom.smsCode"></up-input>
<view style="width: 250rpx">
<up-code ref="uCode" @change="codeChange2" keep-running start-text="点我获取验证码"></up-code>
<up-button @click="getCode" color="#4874e5">{{ tips }}</up-button>
</view>
</view>
<view class="withdraw_mon_note">可提现金额{{ getInfo.balance }}</view>
</view>
<!-- <view class="withdraw_note">
<view class="withdraw_note_tit" style="font-weight: bold; font-size: 26rpx">提现规则</view>
<view class="withdraw_note_s">1.每月1号1121号可提现到账时间T+1</view>
<view class="withdraw_note_s">2.提现年龄是18-65</view>
<view class="withdraw_note_s">3.提现银行卡是常用的一类银行否则会有限额</view>
<view class="withdraw_note_s">4.一月不能超{{ appConfig.monthQuota }}如遇超出 提现后管理人员会联系您</view>
<view class="withdraw_note_s">5.提现次数不限公户无限额无手续费</view>
</view> -->
<view style="height: 50rpx"></view>
<view style="display: flex; justify-content: center; margin-top: 80rpx">
<view class="affirm_btn" @click="payOrder">立即提现</view>
</view>
<view style="height: 50rpx"></view>
</view>
</template>
<script setup>
import { ref, reactive } from 'vue';
import { operatorInfo, getAppConfig, smsCode, userExtract } from '@/api/api.js';
import { onLoad, onShow } from '@dcloudio/uni-app';
let value = ref();
let getInfo = ref({});
let tips = ref('');
let uCode = ref(null);
let dataFrom = reactive({
amount: '',
smsCode: '',
accountId: ''
});
let bank = ref();
onLoad(async () => {
let _res = await operatorInfo();
getInfo.value = _res;
uni.$on('bank', (e) => {
bank.value = e;
dataFrom.accountId = e.id;
console.log(e);
});
});
let toNav = () => {
uni.navigateTo({
url: '/pages/mine/bankCard?type=xz'
});
};
let codeChange2 = (text) => {
tips.value = text;
};
let getCode = () => {
console.log(123456);
if (!getInfo.value.phone) return uni.showToast({ title: '请输入手机号', icon: 'none' });
if (uCode.value.canGetCode) {
// 模拟向后端请求验证码
uni.showLoading({
title: '正在获取验证码'
});
smsCode({
phone: getInfo.value.phone
}).then((res) => {
uni.hideLoading();
uni.$u.toast('验证码已发送');
uCode.value.start();
});
} else {
uni.$u.toast('倒计时结束后再发送');
}
};
function maskCardNumber(cardNumber) {
if (!cardNumber || typeof cardNumber !== 'string') {
throw new Error('Invalid card number');
}
const sanitizedNumber = cardNumber.replace(/\D/g, '');
if (sanitizedNumber.length < 4) {
throw new Error('Card number is too short');
}
const lastFourDigits = sanitizedNumber.slice(-4);
const maskedNumber = '*'.repeat(sanitizedNumber.length - 4) + lastFourDigits;
return maskedNumber;
}
let payOrder = async () => {
if (Number(getInfo.value.balance) < Number(dataFrom.amount)) return uni.showToast({ title: '可提现金额不足', icon: 'none' });
if (!dataFrom.accountId) return uni.showToast({ title: '请先选择提现银行卡', icon: 'none' });
if (!dataFrom.amount) return uni.showToast({ title: '请输入提现金额', icon: 'none' });
if (!dataFrom.smsCode) return uni.showToast({ title: '请输入验证码', icon: 'none' });
let _res = await userExtract(dataFrom);
uni.showModal({
title: '提示',
content: '提交成功',
showCancel: false,
success() {
uni.navigateBack();
}
});
};
</script>
<style scoped lang="scss">
.withdraw {
&_k {
width: 100%;
height: 74rpx;
padding: 0 20rpx;
background: #ffffff;
border-radius: 8rpx 8rpx 8rpx 8rpx;
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 30rpx;
&_tit {
font-weight: bold;
font-size: 24rpx;
color: #232323;
margin-right: 100rpx;
}
&_input {
flex: 1;
text-align: right;
font-size: 28rpx;
}
&_img {
width: 44rpx;
height: 44rpx;
}
}
&_mon {
padding: 20rpx;
background: #ffffff;
border-radius: 8rpx 8rpx 8rpx 8rpx;
&_tit {
font-weight: bold;
font-size: 24rpx;
color: #232323;
}
&_input {
display: flex;
align-items: center;
justify-content: space-between;
border-bottom: 2rpx solid #cccccc;
padding: 15rpx 0;
margin-bottom: 20rpx;
&_fu {
font-weight: bold;
font-size: 66rpx;
color: #232323;
}
&_note {
font-weight: bold;
font-size: 24rpx;
color: #ff7777;
}
}
&_note {
font-weight: 400;
font-size: 24rpx;
color: #232323;
margin-bottom: 10rpx;
}
}
&_note {
margin-top: 30rpx;
padding: 0 15rpx;
view {
margin-bottom: 15rpx;
font-weight: 400;
font-size: 26rpx;
color: #232323;
line-height: 40rpx;
}
}
}
.affirm_btn {
width: 650rpx;
height: 78rpx;
background: #4874e5;
border-radius: 12rpx;
display: flex;
align-items: center;
justify-content: center;
font-weight: bold;
font-size: 24rpx;
color: #ffffff;
}
</style>

156
pages/mine/z.vue Normal file
View File

@@ -0,0 +1,156 @@
<template>
<view class="earnings p30">
<z-paging ref="paging" v-model="dataList" use-page-scroll @query="queryList">
<view class="mt30 wallet_list" v-for="(item, index) in dataList" :key="index">
<view class="wallet_list_left">
<view>{{ item.type == 1 ? '提现人' : '提现公司' }}{{ item.name }}</view>
<!-- <view>银行名称{{ item.bankName }}</view> -->
<view v-if="item.type != 1">支行名称{{ item.subbranchName }}</view>
<view>银行卡号{{ item.bankCard }}</view>
<view>提现时间{{ timeFormat(new Date(item.createTime).getTime(), 'yyyy-mm-dd hh:MM:ss') }}</view>
<view>处理时间{{ item.completeTime ? timeFormat(new Date(item.completeTime).getTime(), 'yyyy-mm-dd hh:MM:ss') : '-' }}</view>
<view>处理结果{{ item.handleMessage || '-' }}</view>
</view>
<view class="wallet_list_right" style="display: flex; flex-direction: column; align-items: flex-end;height: 320rpx;">
<view style="margin-bottom: 100rpx">
<view></view>
<up-tag v-if="item.status == 0" size="mini" text="申请中" type="warning" plain plainFill></up-tag>
<up-tag v-if="item.status == 1" size="mini" type="success" text="提现成功" plain plainFill></up-tag>
<up-tag v-if="item.status == -1" size="mini" type="error" text="失败" plain plainFill></up-tag>
</view>
<view>{{ item.amount }}</view>
</view>
</view>
</z-paging>
</view>
</template>
<script setup>
import { reactive, ref } from 'vue';
import { onPullDownRefresh, onPageScroll, onReachBottom } from '@dcloudio/uni-app';
import { timeFormat } from '@/uni_modules/uview-plus';
import { userExtractList } from '@/api/api.js';
import { onLoad, onShow } from '@dcloudio/uni-app';
import { useNav } from '@/hooks/useNav.js';
import moneyJson from '@/common/money.json';
const { nav, navTo } = useNav();
let getInfo = ref({});
const paging = ref(null);
let dataList = ref([]);
let isPagingRefNotFound = () => {
return !paging.value;
};
function maskCardNumber(cardNumber) {
if (!cardNumber || typeof cardNumber !== 'string') {
throw new Error('Invalid card number');
}
const sanitizedNumber = cardNumber.replace(/\D/g, '');
if (sanitizedNumber.length < 4) {
throw new Error('Card number is too short');
}
const lastFourDigits = sanitizedNumber.slice(-4);
const maskedNumber = '*'.repeat(sanitizedNumber.length - 4) + lastFourDigits;
return maskedNumber;
}
onPullDownRefresh(() => {
if (isPagingRefNotFound()) return;
paging.value.reload().catch(() => {});
});
onPageScroll((e) => {
if (isPagingRefNotFound()) return;
paging.value.updatePageScrollTop(e.scrollTop);
e.scrollTop < 10 && paging.value.doChatRecordLoadMore();
});
onReachBottom(() => {
if (isPagingRefNotFound()) return;
paging.value.pageReachBottom();
});
const queryList = (pageNo, pageSize) => {
const params = {
current: pageNo,
pageSize: pageSize
};
userExtractList(params)
.then((res) => {
paging.value.complete(res);
})
.catch((res) => {
paging.value.complete(false);
});
};
</script>
<style scoped lang="scss">
.wallet_pall {
width: 690rpx;
height: 272rpx;
border-radius: 16rpx 16rpx 16rpx 16rpx;
padding: 40rpx;
background: #ffffff;
&_header {
font-weight: bold;
font-size: 26rpx;
color: #002ea4;
}
&_ye {
display: flex;
align-items: center;
justify-content: space-between;
height: 70%;
view:nth-child(1) {
font-weight: bold;
font-size: 68rpx;
color: #002ea4;
}
view:nth-child(2) {
width: 128rpx;
height: 58rpx;
background: rgba(0, 46, 164, 0.07);
border-radius: 32rpx 32rpx 32rpx 32rpx;
display: flex;
align-items: center;
justify-content: center;
font-size: 26rpx;
color: #002ea4;
}
}
}
.wallet_list {
width: 690rpx;
background: #ffffff;
border-radius: 8rpx 8rpx 8rpx 8rpx;
padding: 15rpx 30rpx;
@include flex($space: space-between);
&_left {
// view:nth-child(1) {
// font-weight: bold;
// font-size: 28rpx;
// color: #232323;
// margin-bottom: 10rpx;
// }
// view:nth-child(2) {
// font-size: 24rpx;
// color: #232323;
// }
view {
font-size: 28rpx;
color: #232323;
margin-bottom: 10rpx;
}
}
&_right {
font-weight: bold;
font-size: 28rpx;
color: #ff2727;
}
}
</style>