We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
autopoi:1.1.1
在实体映射中定义其他@ExcelEntity 实体,普通字段不受影响,时间字段会转换异常
友情提示: 未按格式要求发帖,会直接删掉。
请在细化下问题描述
... 解决方案 autopoi版本 1.2 value为空值时提前 return
org.jeecgframework.poi.excel.export.base.ExportBase#getCellValue
public Object getCellValue(ExcelExportEntity entity, Object obj) throws Exception { Object value; if (obj instanceof Map) { value = ((Map) obj).get(entity.getKey()); } else { value = entity.getMethods() != null ? getFieldBySomeMethod(entity.getMethods(), obj) : entity.getMethod().invoke(obj, new Object[] {}); }
// +++ value = Optional.ofNullable(value).orElse(""); if (StringUtils.isEmpty(value.toString())) { return ""; } // +++
}
autopoi导入导出组件系列问题
Activity
zhangdaiscott commentedon Aug 24, 2020
请在细化下问题描述
zhangdaiscott commentedon Aug 31, 2020
...
解决方案
autopoi版本 1.2 value为空值时提前 return
org.jeecgframework.poi.excel.export.base.ExportBase#getCellValue
public Object getCellValue(ExcelExportEntity entity, Object obj) throws Exception {
Object value;
if (obj instanceof Map) {
value = ((Map) obj).get(entity.getKey());
} else {
value = entity.getMethods() != null ? getFieldBySomeMethod(entity.getMethods(), obj) : entity.getMethod().invoke(obj, new Object[] {});
}
}
autopoi导入导出组件系列问题
autopoi导入导出组件系列问题