From 5a759c72b81d1541ad4c88770a0acd5c3ffcb003 Mon Sep 17 00:00:00 2001 From: LSH Date: 星期一, 16 十月 2023 16:39:33 +0800 Subject: [PATCH] # --- src/main/java/com/zy/crm/manager/utils/WordUtils.java | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/src/main/java/com/zy/crm/manager/utils/WordUtils.java b/src/main/java/com/zy/crm/manager/utils/WordUtils.java index c633862..74b58ac 100644 --- a/src/main/java/com/zy/crm/manager/utils/WordUtils.java +++ b/src/main/java/com/zy/crm/manager/utils/WordUtils.java @@ -168,6 +168,9 @@ } public static String formatNumberForAccounting(double number) { + if (number == 0) { + return "0.00"; + } NumberFormat formatter = new DecimalFormat("#,###.00"); return formatter.format(number); } -- Gitblit v1.9.1