fengxiang
2018-09-27 3c3f6b4816efe48645866a6ebc1581eb522dc229
src/main/java/com/moral/common/util/ExportExcelUtils.java
@@ -64,7 +64,9 @@
      for (int i = 0; i < list.size(); i++) {
         JSONObject jsonObject = JSONObject.fromObject(list.get(i));
         for (int j = 0; j < colTitles.length; j++) {
            ws.addCell(new Label(j, i + 1, jsonObject.getString(fieldNames[j])));
            if (jsonObject.containsKey(fieldNames[j])) {
               ws.addCell(new Label(j, i + 1, jsonObject.getString(fieldNames[j])));
            }
         }
      }
   }