From a9695d1756d2dce623bf6f0d4a627f44850dce3d Mon Sep 17 00:00:00 2001 From: mazh Date: Wed, 5 Aug 2020 11:28:57 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DBUG:=20=E5=AF=BC=E5=87=BAExce?= =?UTF-8?q?l=E5=8A=9F=E8=83=BD,=20=E5=BD=93attr=E7=9A=84cellType=E4=B8=BAS?= =?UTF-8?q?tring=E6=97=B6,=20cell=E7=9A=84cellType=E7=94=B1Numeric?= =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E4=B8=BAString=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/ruoyi/common/utils/poi/ExcelUtil.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruoyi-common/src/main/java/com/ruoyi/common/utils/poi/ExcelUtil.java b/ruoyi-common/src/main/java/com/ruoyi/common/utils/poi/ExcelUtil.java index 494fb4b..d950b77 100644 --- a/ruoyi-common/src/main/java/com/ruoyi/common/utils/poi/ExcelUtil.java +++ b/ruoyi-common/src/main/java/com/ruoyi/common/utils/poi/ExcelUtil.java @@ -476,7 +476,7 @@ public class ExcelUtil { if (ColumnType.STRING == attr.cellType()) { - cell.setCellType(CellType.NUMERIC); + cell.setCellType(CellType.STRING); cell.setCellValue(StringUtils.isNull(value) ? attr.defaultValue() : value + attr.suffix()); } else if (ColumnType.NUMERIC == attr.cellType())