From 08743f3bf77c2120c1381ee9c17d2988ba2bdeff Mon Sep 17 00:00:00 2001 From: hzj <1304805162@qq.com> Date: Fri, 14 Nov 2025 19:56:11 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E6=8F=90=E7=8E=B0=E3=80=81=E8=BD=AC?= =?UTF-8?q?=E8=B4=A6=E8=AF=A6=E6=83=85):=20=E5=AF=B9=E6=8E=A5=E6=8E=A5?= =?UTF-8?q?=E5=8F=A3=E8=B0=83=E8=AF=95=EF=BC=8C=E4=BD=86=E6=98=AF=E5=85=88?= =?UTF-8?q?=E9=9A=90=E8=97=8F=E8=B7=B3=E8=BD=AC=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/wallet.js | 12 ++ src/views/BDCenter/availableIncome.vue | 4 +- src/views/BDCenter/incomeDetails.vue | 224 ++++++++++++------------- 3 files changed, 125 insertions(+), 115 deletions(-) diff --git a/src/api/wallet.js b/src/api/wallet.js index d1f9e4f..96577b4 100644 --- a/src/api/wallet.js +++ b/src/api/wallet.js @@ -341,3 +341,15 @@ export const withdrawApply = async (data) => { throw error } } + +// 获取提现记录 +export const apiGetCashOutRecords = async () => { + try { + const response = await get(`/activity/lottery/withdraw/records`) + return response + } catch (error) { + console.error('Failed to fetch get cash out records:', error) + console.error('error:' + error.response.errorMsg) + throw error + } +} diff --git a/src/views/BDCenter/availableIncome.vue b/src/views/BDCenter/availableIncome.vue index 1dee53b..64344d2 100644 --- a/src/views/BDCenter/availableIncome.vue +++ b/src/views/BDCenter/availableIncome.vue @@ -19,10 +19,10 @@ " >
{{ t('available_salaries') }}
-
+
+
-
-
-
{{ t('cash_out') }}
-
${{ record.amount }}
-
-
-
- {{ record.date }} -
-
- {{ getStatusText(record.status) }} -
-
-
- - -
-
{{ t('transfer') }}
+
-
-
- -
-
-
asdfasdfasdfasdsfasfasfasd
-
- ID:1234567890 -
-
- 21/10/2025 17:56 -
-
+
+
{{ t('cash_out') }}
+
${{ record.amount }}
- -
- {{ t('plus_coins', { amount: '10000' }) }} +
+
+ {{ record.date }} +
+
+ {{ getStatusText(record.status) }} +
- +
+
{{ t('transfer') }}
+
+
+
+ +
+
+
{{ record.name }}
+
+ ID:{{ record.id }} +
+
+
+ +
+ {{ t('plus_coins', { amount: record.amount }) }} +
+
+ +
+ 21/10/2025 17:56 +
+
+ + +
{{ record.type }}
-
- {{ record.amount }} -
+
-${{ record.amount }}
{{ record.date }} @@ -144,52 +120,65 @@ import { useI18n } from 'vue-i18n' import GeneralHeader from '@/components/GeneralHeader.vue' import { ref, onMounted } from 'vue' import { setDocumentDirection } from '@/locales/i18n' +import { apiGetCashOutRecords } from '@/api/wallet' const { t, locale } = useI18n() // 监听语言变化并设置文档方向 locale.value && setDocumentDirection(locale.value) -// Cash Out 记录数据 -const cashOutRecords = ref([ +// 记录数据 +const Records = ref([ { id: 1, + type: 'cashOut', amount: 10, date: '21/10/2025 17:56', status: 'Under review', }, { id: 2, + type: 'cashOut', amount: 10, date: '21/10/2025 17:56', status: 'Approved', }, { id: 3, + type: 'cashOut', amount: 10, date: '21/10/2025 17:56', status: 'Rejection', }, -]) - -// 其他记录数据 -const otherRecords = ref([ + { + id: 7, + type: 'Transfer', + avatar: '', + name: 'asdfasdfasdfasdsfasfasfasd', + id: '1234567890', + addStatus: '1', + amount: '10000', + date: '21/10/2025 17:56', + }, { id: 4, type: 'Exchange Coins', - amount: '- $10', + addStatus: '0', + amount: '10', date: '21/10/2025 17:56', }, { id: 5, - type: "BD's income", - amount: '+ $10', + type: 'BD income', + addStatus: '1', + amount: '10', date: '21/10/2025 17:56', }, { id: 6, - type: "BD Leader's income", - amount: '+ $10', + type: 'BD Leader income', + addStatus: '1', + amount: '10', date: '21/10/2025 17:56', }, ]) @@ -214,8 +203,17 @@ const defaultAvatarUrl = (e) => { e.target.src = new URL('/src/assets/images/WeeklyStar/defaultAvatar.png', import.meta.url).href } +// 获取提现记录 +const getCashOutRecords = async () => { + const resCashOutRecords = await apiGetCashOutRecords() + console.log('已邀请列表:', resCashOutRecords) + if (resCashOutRecords.status && resCashOutRecords.body) { + // invitedUserList.value = resCashOutRecords.body + } +} + onMounted(() => { - // 这里可以添加数据获取逻辑 + getCashOutRecords() // 获取提现记录 })