From 214daf2c75518db9f34af821f92e473c1d32d8a2 Mon Sep 17 00:00:00 2001 From: hzj <1304805162@qq.com> Date: Wed, 21 Jan 2026 18:19:36 +0800 Subject: [PATCH] =?UTF-8?q?feat(cp=E6=8E=92=E8=A1=8C=E6=A6=9C):=20?= =?UTF-8?q?=E9=87=91=E5=B8=81=E8=AE=A1=E7=AE=97=E6=96=B9=E6=B3=95=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/Ranking/Couple/Ranking.vue | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/views/Ranking/Couple/Ranking.vue b/src/views/Ranking/Couple/Ranking.vue index 80bc055..e7ce69d 100644 --- a/src/views/Ranking/Couple/Ranking.vue +++ b/src/views/Ranking/Couple/Ranking.vue @@ -621,15 +621,13 @@ const formatLargeNumber = (num) => { const absNum = Math.abs(num) if (absNum >= 1000000) { - // 截断到两位小数,不进行四舍五入 const millionValue = num / 1000000 - const truncatedValue = Math.trunc(millionValue * 100) / 100 - return truncatedValue.toFixed(2) + 'M' + const roundedValue = Math.round(millionValue * 100) / 100 + return roundedValue.toFixed(2) + 'M' } else if (absNum >= 1000) { - // 截断到两位小数,不进行四舍五入 const thousandValue = num / 1000 - const truncatedValue = Math.trunc(thousandValue * 100) / 100 - return truncatedValue.toFixed(2) + 'K' + const roundedValue = Math.round(thousandValue * 100) / 100 + return roundedValue.toFixed(2) + 'K' } else { return Math.floor(num).toString() }