三期内容提交
This commit is contained in:
@@ -106,3 +106,11 @@ export function numberToCNY(money) {
|
||||
}
|
||||
return chineseStr;
|
||||
}
|
||||
|
||||
|
||||
export function formatNumberToWan(num) {
|
||||
if (num === 0) return 0;
|
||||
const wanNum = num / 10000;
|
||||
const roundedNum = Math.round(wanNum * 100) / 100; // 保留两位小数,四舍五入
|
||||
return roundedNum;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user