فهرست منبع

导出问题修复

wangming 1 سال پیش
والد
کامیت
4a46279c00
1فایلهای تغییر یافته به همراه5 افزوده شده و 0 حذف شده
  1. 5 0
      business-common/src/main/java/com/rongwei/bscommon/sys/utils/XlsSheetUtil.java

+ 5 - 0
business-common/src/main/java/com/rongwei/bscommon/sys/utils/XlsSheetUtil.java

@@ -306,6 +306,11 @@ public class XlsSheetUtil {
 
                 for(int i = rows.getIntValue(0), j = rows.getIntValue(1); i <= j; i++) {
                     Row row = sheet.getRow(i);
+
+                    if(row == null) {
+                        row = sheet.createRow(i);
+                    }
+
                     for(int colStart = cols.getIntValue(0), colEnd = cols.getIntValue(1); colStart <= colEnd; colStart++) {
 
                         Cell cell = row.getCell(colStart);