优化ExcelUtil空值处理

pull/50/MERGE
Ricky 4 years ago
parent cb9fa33b5a
commit 2419815bc1

@ -528,7 +528,10 @@ public class ExcelUtil<T>
}
else if (ColumnType.NUMERIC == attr.cellType())
{
cell.setCellValue(StringUtils.contains(Convert.toStr(value), ".") ? Convert.toDouble(value) : Convert.toInt(value));
if (StringUtils.isNotNull(value))
{
cell.setCellValue(StringUtils.contains(Convert.toStr(value), ".") ? Convert.toDouble(value) : Convert.toInt(value));
}
}
else if (ColumnType.IMAGE == attr.cellType())
{

Loading…
Cancel
Save