<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                現在要導出格式如下: ![](https://img.kancloud.cn/45/bb/45bb65225982b10f9689c666382659e5_318x493.png) 實體如下: ~~~ public class TestEntity{ @Excel(name = "姓名", width = 15) private String username; @Excel(name = "年齡", width = 15) private int age; .....省略后續getset ~~~ --------- 數據格式如下: ~~~ //多個map,對應了多個sheet List<Map<String, Object>> listMap = new ArrayList<Map<String, Object>>(); for(int i=0;i<3;i++){ Map<String, Object> map = new HashMap<String, Object>(); map.put("title",getExportParams("測試"+i));//表格title map.put("entity",TestEntity.class);//表格對應實體 //數據封裝方式一:map數據,手動封裝ExcelExportEntity集合 List<Map> ls=new ArrayList<Map> (); for(int j=0;j<10;j++){ Map map = new HashMap(); map1.put("name","李四"+j); map1.put("age",18+j); ls.add(map); } //數據封裝方式二:實體類 List<TestEntity> ls=new ArrayList<TestEntity> (); for(int j=0;j<10;j++){ TestEntity testEntity = new TestEntity(); testEntity.setName("張三"+j); testEntity.setAge(18+j); ls.add(testEntity); } map.put("data", ls); listMap.add(map); } //導出參數 public static ExportParams getExportParams(String name) { //表格名稱,sheet名稱,導出版本 return new ExportParams(name,name,ExcelType.XSSF); } ~~~ 調用ExcelExportUtil.exportExcel方法生成workbook ~~~ Workbook wb = ExcelExportUtil.exportExcel(listMap,ExcelType.XSSF); ~~~
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看