From 6b49a037e07faa06ded71fb8a00ba5f6b4490d96 Mon Sep 17 00:00:00 2001 From: Songsl <2431955898@qq.com> Date: Sun, 14 Jun 2026 15:43:02 +0800 Subject: [PATCH] =?UTF-8?q?=E9=92=B1=E5=8C=85=E7=AE=A1=E7=90=86=E6=A8=A1?= =?UTF-8?q?=E5=9D=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/modules/wallet/wallet.ts | 36 +++ src/views/wallet/addressList/index.vue | 228 ++++++++++++++++++ src/views/wallet/addressList/options.ts | 40 +++ src/views/wallet/withdrawOrderList/index.vue | 144 +++++++++++ src/views/wallet/withdrawOrderList/options.ts | 70 ++++++ 5 files changed, 518 insertions(+) create mode 100644 src/api/modules/wallet/wallet.ts create mode 100644 src/views/wallet/addressList/index.vue create mode 100644 src/views/wallet/addressList/options.ts create mode 100644 src/views/wallet/withdrawOrderList/index.vue create mode 100644 src/views/wallet/withdrawOrderList/options.ts diff --git a/src/api/modules/wallet/wallet.ts b/src/api/modules/wallet/wallet.ts new file mode 100644 index 0000000..82ebfcd --- /dev/null +++ b/src/api/modules/wallet/wallet.ts @@ -0,0 +1,36 @@ +import { request } from '@/api' + +// 提现订单列表 +export const getWithdrawOrderList = (params: { + page: number + page_size: number + start_time?: string + end_time?: string + status?: string +}) => { + return request.get('/upay/withdrawOrderList', params as any) +} + +// 刷新地址余额 +export const balanceRefresh = (params: { address?: string, addressType?: string }) => { + return request.post('/upay/balanceRefresh', params) +} + +// 提现地址列表 +export const getAddressList = (params: { + page: number + page_size: number + address?: string + addressType?: string +}) => { + return request.post('/upay/addressList', params as any) +} + +// 提现 +export const withdrawAction = (params: { + from: string + to: string + amount: string +}) => { + return request.post('/upay/withdrawAction', params) +} diff --git a/src/views/wallet/addressList/index.vue b/src/views/wallet/addressList/index.vue new file mode 100644 index 0000000..9118837 --- /dev/null +++ b/src/views/wallet/addressList/index.vue @@ -0,0 +1,228 @@ + + + + + diff --git a/src/views/wallet/addressList/options.ts b/src/views/wallet/addressList/options.ts new file mode 100644 index 0000000..13d10de --- /dev/null +++ b/src/views/wallet/addressList/options.ts @@ -0,0 +1,40 @@ +// 提现地址列表页面表格列配置 +export const tableColumns = [ + // 序号 + { label: '序号', type: 'index', width: 60, align: 'center' as const }, + // 地址 + { label: '地址', prop: 'address', width: 400, align: 'center' as const, copy: true }, + // TRX余额 + { label: 'TRX余额', prop: 'trxBalance', align: 'center' as const }, + // USDT余额 + { label: 'USDT余额', prop: 'usdtBalance', align: 'center' as const }, + // 地址类型 + { label: '地址类型', prop: 'addressType', align: 'center' as const }, + // 创建时间 + { label: '创建时间', prop: 'createdAt', align: 'center' as const }, + // 操作 + { label: '操作', prop: 'action', width: 160, slotName: 'action' as const }, +] + +// 搜索配置 +export const searchOptions = [ + { + prop: 'addressType', + label: '钱包类型', + type: 'select' as const, + placeholder: '请选择钱包类型', + width: '220px', + options: [ + { label: 'TRX', value: 'TRX' }, + { label: 'ETH', value: 'ETH' }, + { label: 'BTC', value: 'BTC' }, + ], + }, + { + prop: 'address', + label: '钱包地址', + type: 'input' as const, + placeholder: '请输入钱包地址', + width: '220px', + }, +] diff --git a/src/views/wallet/withdrawOrderList/index.vue b/src/views/wallet/withdrawOrderList/index.vue new file mode 100644 index 0000000..2e88724 --- /dev/null +++ b/src/views/wallet/withdrawOrderList/index.vue @@ -0,0 +1,144 @@ + + + + + diff --git a/src/views/wallet/withdrawOrderList/options.ts b/src/views/wallet/withdrawOrderList/options.ts new file mode 100644 index 0000000..d369564 --- /dev/null +++ b/src/views/wallet/withdrawOrderList/options.ts @@ -0,0 +1,70 @@ +// 状态选项 +const statusOptions = [ + { label: '未完成', value: 1 }, + { label: '成功', value: 2 }, + { label: '失败', value: 3 }, +] + +// 提现订单列表页面表格列配置 +export const tableColumns = [ + // 序号 + { label: '序号', type: 'index', width: 60, align: 'center' as const }, + // 用户ID +// { label: '用户ID', prop: 'user_id' }, + // 订单号 + { label: '订单号', prop: 'order_n', width: 300, align: 'center' as const, copy: true }, + // 通知号 + { label: '通知号', prop: 'notify_n', width: 200, align: 'center' as const }, + // 来源地址 + { label: '来源地址', prop: 'from', width: 400, align: 'center' as const, copy: true }, + // 目标地址 + { label: '目标地址', prop: 'to', width: 400, align: 'center' as const, copy: true }, + // 金额 + { label: '金额', prop: 'amount', width: 160, align: 'center' as const }, + // 地址类型 + { label: '地址类型', prop: 'addressType', width: 100, align: 'center' as const }, + // 余额 + { label: '余额', prop: 'balance', width: 160, align: 'center' as const }, + // 状态 + { label: '状态', prop: 'status', width: 100, align: 'center' as const, options: statusOptions }, + // 创建时间 + { label: '创建时间', prop: 'create_time', width: 200, align: 'center' as const }, + // 成功时间 + { label: '成功时间', prop: 'success_time', width: 200, align: 'center' as const }, + // 交易ID + { label: '交易ID', prop: 'tx_id', width: 400, align: 'center' as const }, +] + +// 搜索配置 +export const searchOptions = [ + { + prop: 'status', + label: '状态', + type: 'select' as const, + placeholder: '请选择状态', + width: '160px', + options: statusOptions, + }, + { + prop: 'start_time', + label: '开始时间', + type: 'date' as const, + dateType: 'datetime' as const, + placeholder: '开始时间', + valueFormat: 'YYYY-MM-DD HH:mm:ss', + format: 'YYYY-MM-DD', + width: '220px', + defaultTime: 'start' as const, + }, + { + prop: 'end_time', + label: '结束时间', + type: 'date' as const, + dateType: 'datetime' as const, + placeholder: '结束时间', + valueFormat: 'YYYY-MM-DD HH:mm:ss', + format: 'YYYY-MM-DD', + width: '220px', + defaultTime: 'end' as const, + }, +]