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
836180fe
Commit
836180fe
authored
Nov 11, 2022
by
RuoYi
Browse files
优化导出对象的子列表为空会出现[]问题
parent
06fbda53
Changes
1
Hide whitespace changes
Inline
Side-by-side
ruoyi-common/src/main/java/com/ruoyi/common/utils/poi/ExcelUtil.java
View file @
836180fe
...
...
@@ -911,6 +911,10 @@ public class ExcelUtil<T>
{
cellValue
=
RegExUtils
.
replaceFirst
(
cellValue
,
FORMULA_REGEX_STR
,
"\t$0"
);
}
if
(
value
instanceof
Collection
&&
StringUtils
.
equals
(
"[]"
,
cellValue
))
{
cellValue
=
StringUtils
.
EMPTY
;
}
cell
.
setCellValue
(
StringUtils
.
isNull
(
cellValue
)
?
attr
.
defaultValue
()
:
cellValue
+
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