From 9427df4fcfef577244b7dedb67abd0fd667ce217 Mon Sep 17 00:00:00 2001 From: liaoxinyu Date: Thu, 13 Mar 2025 14:08:50 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=90=88=E7=BA=A6=E4=BF=9D?= =?UTF-8?q?=E8=AF=81=E9=87=91=E5=8F=AA=E8=83=BD=E8=BE=93=E5=85=A52?= =?UTF-8?q?=E4=BD=8D=E5=B0=8F=E6=95=B0=E7=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/base/mine.vue | 9 ++++++--- pages/exchange/open-position.vue | 12 ++++++++++-- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/pages/base/mine.vue b/pages/base/mine.vue index fbb7a3b..5340b30 100644 --- a/pages/base/mine.vue +++ b/pages/base/mine.vue @@ -40,8 +40,9 @@ --> - {{filterMoney(account.total_assets_btc, true)}} + + {{ price1(account.total_assets_btc, 8) }} ≈ ${{ price1(account.total_assets_usd, 2) }} @@ -188,7 +189,8 @@ - ≈{{ omitTo(account.funds_account_usd,2) }} + + ≈{{ price1(account.funds_account_usd,2) }} {{ $t("base.d6") }}(USDT) @@ -299,7 +301,8 @@ - {{ filterMoney(account.contract_account_usd)}}{{ account.symbol }} + + {{ price1(account.contract_account_usd,2)}}{{ account.symbol }} diff --git a/pages/exchange/open-position.vue b/pages/exchange/open-position.vue index 7b5ad8a..7dfa7d4 100644 --- a/pages/exchange/open-position.vue +++ b/pages/exchange/open-position.vue @@ -173,12 +173,12 @@ --> @@ -1151,6 +1151,14 @@ export default { } }, methods: { + inputEnter(e){ + this.$nextTick(()=> { + this.margin = e + .replace(/[^\d.]/g, "") // 移除非数字、非小数点的字符 + .replace(/^(\d*\.?\d{0,2}).*$/, "$1"); // 限制最多两位小数 + this.sliderActive=-1 + }) + }, onRefresh() { if (this.refreshing) return; this.refreshing = true;