From 51b0f6ed9f4e1d3bb6f8144470b46908c7699a96 Mon Sep 17 00:00:00 2001
From: yyl <yyl>
Date: 星期一, 11 五月 2026 16:20:37 +0800
Subject: [PATCH] Merge branch 'master' into h5version
---
Main/Utility/UIHelper.cs | 30 ++++++++++++++++++++++--------
1 files changed, 22 insertions(+), 8 deletions(-)
diff --git a/Main/Utility/UIHelper.cs b/Main/Utility/UIHelper.cs
index 8cb49c4..43a23f7 100644
--- a/Main/Utility/UIHelper.cs
+++ b/Main/Utility/UIHelper.cs
@@ -237,10 +237,17 @@
/// </summary>
public static string ReplaceLargeNum(double num, int decimalPlaces = 1)
{
- const long K = 10000; //鍥藉唴涓轰竾锛屾捣澶栦负鍗�
- const long M = K * 10000;
- const long B = M * 10000;
- const long T = B * 10000;
+ // 鑾峰彇褰撳墠璇█鐘舵��
+ string langId = Language.Id;
+ bool isChinese = langId == "zh" || langId == "ft";
+
+ // 绠�绻佷腑鏂囦竾杩涘埗 (10000)锛屽叾浠栧崈杩涘埗 (1000)
+ long baseUnit = isChinese ? 10000 : 1000;
+
+ long K = baseUnit;
+ long M = K * baseUnit;
+ long B = M * baseUnit;
+ long T = B * baseUnit;
if (num >= T)
{
@@ -267,10 +274,17 @@
//鐢ㄤ簬缇庢湳瀛� 缁熶竴鐢ㄥ瓧姣岾MBT浠h〃浣跨敤锛屽皬鏁扮偣鐢�.
public static string ReplaceLargeArtNum(double num)
{
- const long K = 10000; //鍥藉唴涓轰竾锛屾捣澶栦负鍗�
- const long M = K * 10000;
- const long B = M * 10000;
- const long T = B * 10000;
+ // 鑾峰彇褰撳墠璇█鐘舵��
+ string langId = Language.Id;
+ bool isChinese = langId == "zh" || langId == "ft";
+
+ // 绠�绻佷腑鏂囦竾杩涘埗 (10000)锛屽叾浠栧崈杩涘埗 (1000)
+ long baseUnit = isChinese ? 10000 : 1000;
+
+ long K = baseUnit;
+ long M = K * baseUnit;
+ long B = M * baseUnit;
+ long T = B * baseUnit;
if (num >= T)
{
--
Gitblit v1.8.0