From 155bb21ac78455a0c5b3a2302528ade7a5a6fb19 Mon Sep 17 00:00:00 2001 From: Junjie <fallin.jie@qq.com> Date: 星期五, 08 九月 2023 08:56:49 +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