From 001d3ba07f6a87396124b463fac919c11e802582 Mon Sep 17 00:00:00 2001 From: hzj <1304805162@qq.com> Date: Thu, 25 Sep 2025 14:29:31 +0800 Subject: [PATCH] =?UTF-8?q?style(=E6=A0=B7=E5=BC=8F=E8=B0=83=E6=95=B4):=20?= =?UTF-8?q?=E8=BD=AC=E8=B4=A6=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/TransferView.vue | 350 +++++++++++++++++++++++-------------- 1 file changed, 218 insertions(+), 132 deletions(-) diff --git a/src/views/TransferView.vue b/src/views/TransferView.vue index 3e2d67a..8d7bc2f 100644 --- a/src/views/TransferView.vue +++ b/src/views/TransferView.vue @@ -4,74 +4,184 @@
-
-
-

Information

- +
+
+
Information
+
+
Details
+ +
-
- Available salary: +
+ Available salary: Loading... - {{ availableSalary }} + {{ + availableSalary + }} +
+
+ + +
+
Transfer to others
+
+ +
+ +
+ +
+ + {{ selectedPayee.name.charAt(0) }} +
+ +
+
+ {{ selectedPayee.name }} +
+
+ ID: {{ selectedPayee.account || selectedPayee.id }} +
+
+ + +
+ +
+ + + +
+
+ + +
+
+ Search +
+
-
-

Transfer to others

- - -
-
-
- - {{ selectedPayee.name.charAt(0) }} +
+
+ +
+
+ +
{{ coin.amount }}
+
${{ coin.price }}
-
-

{{ selectedPayee.name }}

-

ID: {{ selectedPayee.account || selectedPayee.id }}

-
- 👑 Host - 🏢 Agency - 💰 Salary -
-
-
- -
- - -
-
-
🔍
- Search -
-
- - -
-
-
🪙
-
{{ coin.amount }}
-
${{ coin.price }}
- +
+ +
@@ -81,9 +191,9 @@ import { ref, reactive, onMounted } from 'vue' import { useRouter } from 'vue-router' import MobileHeader from '../components/MobileHeader.vue' -import {getBankBalance, userBankTransfer} from '../api/wallet.js' +import { getBankBalance, userBankTransfer } from '../api/wallet.js' import { getSelectedPayee, clearSelectedPayee } from '../utils/payeeStore.js' -import {showError, showSuccess} from "@/utils/toast.js"; +import { showError, showSuccess } from '@/utils/toast.js' const router = useRouter() @@ -100,7 +210,7 @@ const selectedPayee = reactive({ type: '', isHost: false, isAgency: false, - hasSalary: false + hasSalary: false, }) // 初始化收款人信息 @@ -118,7 +228,7 @@ const coinOptions = reactive([ { id: 3, amount: 100000, price: 10 }, { id: 4, amount: 500000, price: 50 }, { id: 5, amount: 1000000, price: 100 }, - { id: 6, amount: 2000000, price: 200 } + { id: 6, amount: 2000000, price: 200 }, ]) // 获取银行余额 @@ -163,7 +273,7 @@ const clearPayee = () => { type: '', isHost: false, isAgency: false, - hasSalary: false + hasSalary: false, }) clearSelectedPayee() } @@ -188,7 +298,7 @@ const transfer = async () => { return } - const selectedCoinData = coinOptions.find(coin => coin.id === selectedCoin.value) + const selectedCoinData = coinOptions.find((coin) => coin.id === selectedCoin.value) // 获取支付密码 // const password = prompt('Please enter your payment password:') @@ -219,7 +329,6 @@ const transfer = async () => { // 刷新银行余额 await fetchBankBalance() - } catch (error) { // 错误处理 console.error('Transfer failed:', error) @@ -242,6 +351,11 @@ onMounted(() => {