Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
jinli gu
RuoYi Vue
Commits
a9695d17
Commit
a9695d17
authored
Aug 05, 2020
by
mazh
Browse files
修复BUG: 导出Excel功能, 当attr的cellType为String时, cell的cellType由Numeric修正为String。
parent
b5689885
Changes
1
Show whitespace changes
Inline
Side-by-side
ruoyi-common/src/main/java/com/ruoyi/common/utils/poi/ExcelUtil.java
View file @
a9695d17
...
...
@@ -476,7 +476,7 @@ public class ExcelUtil<T>
{
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
())
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment