From 6ae727d83d6e42428711fa2337528679aae239eb Mon Sep 17 00:00:00 2001
From: lxf <1371462558@qq.com>
Date: Thu, 24 Apr 2025 17:17:05 +0800
Subject: [PATCH] feat

---
 src/utils/filter.js |   11 ++++++-----
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/src/utils/filter.js b/src/utils/filter.js
index 4e7ed63..4ddb0b8 100644
--- a/src/utils/filter.js
+++ b/src/utils/filter.js
@@ -1,13 +1,13 @@
 export function _toLocaleString(
   number,
   showCurrencySymbol = true, // 是否显示货币符号,默认为 true
-  locale = "en-IN", // 默认使用印度英语的语言环境
+  locale = "ar-SA", // 默认使用印度英语的语言环境
   options = {
     // style:可选值为 decimal(小数)、currency(货币)或 percent(百分比);
     // currency:设置为货币样式时使用的符号,支持列表在这里;
     // useGrouping:布尔值,是否显示数字分位。
     style: "currency",
-    currency: "INR",
+    currency: "SAR",
     minimumFractionDigits: 2 //如果不想要显示末尾的小数「.00」,只要设置一下最小分位 minimumFractionDigits 即可(默认是 2):
   }
 ) {
@@ -15,9 +15,10 @@
   number = Math.floor(number * 100) / 100; // 向下取整并保留两位小数
 
   let str = Number(number).toLocaleString(locale, options);
-  if (showCurrencySymbol) {
-    str = str.replace("₹", "");
-  }
+  console.log('转换后的'+ str)
+  // if (showCurrencySymbol) {
+  //   str = str.replaceAll("₹", "");
+  // }
   return str;
 }
 export function _toString(u) {

--
Gitblit v1.9.3