licailing 4 лет назад
Родитель
Сommit
44b646a24a

+ 1 - 1
pom.xml

@@ -32,7 +32,7 @@
     <properties>
         <java.version>1.8</java.version>
         <skipTests>true</skipTests>
-        <poi.verion>3.17</poi.verion>
+        <poi.verion>4.1.0</poi.verion>
         <javawx.version>3.5.0</javawx.version>
         <aliyun.oss.version>2.8.3</aliyun.oss.version>
         <aliyun.core.version>4.1.0</aliyun.core.version>

+ 434 - 0
src/main/java/com/izouma/wenlvju/service/poi/PoiWordTable.java

@@ -0,0 +1,434 @@
+package com.izouma.wenlvju.service.poi;
+
+import org.apache.poi.ooxml.POIXMLDocumentPart;
+import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
+import org.apache.poi.util.Units;
+import org.apache.poi.xwpf.usermodel.*;
+import org.apache.xmlbeans.XmlCursor;
+import org.springframework.util.StringUtils;
+
+import java.io.*;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+public class PoiWordTable {
+
+    public static void main(String[] args) throws Exception {
+
+        final String returnurl = "D:\\youxi\\jx\\result.docx";  // 结果文件
+
+        final String templateurl = "D:\\youxi\\jx\\test.docx";  // 模板文件
+
+        InputStream is = new FileInputStream(templateurl);
+        XWPFDocument doc = new XWPFDocument(is);
+
+        // 替换word模板数据
+        replaceAll(doc);
+
+        // 保存结果文件
+        try {
+            File file = new File(returnurl);
+            if (file.exists()) {
+                file.delete();
+            }
+            FileOutputStream fos = new FileOutputStream(returnurl);
+            doc.write(fos);
+            fos.close();
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+    }
+
+
+    /**
+     * @Description: 替换段落和表格中
+     */
+    public static void replaceAll(XWPFDocument doc) throws InvalidFormatException, IOException {
+        doParagraphs(doc); // 处理段落文字数据,包括文字和表格、图片
+        doCharts(doc);  // 处理图表数据,柱状图、折线图、饼图啊之类的
+    }
+
+
+    /**
+     * 处理段落文字
+     *
+     * @param doc
+     * @throws InvalidFormatException
+     * @throws FileNotFoundException
+     * @throws IOException
+     */
+    public static void doParagraphs(XWPFDocument doc) throws InvalidFormatException, IOException {
+
+        // 文本数据
+        Map<String, String> textMap = new HashMap<>();
+        textMap.put("var", "我是被替换的文本内容");
+
+        // 图片数据
+        Map<String, String> imgMap = new HashMap<>();
+        imgMap.put("img", "D:/youxi/ddd.png");
+
+
+        /**----------------------------处理段落------------------------------------**/
+        List<XWPFParagraph> paragraphList = doc.getParagraphs();
+        if (paragraphList != null && paragraphList.size() > 0) {
+            for (XWPFParagraph paragraph : paragraphList) {
+                List<XWPFRun> runs = paragraph.getRuns();
+                for (XWPFRun run : runs) {
+                    String text = run.getText(0);
+                    if (text != null) {
+
+                        // 替换文本信息
+                        String tempText = text;
+                        String key = tempText.replaceAll("\\{\\{", "").replaceAll("}}", "");
+                        if (!StringUtils.isEmpty(textMap.get(key))) {
+                            run.setText(textMap.get(key), 0);
+                        }
+
+                        // 替换图片内容 参考:https://blog.csdn.net/a909301740/article/details/84984445
+                        String tempImgText = text;
+                        String imgkey = tempImgText.replaceAll("\\{\\{@", "").replaceAll("}}", "");
+                        if (!StringUtils.isEmpty(imgMap.get(imgkey))) {
+                            String imgPath = imgMap.get(imgkey);
+                            try {
+                                run.setText("", 0);
+                                run.addPicture(new FileInputStream(imgPath), Document.PICTURE_TYPE_PNG, "img.png", Units.toEMU(200), Units.toEMU(200));
+
+                            } catch (Exception e) {
+                                e.printStackTrace();
+                            }
+                        }
+
+                        // 动态表格
+                        if (text.contains("${table1}")) {
+                            run.setText("", 0);
+                            XmlCursor cursor = paragraph.getCTP().newCursor();
+                            XWPFTable tableOne = doc.insertNewTbl(cursor);// ---这个是关键
+
+                            // 设置表格宽度,第一行宽度就可以了,这个值的单位,目前我也还不清楚,还没来得及研究
+                            tableOne.setWidth(8500);
+
+                            // 表格第一行,对于每个列,必须使用createCell(),而不是getCell(),因为第一行嘛,肯定是属于创建的,没有create哪里来的get呢
+                            XWPFTableRow tableOneRowOne = tableOne.getRow(0);//行
+                            PoiWordTools.setWordCellSelfStyle(tableOneRowOne.getCell(0), "微软雅黑", "9", 0, "left", "top", "#000000", "#B4C6E7", "10%", "序号");
+                            PoiWordTools.setWordCellSelfStyle(tableOneRowOne.createCell(), "微软雅黑", "9", 0, "left", "top", "#000000", "#B4C6E7", "45%", "公司名称(英文)");
+                            PoiWordTools.setWordCellSelfStyle(tableOneRowOne.createCell(), "微软雅黑", "9", 0, "left", "top", "#000000", "#B4C6E7", "45%", "公司名称(中文)");
+
+                            // 表格第二行
+                            XWPFTableRow tableOneRowTwo = tableOne.createRow();//行
+                            PoiWordTools.setWordCellSelfStyle(tableOneRowTwo.getCell(0), "微软雅黑", "9", 0, "left", "top", "#000000", "#B4C6E7", "10%", "一行一列");
+                            PoiWordTools.setWordCellSelfStyle(tableOneRowTwo.getCell(1), "微软雅黑", "9", 0, "left", "top", "#000000", "#B4C6E7", "45%", "一行一列");
+                            PoiWordTools.setWordCellSelfStyle(tableOneRowTwo.getCell(2), "微软雅黑", "9", 0, "left", "top", "#000000", "#B4C6E7", "45%", "一行一列");
+
+
+                            // ....... 可动态添加表格
+                        }
+                    }
+                }
+            }
+        }
+    }
+
+
+    /**
+     * 处理图表
+     *
+     * @param doc
+     * @throws FileNotFoundException
+     */
+    public static void doCharts(XWPFDocument doc) throws FileNotFoundException {
+        /**----------------------------处理图表------------------------------------**/
+
+        // 数据准备
+        List<String> titleArr = new ArrayList<String>();// 标题
+        titleArr.add("title");
+        titleArr.add("金额");
+
+        List<String> fldNameArr = new ArrayList<String>();// 字段名
+        fldNameArr.add("item1");
+        fldNameArr.add("item2");
+
+        // 数据集合
+        List<Map<String, String>> listItemsByType = new ArrayList<Map<String, String>>();
+
+        // 第一行数据
+        Map<String, String> base1 = new HashMap<String, String>();
+        base1.put("item1", "材料费用");
+        base1.put("item2", "500");
+
+        // 第二行数据
+        Map<String, String> base2 = new HashMap<String, String>();
+        base2.put("item1", "出差费用");
+        base2.put("item2", "300");
+
+        // 第三行数据
+        Map<String, String> base3 = new HashMap<String, String>();
+        base3.put("item1", "住宿费用");
+        base3.put("item2", "300");
+
+        listItemsByType.add(base1);
+        listItemsByType.add(base2);
+        listItemsByType.add(base3);
+
+
+        // 获取word模板中的所有图表元素,用map存放
+        // 为什么不用list保存:查看doc.getRelations()的源码可知,源码中使用了hashMap读取文档图表元素,
+        // 对relations变量进行打印后发现,图表顺序和文档中的顺序不一致,也就是说relations的图表顺序不是文档中从上到下的顺序
+        Map<String, POIXMLDocumentPart> chartsMap = new HashMap<String, POIXMLDocumentPart>();
+        //动态刷新图表
+        List<POIXMLDocumentPart> relations = doc.getRelations();
+        for (POIXMLDocumentPart poixmlDocumentPart : relations) {
+            if (poixmlDocumentPart instanceof XWPFChart) {  // 如果是图表元素
+                String str = poixmlDocumentPart.toString();
+                System.out.println("str:" + str);
+                String key = str.replaceAll("Name: ", "")
+                        .replaceAll(" - Content Type: application/vnd\\.openxmlformats-officedocument\\.drawingml\\.chart\\+xml", "")
+                        .trim();
+                System.out.println("key:" + key);
+
+                chartsMap.put(key, poixmlDocumentPart);
+            }
+        }
+
+        System.out.println("\n图表数量:" + chartsMap.size() + "\n");
+
+
+        // 第一个图表-条形图
+        POIXMLDocumentPart poixmlDocumentPart0 = chartsMap.get("/word/charts/chart1.xml");
+        PoiWordTools.replaceBarCharts(poixmlDocumentPart0, titleArr, fldNameArr, listItemsByType);
+
+        // 第二个-柱状图
+        POIXMLDocumentPart poixmlDocumentPart1 = chartsMap.get("/word/charts/chart2.xml");
+        PoiWordTools.replaceBarCharts(poixmlDocumentPart1, titleArr, fldNameArr, listItemsByType);
+
+        // 第三个图表-多列柱状图
+        doCharts3(chartsMap);
+
+        // 第四个图表-折线图
+        doCharts4(chartsMap);
+
+        // 第五个图表-饼图
+        POIXMLDocumentPart poixmlDocumentPart4 = chartsMap.get("/word/charts/chart5.xml");
+        PoiWordTools.replacePieCharts(poixmlDocumentPart4, titleArr, fldNameArr, listItemsByType);
+
+
+        doCharts6(chartsMap);
+    }
+
+
+    public static void doCharts3(Map<String, POIXMLDocumentPart> chartsMap) {
+        // 数据准备
+        List<String> titleArr = new ArrayList<String>();// 标题
+        titleArr.add("姓名");
+        titleArr.add("欠款");
+        titleArr.add("存款");
+
+        List<String> fldNameArr = new ArrayList<String>();// 字段名
+        fldNameArr.add("item1");
+        fldNameArr.add("item2");
+        fldNameArr.add("item3");
+
+        // 数据集合
+        List<Map<String, String>> listItemsByType = new ArrayList<Map<String, String>>();
+
+        // 第一行数据
+        Map<String, String> base1 = new HashMap<String, String>();
+        base1.put("item1", "老张");
+        base1.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base1.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第二行数据
+        Map<String, String> base2 = new HashMap<String, String>();
+        base2.put("item1", "老李");
+        base2.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base2.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第三行数据
+        Map<String, String> base3 = new HashMap<String, String>();
+        base3.put("item1", "老刘");
+        base3.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base3.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+
+        listItemsByType.add(base1);
+        listItemsByType.add(base2);
+        listItemsByType.add(base3);
+
+        POIXMLDocumentPart poixmlDocumentPart2 = chartsMap.get("/word/charts/chart3.xml");
+        PoiWordTools.replaceBarCharts(poixmlDocumentPart2, titleArr, fldNameArr, listItemsByType);
+    }
+
+
+    public static void doCharts4(Map<String, POIXMLDocumentPart> chartsMap) {
+        // 数据准备
+        List<String> titleArr = new ArrayList<String>();// 标题
+        titleArr.add("title");
+        titleArr.add("占基金资产净值比例22222(%)");
+        titleArr.add("额外的(%)");
+        titleArr.add("额外的(%)");
+
+        List<String> fldNameArr = new ArrayList<String>();// 字段名
+        fldNameArr.add("item1");
+        fldNameArr.add("item2");
+        fldNameArr.add("item3");
+        fldNameArr.add("item4");
+
+        // 数据集合
+        List<Map<String, String>> listItemsByType = new ArrayList<Map<String, String>>();
+
+        // 第一行数据
+        Map<String, String> base1 = new HashMap<String, String>();
+        base1.put("item1", "材料费用");
+        base1.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base1.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base1.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第二行数据
+        Map<String, String> base2 = new HashMap<String, String>();
+        base2.put("item1", "出差费用");
+        base2.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base2.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base2.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第三行数据
+        Map<String, String> base3 = new HashMap<String, String>();
+        base3.put("item1", "住宿费用");
+        base3.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base3.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base3.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+
+        listItemsByType.add(base1);
+        listItemsByType.add(base2);
+        listItemsByType.add(base3);
+
+        POIXMLDocumentPart poixmlDocumentPart2 = chartsMap.get("/word/charts/chart4.xml");
+        PoiWordTools.replaceLineCharts(poixmlDocumentPart2, titleArr, fldNameArr, listItemsByType);
+    }
+
+
+    /**
+     * 对应文档中的第6个图表(预处理—分公司情况)
+     */
+    public static void doCharts6(Map<String, POIXMLDocumentPart> chartsMap) {
+        // 数据准备
+        List<String> titleArr = new ArrayList<String>();// 标题
+        titleArr.add("title");
+        titleArr.add("投诉受理量(次)");
+        titleArr.add("预处理拦截工单量(次)");
+        titleArr.add("拦截率");
+
+        List<String> fldNameArr = new ArrayList<String>();// 字段名
+        fldNameArr.add("item1");
+        fldNameArr.add("item2");
+        fldNameArr.add("item3");
+        fldNameArr.add("item4");
+
+        // 数据集合
+        List<Map<String, String>> listItemsByType = new ArrayList<Map<String, String>>();
+
+        // 第一行数据
+        Map<String, String> base1 = new HashMap<String, String>();
+        base1.put("item1", "通辽");
+        base1.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base1.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base1.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第二行数据
+        Map<String, String> base2 = new HashMap<String, String>();
+        base2.put("item1", "呼和浩特");
+        base2.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base2.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base2.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第三行数据
+        Map<String, String> base3 = new HashMap<String, String>();
+        base3.put("item1", "锡林郭勒");
+        base3.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base3.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base3.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第四行数据
+        Map<String, String> base4 = new HashMap<String, String>();
+        base4.put("item1", "阿拉善");
+        base4.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base4.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base4.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第五行数据
+        Map<String, String> base5 = new HashMap<String, String>();
+        base5.put("item1", "巴彦淖尔");
+        base5.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base5.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base5.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第六行数据
+        Map<String, String> base6 = new HashMap<String, String>();
+        base6.put("item1", "兴安");
+        base6.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base6.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base6.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第七行数据
+        Map<String, String> base7 = new HashMap<String, String>();
+        base7.put("item1", "乌兰察布");
+        base7.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base7.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base7.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第八行数据
+        Map<String, String> base8 = new HashMap<String, String>();
+        base8.put("item1", "乌海");
+        base8.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base8.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base8.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第九行数据
+        Map<String, String> base9 = new HashMap<String, String>();
+        base9.put("item1", "赤峰");
+        base9.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base9.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base9.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第十行数据
+        Map<String, String> base10 = new HashMap<String, String>();
+        base10.put("item1", "包头");
+        base10.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base10.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base10.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第十一行数据
+        Map<String, String> base11 = new HashMap<String, String>();
+        base11.put("item1", "呼伦贝尔");
+        base11.put("item2", (int) (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base11.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base11.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        // 第十二行数据
+        Map<String, String> base12 = new HashMap<String, String>();
+        base12.put("item1", "鄂尔多斯");
+        base12.put("item2", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base12.put("item3", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+        base12.put("item4", (int) (1 + Math.random() * (100 - 1 + 1)) + "");
+
+        listItemsByType.add(base1);
+        listItemsByType.add(base2);
+        listItemsByType.add(base3);
+        listItemsByType.add(base4);
+        listItemsByType.add(base5);
+        listItemsByType.add(base6);
+        listItemsByType.add(base7);
+        listItemsByType.add(base8);
+        listItemsByType.add(base9);
+        listItemsByType.add(base10);
+        listItemsByType.add(base11);
+        listItemsByType.add(base12);
+
+        // 下标0的图表-折线图
+        POIXMLDocumentPart poixmlDocumentPart5 = chartsMap.get("/word/charts/chart6.xml");
+        PoiWordTools.replaceCombinationCharts(poixmlDocumentPart5, titleArr, fldNameArr, listItemsByType);
+    }
+
+}
+

+ 642 - 0
src/main/java/com/izouma/wenlvju/service/poi/PoiWordTools.java

@@ -0,0 +1,642 @@
+package com.izouma.wenlvju.service.poi;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.math.BigDecimal;
+import java.math.BigInteger;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.poi.ooxml.POIXMLDocumentPart;
+import org.apache.poi.ss.usermodel.*;
+import org.apache.poi.ss.util.CellRangeAddress;
+import org.apache.poi.xssf.usermodel.XSSFWorkbook;
+import org.apache.poi.xwpf.usermodel.XWPFChart;
+import org.apache.poi.xwpf.usermodel.XWPFTableCell;
+import org.openxmlformats.schemas.drawingml.x2006.chart.*;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTColor;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTFonts;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTHpsMeasure;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTJc;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTOnOff;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTP;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTPPr;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTParaRPr;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTR;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTRPr;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTShd;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTc;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTTcPr;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTText;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.CTVerticalJc;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.STJc;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.STOnOff;
+import org.openxmlformats.schemas.wordprocessingml.x2006.main.STVerticalJc;
+
+/**
+ * poi生成word的工具类
+ * 针对于模板中的图表是静态的,也就是模板中的图表长什么样子不会根据数据而改变
+ */
+public class PoiWordTools {
+
+    private static final BigDecimal bd2 = new BigDecimal("2");
+
+
+    /**
+     * 调用替换柱状图数据
+     */
+    public static void replaceBarCharts(POIXMLDocumentPart poixmlDocumentPart,
+                                        List<String> titleArr, List<String> fldNameArr, List<Map<String, String>> listItemsByType) {
+        XWPFChart chart = (XWPFChart) poixmlDocumentPart;
+        chart.getCTChart();
+
+        //根据属性第一列名称切换数据类型
+        CTChart ctChart = chart.getCTChart();
+        CTPlotArea plotArea = ctChart.getPlotArea();
+
+        CTBarChart barChart = plotArea.getBarChartArray(0);
+        List<CTBarSer> BarSerList = barChart.getSerList();  // 获取柱状图单位
+
+        //刷新内置excel数据
+        PoiWordTools.refreshExcel(chart, listItemsByType, fldNameArr, titleArr);
+        //刷新页面显示数据
+        refreshBarStrGraphContent(barChart, BarSerList, listItemsByType, fldNameArr, 1);
+    }
+
+
+    /**
+     * 调用替换折线图数据
+     */
+    public static void replaceLineCharts(POIXMLDocumentPart poixmlDocumentPart,
+                                         List<String> titleArr, List<String> fldNameArr, List<Map<String, String>> listItemsByType) {
+        XWPFChart chart = (XWPFChart) poixmlDocumentPart;
+        chart.getCTChart();
+
+        //根据属性第一列名称切换数据类型
+        CTChart ctChart = chart.getCTChart();
+        CTPlotArea plotArea = ctChart.getPlotArea();
+
+        CTLineChart lineChart = plotArea.getLineChartArray(0);
+        List<CTLineSer> lineSerList = lineChart.getSerList();   // 获取折线图单位
+
+        //刷新内置excel数据
+        PoiWordTools.refreshExcel(chart, listItemsByType, fldNameArr, titleArr);
+        //刷新页面显示数据
+        PoiWordTools.refreshLineStrGraphContent(lineChart, lineSerList, listItemsByType, fldNameArr, 1);
+
+    }
+
+
+    /**
+     * 调用替换饼图数据
+     */
+    public static void replacePieCharts(POIXMLDocumentPart poixmlDocumentPart,
+                                        List<String> titleArr, List<String> fldNameArr, List<Map<String, String>> listItemsByType) {
+        XWPFChart chart = (XWPFChart) poixmlDocumentPart;
+        chart.getCTChart();
+
+        //根据属性第一列名称切换数据类型
+        CTChart ctChart = chart.getCTChart();
+        CTPlotArea plotArea = ctChart.getPlotArea();
+
+        CTPieChart pieChart = plotArea.getPieChartArray(0);
+        List<CTPieSer> pieSerList = pieChart.getSerList();  // 获取饼图单位
+
+        //刷新内置excel数据
+        PoiWordTools.refreshExcel(chart, listItemsByType, fldNameArr, titleArr);
+        //刷新页面显示数据
+        PoiWordTools.refreshPieStrGraphContent(pieChart, pieSerList, listItemsByType, fldNameArr, 1);
+
+    }
+
+
+    /**
+     * 调用替换柱状图、折线图组合数据
+     */
+    public static void replaceCombinationCharts(POIXMLDocumentPart poixmlDocumentPart,
+                                                List<String> titleArr, List<String> fldNameArr, List<Map<String, String>> listItemsByType) {
+        XWPFChart chart = (XWPFChart) poixmlDocumentPart;
+        chart.getCTChart();
+
+        //根据属性第一列名称切换数据类型
+        CTChart ctChart = chart.getCTChart();
+        CTPlotArea plotArea = ctChart.getPlotArea();
+
+
+        CTBarChart barChart = plotArea.getBarChartArray(0);
+        List<CTBarSer> barSerList = barChart.getSerList();  // 获取柱状图单位
+        //刷新内置excel数据
+        PoiWordTools.refreshExcel(chart, listItemsByType, fldNameArr, titleArr);
+        //刷新页面显示数据   数据中下标1开始的是柱状图数据,所以这个是1
+        refreshBarStrGraphContent(barChart, barSerList, listItemsByType, fldNameArr, 1);
+
+
+        CTLineChart lineChart = plotArea.getLineChartArray(0);
+        List<CTLineSer> lineSerList = lineChart.getSerList();   // 获取折线图单位
+        //刷新内置excel数据   有一个就可以了    有一个就可以了    有一个就可以了
+        //new PoiWordTools().refreshExcel(chart, listItemsByType, fldNameArr, titleArr);
+        //刷新页面显示数据   数据中下标3开始的是折线图的数据,所以这个是3
+        PoiWordTools.refreshLineStrGraphContent(lineChart, lineSerList, listItemsByType, fldNameArr, 3);
+
+    }
+
+
+    /**
+     * 刷新折线图数据方法
+     *
+     * @param typeChart
+     * @param serList
+     * @param dataList
+     * @param fldNameArr
+     * @param position
+     * @return
+     */
+    public static boolean refreshLineStrGraphContent(Object typeChart,
+                                                     List<?> serList, List<Map<String, String>> dataList, List<String> fldNameArr, int position) {
+
+        boolean result = true;
+        //更新数据区域
+        for (int i = 0; i < serList.size(); i++) {
+            //CTSerTx tx=null;
+            CTAxDataSource cat = null;
+            CTNumDataSource val = null;
+            CTLineSer ser = ((CTLineChart) typeChart).getSerArray(i);
+            //tx= ser.getTx();
+            // Category Axis Data
+            cat = ser.getCat();
+            // 获取图表的值
+            val = ser.getVal();
+            // strData.set
+            CTStrData strData = cat.getStrRef().getStrCache();
+            CTNumData numData = val.getNumRef().getNumCache();
+            strData.setPtArray((CTStrVal[]) null); // unset old axis text
+            numData.setPtArray((CTNumVal[]) null); // unset old values
+
+            // set model
+            long idx = 0;
+            for (int j = 0; j < dataList.size(); j++) {
+                //判断获取的值是否为空
+                String value = "0";
+                if (new BigDecimal(dataList.get(j).get(fldNameArr.get(i + position))) != null) {
+                    value = new BigDecimal(dataList.get(j).get(fldNameArr.get(i + position))).toString();
+                }
+                if (!"0".equals(value)) {
+                    CTNumVal numVal = numData.addNewPt();//序列值
+                    numVal.setIdx(idx);
+                    numVal.setV(value);
+                }
+                CTStrVal sVal = strData.addNewPt();//序列名称
+                sVal.setIdx(idx);
+                sVal.setV(dataList.get(j).get(fldNameArr.get(0)));
+                idx++;
+            }
+            numData.getPtCount().setVal(idx);
+            strData.getPtCount().setVal(idx);
+
+
+            //赋值横坐标数据区域
+            String axisDataRange = new CellRangeAddress(1, dataList.size(), 0, 0)
+                    .formatAsString("Sheet1", false);
+            cat.getStrRef().setF(axisDataRange);
+
+            //数据区域
+            String numDataRange = new CellRangeAddress(1, dataList.size(), i + position, i + position)
+                    .formatAsString("Sheet1", false);
+            val.getNumRef().setF(numDataRange);
+
+            // 设置系列生成方向
+
+
+        }
+        return result;
+    }
+
+
+    /**
+     * 刷新柱状图数据方法
+     *
+     * @param typeChart
+     * @param serList
+     * @param dataList
+     * @param fldNameArr
+     * @param position
+     * @return
+     */
+    public  static boolean refreshBarStrGraphContent(Object typeChart,
+                                                     List<?> serList, List<Map<String, String>> dataList, List<String> fldNameArr, int position) {
+        boolean result = true;
+        //更新数据区域
+        for (int i = 0; i < serList.size(); i++) {
+//            CTSerTx tx=null;
+            CTAxDataSource cat = null;
+            CTNumDataSource val = null;
+            CTBarSer ser = ((CTBarChart) typeChart).getSerArray(i);
+//            tx= ser.getTx();
+
+            // Category Axis Data
+            cat = ser.getCat();
+            // 获取图表的值
+            val = ser.getVal();
+            // strData.set
+            CTStrData strData = cat.getStrRef().getStrCache();
+            CTNumData numData = val.getNumRef().getNumCache();
+            strData.setPtArray((CTStrVal[]) null); // unset old axis text
+            numData.setPtArray((CTNumVal[]) null); // unset old values
+
+            // set model
+            long idx = 0;
+            for (int j = 0; j < dataList.size(); j++) {
+                //判断获取的值是否为空
+                String value = "0";
+                if (new BigDecimal(dataList.get(j).get(fldNameArr.get(i + position))) != null) {
+                    value = new BigDecimal(dataList.get(j).get(fldNameArr.get(i + position))).toString();
+                }
+                if (!"0".equals(value)) {
+                    CTNumVal numVal = numData.addNewPt();//序列值
+                    numVal.setIdx(idx);
+                    numVal.setV(value);
+                }
+                CTStrVal sVal = strData.addNewPt();//序列名称
+                sVal.setIdx(idx);
+                sVal.setV(dataList.get(j).get(fldNameArr.get(0)));
+                idx++;
+            }
+            numData.getPtCount().setVal(idx);
+            strData.getPtCount().setVal(idx);
+
+
+            //赋值横坐标数据区域
+            String axisDataRange = new CellRangeAddress(1, dataList.size(), 0, 0)
+                    .formatAsString("Sheet1", true);
+            cat.getStrRef().setF(axisDataRange);
+
+            //数据区域
+            String numDataRange = new CellRangeAddress(1, dataList.size(), i + position, i + position)
+                    .formatAsString("Sheet1", true);
+            val.getNumRef().setF(numDataRange);
+
+        }
+        return result;
+    }
+
+
+
+    /**
+     * 刷新饼图数据方法
+     *
+     * @param typeChart
+     * @param serList
+     * @param dataList
+     * @param fldNameArr
+     * @param position
+     * @return
+     */
+    public static boolean refreshPieStrGraphContent(Object typeChart,
+                                                    List<?> serList, List<Map<String, String>> dataList, List<String> fldNameArr, int position) {
+
+        boolean result = true;
+        //更新数据区域
+        for (int i = 0; i < serList.size(); i++) {
+            //CTSerTx tx=null;
+            CTAxDataSource cat = null;
+            CTNumDataSource val = null;
+            CTPieSer ser = ((CTPieChart) typeChart).getSerArray(i);
+
+            //tx= ser.getTx();
+            // Category Axis Data
+            cat = ser.getCat();
+            // 获取图表的值
+            val = ser.getVal();
+            // strData.set
+            CTStrData strData = cat.getStrRef().getStrCache();
+            CTNumData numData = val.getNumRef().getNumCache();
+            strData.setPtArray((CTStrVal[]) null); // unset old axis text
+            numData.setPtArray((CTNumVal[]) null); // unset old values
+
+            // set model
+            long idx = 0;
+            for (int j = 0; j < dataList.size(); j++) {
+                //判断获取的值是否为空
+                String value = "0";
+                if (new BigDecimal(dataList.get(j).get(fldNameArr.get(i + position))) != null) {
+                    value = new BigDecimal(dataList.get(j).get(fldNameArr.get(i + position))).toString();
+                }
+                if (!"0".equals(value)) {
+                    CTNumVal numVal = numData.addNewPt();//序列值
+                    numVal.setIdx(idx);
+                    numVal.setV(value);
+                }
+                CTStrVal sVal = strData.addNewPt();//序列名称
+                sVal.setIdx(idx);
+                sVal.setV(dataList.get(j).get(fldNameArr.get(0)));
+                idx++;
+            }
+            numData.getPtCount().setVal(idx);
+            strData.getPtCount().setVal(idx);
+
+
+            //赋值横坐标数据区域
+            String axisDataRange = new CellRangeAddress(1, dataList.size(), 0, 0)
+                    .formatAsString("Sheet1", true);
+            cat.getStrRef().setF(axisDataRange);
+
+            //数据区域
+            String numDataRange = new CellRangeAddress(1, dataList.size(), i + position, i + position)
+                    .formatAsString("Sheet1", true);
+            val.getNumRef().setF(numDataRange);
+        }
+        return result;
+    }
+
+
+    /**
+     * 刷新内置excel数据
+     *
+     * @param chart
+     * @param dataList
+     * @param fldNameArr
+     * @param titleArr
+     * @return
+     */
+    public static boolean refreshExcel(XWPFChart chart,
+                                       List<Map<String, String>> dataList, List<String> fldNameArr, List<String> titleArr) {
+        boolean result = true;
+        Workbook wb = new XSSFWorkbook();
+        Sheet sheet = wb.createSheet("Sheet1");
+        //根据数据创建excel第一行标题行
+        for (int i = 0; i < titleArr.size(); i++) {
+            if (sheet.getRow(0) == null) {
+                sheet.createRow(0).createCell(i).setCellValue(titleArr.get(i) == null ? "" : titleArr.get(i));
+            } else {
+                sheet.getRow(0).createCell(i).setCellValue(titleArr.get(i) == null ? "" : titleArr.get(i));
+            }
+        }
+
+        //遍历数据行
+        for (int i = 0; i < dataList.size(); i++) {
+            Map<String, String> baseFormMap = dataList.get(i);//数据行
+            //fldNameArr字段属性
+            for (int j = 0; j < fldNameArr.size(); j++) {
+                if (sheet.getRow(i + 1) == null) {
+                    if (j == 0) {
+                        try {
+                            sheet.createRow(i + 1).createCell(j).setCellValue(baseFormMap.get(fldNameArr.get(j)) == null ? "" : baseFormMap.get(fldNameArr.get(j)));
+                        } catch (Exception e) {
+                            if (baseFormMap.get(fldNameArr.get(j)) == null) {
+                                sheet.createRow(i + 1).createCell(j).setCellValue("");
+                            } else {
+                                sheet.createRow(i + 1).createCell(j).setCellValue(baseFormMap.get(fldNameArr.get(j)));
+                            }
+                        }
+                    }
+                } else {
+                    BigDecimal b = new BigDecimal(baseFormMap.get(fldNameArr.get(j)));
+                    double value = 0d;
+                    if (b != null) {
+                        value = b.doubleValue();
+                    }
+                    if (value == 0) {
+                        sheet.getRow(i + 1).createCell(j);
+                    } else {
+                        sheet.getRow(i + 1).createCell(j).setCellValue(b.doubleValue());
+                    }
+                }
+            }
+
+        }
+        // 更新嵌入的workbook
+        POIXMLDocumentPart xlsPart = chart.getRelations().get(0);
+        OutputStream xlsOut = xlsPart.getPackagePart().getOutputStream();
+
+        try {
+            wb.write(xlsOut);
+            xlsOut.close();
+        } catch (IOException e) {
+            e.printStackTrace();
+            result = false;
+        } finally {
+            if (wb != null) {
+                try {
+                    wb.close();
+                } catch (IOException e) {
+                    e.printStackTrace();
+                    result = false;
+                }
+            }
+        }
+        return result;
+    }
+
+
+    /**
+     * 设置表格样式
+     *
+     * @param cell
+     * @param fontName
+     * @param fontSize
+     * @param fontBlod
+     * @param alignment
+     * @param vertical
+     * @param fontColor
+     * @param bgColor
+     * @param cellWidth
+     * @param content
+     */
+    public static void setWordCellSelfStyle(XWPFTableCell cell, String fontName, String fontSize, int fontBlod,
+                                            String alignment, String vertical, String fontColor,
+                                            String bgColor, String cellWidth, String content) {
+
+        //poi对字体大小设置特殊,不支持小数,但对原word字体大小做了乘2处理
+        BigInteger bFontSize = new BigInteger("24");
+        if (fontSize != null && !fontSize.equals("")) {
+            //poi对字体大小设置特殊,不支持小数,但对原word字体大小做了乘2处理
+            BigDecimal fontSizeBD = new BigDecimal(fontSize);
+            fontSizeBD = bd2.multiply(fontSizeBD);
+            fontSizeBD = fontSizeBD.setScale(0, BigDecimal.ROUND_HALF_UP);//这里取整
+            bFontSize = new BigInteger(fontSizeBD.toString());// 字体大小
+        }
+
+        // 设置单元格宽度
+        cell.setWidth(cellWidth);
+
+        //=====获取单元格
+        CTTc tc = cell.getCTTc();
+        //====tcPr开始====》》》》
+        CTTcPr tcPr = tc.getTcPr();//获取单元格里的<w:tcPr>
+        if (tcPr == null) {//没有<w:tcPr>,创建
+            tcPr = tc.addNewTcPr();
+        }
+
+        //  --vjc开始-->>
+        CTVerticalJc vjc = tcPr.getVAlign();//获取<w:tcPr>  的<w:vAlign w:val="center"/>
+        if (vjc == null) {//没有<w:w:vAlign/>,创建
+            vjc = tcPr.addNewVAlign();
+        }
+        //设置单元格对齐方式
+        vjc.setVal(vertical.equals("top") ? STVerticalJc.TOP : vertical.equals("bottom") ? STVerticalJc.BOTTOM : STVerticalJc.CENTER); //垂直对齐
+
+        CTShd shd = tcPr.getShd();//获取<w:tcPr>里的<w:shd w:val="clear" w:color="auto" w:fill="C00000"/>
+        if (shd == null) {//没有<w:shd>,创建
+            shd = tcPr.addNewShd();
+        }
+        // 设置背景颜色
+        shd.setFill(bgColor.substring(1));
+        //《《《《====tcPr结束====
+
+        //====p开始====》》》》
+        CTP p = tc.getPList().get(0);//获取单元格里的<w:p w:rsidR="00C36068" w:rsidRPr="00B705A0" w:rsidRDefault="00C36068" w:rsidP="00C36068">
+
+        //---ppr开始--->>>
+        CTPPr ppr = p.getPPr();//获取<w:p>里的<w:pPr>
+        if (ppr == null) {//没有<w:pPr>,创建
+            ppr = p.addNewPPr();
+        }
+        //  --jc开始-->>
+        CTJc jc = ppr.getJc();//获取<w:pPr>里的<w:jc w:val="left"/>
+        if (jc == null) {//没有<w:jc/>,创建
+            jc = ppr.addNewJc();
+        }
+        //设置单元格对齐方式
+        jc.setVal(alignment.equals("left") ? STJc.LEFT : alignment.equals("right") ? STJc.RIGHT : STJc.CENTER); //水平对齐
+        //  <<--jc结束--
+        //  --pRpr开始-->>
+        CTParaRPr pRpr = ppr.getRPr(); //获取<w:pPr>里的<w:rPr>
+        if (pRpr == null) {//没有<w:rPr>,创建
+            pRpr = ppr.addNewRPr();
+        }
+        CTFonts pfont = pRpr.getRFonts();//获取<w:rPr>里的<w:rFonts w:ascii="宋体" w:eastAsia="宋体" w:hAnsi="宋体"/>
+        if (pfont == null) {//没有<w:rPr>,创建
+            pfont = pRpr.addNewRFonts();
+        }
+        //设置字体
+        pfont.setAscii(fontName);
+        pfont.setEastAsia(fontName);
+        pfont.setHAnsi(fontName);
+
+        CTOnOff pb = pRpr.getB();//获取<w:rPr>里的<w:b/>
+        if (pb == null) {//没有<w:b/>,创建
+            pb = pRpr.addNewB();
+        }
+        //设置字体是否加粗
+        pb.setVal(fontBlod == 1 ? STOnOff.ON : STOnOff.OFF);
+
+        CTHpsMeasure psz = pRpr.getSz();//获取<w:rPr>里的<w:sz w:val="32"/>
+        if (psz == null) {//没有<w:sz w:val="32"/>,创建
+            psz = pRpr.addNewSz();
+        }
+        // 设置单元格字体大小
+        psz.setVal(bFontSize);
+        CTHpsMeasure pszCs = pRpr.getSzCs();//获取<w:rPr>里的<w:szCs w:val="32"/>
+        if (pszCs == null) {//没有<w:szCs w:val="32"/>,创建
+            pszCs = pRpr.addNewSzCs();
+        }
+        // 设置单元格字体大小
+        pszCs.setVal(bFontSize);
+        //  <<--pRpr结束--
+        //<<<---ppr结束---
+
+        //---r开始--->>>
+        List<CTR> rlist = p.getRList(); //获取<w:p>里的<w:r w:rsidRPr="00B705A0">
+        CTR r = null;
+        if (rlist != null && rlist.size() > 0) {//获取第一个<w:r>
+            r = rlist.get(0);
+        } else {//没有<w:r>,创建
+            r = p.addNewR();
+        }
+        //--rpr开始-->>
+        CTRPr rpr = r.getRPr();//获取<w:r w:rsidRPr="00B705A0">里的<w:rPr>
+        if (rpr == null) {//没有<w:rPr>,创建
+            rpr = r.addNewRPr();
+        }
+        //->-
+        CTFonts font = rpr.getRFonts();//获取<w:rPr>里的<w:rFonts w:ascii="宋体" w:eastAsia="宋体" w:hAnsi="宋体" w:hint="eastAsia"/>
+        if (font == null) {//没有<w:rFonts>,创建
+            font = rpr.addNewRFonts();
+        }
+        //设置字体
+        font.setAscii(fontName);
+        font.setEastAsia(fontName);
+        font.setHAnsi(fontName);
+
+        CTOnOff b = rpr.getB();//获取<w:rPr>里的<w:b/>
+        if (b == null) {//没有<w:b/>,创建
+            b = rpr.addNewB();
+        }
+        //设置字体是否加粗
+        b.setVal(fontBlod == 1 ? STOnOff.ON : STOnOff.OFF);
+        CTColor color = rpr.getColor();//获取<w:rPr>里的<w:color w:val="FFFFFF" w:themeColor="background1"/>
+        if (color == null) {//没有<w:color>,创建
+            color = rpr.addNewColor();
+        }
+        // 设置字体颜色
+        if (content.contains("↓")) {
+            color.setVal("43CD80");
+        } else if (content.contains("↑")) {
+            color.setVal("943634");
+        } else {
+            color.setVal(fontColor.substring(1));
+        }
+        CTHpsMeasure sz = rpr.getSz();
+        if (sz == null) {
+            sz = rpr.addNewSz();
+        }
+        sz.setVal(bFontSize);
+        CTHpsMeasure szCs = rpr.getSzCs();
+        if (szCs == null) {
+            szCs = rpr.addNewSz();
+        }
+        szCs.setVal(bFontSize);
+        //-<-
+        //<<--rpr结束--
+        List<CTText> tlist = r.getTList();
+        CTText t = null;
+        if (tlist != null && tlist.size() > 0) {//获取第一个<w:r>
+            t = tlist.get(0);
+        } else {//没有<w:r>,创建
+            t = r.addNewT();
+        }
+        t.setStringValue(content);
+        //<<<---r结束---
+    }
+
+
+    /**
+     * 获取内置表格数据,拿到第一行第一列格子数据
+     * 有时候模板设计太复杂,对于图表不能精准定位,可以通过设置图表表格数据的第一行第一列格子数据来区分,这个数据不影响图表显示,所以用来区分每个图表
+     */
+    public static String getZeroData(POIXMLDocumentPart poixmlDocumentPart){
+        String text = "";
+        try {
+            XWPFChart chart = (XWPFChart) poixmlDocumentPart;
+            chart.getCTChart();
+
+            POIXMLDocumentPart xlsPart = chart.getRelations().get(0);
+            InputStream xlsin = xlsPart.getPackagePart().getInputStream();
+
+            Workbook workbook = new XSSFWorkbook(xlsin);
+            // 获取第一个sheet
+            Sheet sheet = workbook.getSheetAt(0);
+            // 第一行
+            Row row = sheet.getRow(0);
+            // 第一列
+            Cell cell = row.getCell(0);
+
+            cell.setCellType(CellType.STRING);  // 设置一下格子类型为字符串,不然如果是数字或者时间的话,获取很麻烦
+            text = cell.getStringCellValue();   // 获取格子内容
+
+            System.out.println("(0,0)格子值:" + text);
+
+            // 关闭流
+            xlsin.close();
+
+        } catch (Exception e) {
+            e.printStackTrace();
+        }
+
+
+        return text;
+    }
+
+
+}

+ 45 - 7
src/main/java/com/izouma/wenlvju/service/regulation/ReportService.java

@@ -22,6 +22,7 @@ import com.izouma.wenlvju.repo.regulation.RecordExpertAuditRepo;
 import com.izouma.wenlvju.repo.regulation.ReportRepo;
 import com.izouma.wenlvju.repo.regulation.ReportStatisticRepo;
 import com.izouma.wenlvju.service.storage.StorageService;
+import com.izouma.wenlvju.utils.ChartUtils;
 import com.izouma.wenlvju.utils.JpaUtils;
 import freemarker.template.Configuration;
 import freemarker.template.Template;
@@ -31,12 +32,12 @@ import lombok.AllArgsConstructor;
 import lombok.extern.slf4j.Slf4j;
 import org.apache.commons.io.IOUtils;
 import org.apache.commons.lang3.RandomStringUtils;
+import org.apache.poi.xwpf.usermodel.XWPFChart;
+import org.apache.poi.xwpf.usermodel.XWPFDocument;
 import org.springframework.data.domain.Page;
 import org.springframework.stereotype.Service;
 
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.StringWriter;
+import java.io.*;
 import java.text.SimpleDateFormat;
 import java.time.LocalDate;
 import java.time.LocalDateTime;
@@ -63,7 +64,11 @@ public class ReportService {
         return reportRepo.findAll(JpaUtils.toSpecification(pageQuery, Report.class), JpaUtils.toPageRequest(pageQuery));
     }
 
-    //获取时间
+    /**
+     * 获取时间
+     * @param report
+     * @return
+     */
     public Map<String, Object> getDate(Report report) {
         //开始结束时间
         int year = report.getYear();
@@ -328,8 +333,11 @@ public class ReportService {
         return linkedHashMap;
     }
 
-    /*
-    生成word
+    /**
+     * 生成word
+     * @param report
+     * @throws IOException
+     * @throws TemplateException
      */
     public void word(Report report) throws IOException, TemplateException {
         // 开始结束时间
@@ -373,6 +381,9 @@ public class ReportService {
         //各专业统计
         List<NumOfReport> specialty = this.getSpecialty(recordSpecialties);
         specialty.forEach(num -> dataMap.put(num.getName(), num.getNum()));
+        //画图
+        Map<String, Integer> specialtyMap = specialty.stream()
+                .collect(Collectors.toMap(NumOfReport::getName, NumOfReport::getNum));
 
         //考级机构/承办单位统计
         List<ReportStatistic> reportDTOS = this.generate(records, complains);
@@ -412,10 +423,11 @@ public class ReportService {
         configuration.setDefaultEncoding("utf-8");
         configuration.setClassForTemplateLoading(this.getClass(), "/templates");//指定ftl所在目录,根据自己的改
         StringWriter writer = new StringWriter();
-        Template template = configuration.getTemplate("ReportTemplate.ftl", "utf-8");//以utf-8的编码读取ftl文件
+        Template template = configuration.getTemplate("Report.ftl", "utf-8");//以utf-8的编码读取ftl文件
         template.process(dataMap, writer);
 
         InputStream is = IOUtils.toInputStream(writer.toString(), "UTF-8");
+
         String url = storageService.uploadFromInputStream(is, "word" + "/" + new SimpleDateFormat("yyyy-MM-dd-HH-mm-ss").format(new Date())
                 + RandomStringUtils.randomAlphabetic(8) + ".docx");
 
@@ -430,4 +442,30 @@ public class ReportService {
                 .collect(Collectors.toList());
         reportStatisticRepo.saveAll(statistics);
     }
+
+    /*
+    画图
+     */
+    public XWPFDocument chart(Map<String, Integer> value, String filename, String chartTitle) throws IOException {
+
+        InputStream is = getClass().getResourceAsStream(filename);
+        XWPFDocument doc = new XWPFDocument(is);
+
+        //模拟统计图数据
+        //系列
+        String[] seriesTitles = {chartTitle};
+        //x轴
+        String[] categories = value.keySet().toArray(new String[0]);
+        List<Number[]> values = new ArrayList<>();
+        //值
+        Number[] value1 = value.values().toArray(new Integer[0]);
+        values.add(value1);
+
+        XWPFChart xChart = doc.getCharts().get(0);//获取第1个图表
+        ChartUtils.generateChart(xChart, seriesTitles, categories, values, chartTitle + "统计");
+//        try (FileOutputStream fos = new FileOutputStream("/Users/qiufangchao/Desktop/test.docx")) {
+//            doc.write(fos);
+//        }
+        return doc;
+    }
 }

+ 60 - 0
src/main/java/com/izouma/wenlvju/utils/ChartUtils.java

@@ -0,0 +1,60 @@
+package com.izouma.wenlvju.utils;
+
+import org.apache.poi.ss.util.CellRangeAddress;
+import org.apache.poi.ss.util.CellReference;
+import org.apache.poi.xddf.usermodel.chart.*;
+import org.apache.poi.xwpf.usermodel.XWPFChart;
+
+import java.util.List;
+
+public class ChartUtils {
+    public static void lineChart(XWPFChart chart, String[] series, String[] categories, List<Number[]> values, String chartTitle) {
+        final List<XDDFChartData> data = chart.getChartSeries();//不知道这个ChartSeries代表什么意思
+        final XDDFLineChartData line = (XDDFLineChartData) data.get(0);//这里一般获取第一个,我们这里是折线图就是XDDFLineChartData
+
+        final int numOfPoints = categories.length;
+
+        final String categoryDataRange = chart.formatRange(new CellRangeAddress(1, numOfPoints, 0, 0));
+
+        final XDDFDataSource<?> categoriesData = XDDFDataSourcesFactory.fromArray(categories, categoryDataRange, 0);
+        for (int i = 0; i < values.size(); i++) {
+            final String valuesDataRange = chart.formatRange(new CellRangeAddress(1, numOfPoints, i + 1, i + 1));
+            Number[] value = values.get(i);
+            final XDDFNumericalDataSource<? extends Number> valuesData = XDDFDataSourcesFactory.fromArray(value, valuesDataRange, i + 1);
+            XDDFChartData.Series ser;//图表中的系列
+            ser = line.getSeries().get(i);
+            ser.replaceData(categoriesData, valuesData);
+            CellReference cellReference = chart.setSheetTitle(series[i], 1);//修改系列标题
+            ser.setTitle(series[i], cellReference);
+        }
+
+        chart.plot(line);
+        chart.setTitleText(chartTitle);//折线图标题
+        chart.setTitleOverlay(false);
+    }
+
+    public static void generateChart(XWPFChart chart, String[] series, String[] categories, List<Number[]> values, String chartTitle) {
+        final List<XDDFChartData> data = chart.getChartSeries();
+        final XDDFChartData chartData = data.get(0);
+
+        final int numOfPoints = categories.length;
+
+        final String categoryDataRange = chart.formatRange(new CellRangeAddress(1, numOfPoints, 0, 0));
+
+        final XDDFDataSource<?> categoriesData = XDDFDataSourcesFactory.fromArray(categories, categoryDataRange, 0);
+        for (int i = 0; i < values.size(); i++) {
+            final String valuesDataRange = chart.formatRange(new CellRangeAddress(1, numOfPoints, i + 1, i + 1));
+            Number[] value = values.get(i);
+            final XDDFNumericalDataSource<? extends Number> valuesData = XDDFDataSourcesFactory.fromArray(value, valuesDataRange, i + 1);
+            XDDFChartData.Series ser;//图表中的系列
+            ser = chartData.getSeries().get(i);
+            ser.replaceData(categoriesData, valuesData);
+            CellReference cellReference = chart.setSheetTitle(series[i], 1);//修改系列标题
+            ser.setTitle(series[i], cellReference);
+        }
+
+        chart.plot(chartData);
+        chart.setTitleText(chartTitle);//折线图标题
+        chart.setTitleOverlay(false);
+    }
+}

+ 2118 - 0
src/main/resources/templates/Report.ftl

@@ -0,0 +1,2118 @@
+<?xml version="1.0" encoding="utf-8"?>
+<?mso-application progid="Word.Document"?>
+
+<w:wordDocument xmlns:w="http://schemas.microsoft.com/office/word/2003/wordml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:w10="urn:schemas-microsoft-com:office:word" xmlns:sl="http://schemas.microsoft.com/schemaLibrary/2003/core" xmlns:aml="http://schemas.microsoft.com/aml/2001/core" xmlns:wx="http://schemas.microsoft.com/office/word/2003/auxHint" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" w:macrosPresent="no" w:embeddedObjPresent="no" w:ocxPresent="no" xml:space="preserve">
+  <o:DocumentProperties>
+    <o:Author>qiufangchao</o:Author>
+    <o:LastAuthor>qiufangchao</o:LastAuthor>
+    <o:Revision>1</o:Revision>
+    <o:Created>2021-12-05T07:16:00Z</o:Created>
+    <o:LastSaved>2021-12-09T14:33:18Z</o:LastSaved>
+    <o:Pages>1</o:Pages>
+    <o:Words>0</o:Words>
+    <o:Characters>0</o:Characters>
+    <o:Lines>0</o:Lines>
+    <o:Paragraphs>0</o:Paragraphs>
+    <o:CharactersWithSpaces>0</o:CharactersWithSpaces>
+  </o:DocumentProperties>
+  <o:CustomDocumentProperties>
+    <o:KSOProductBuildVer dt:dt="string">2052-3.9.0.6159</o:KSOProductBuildVer>
+  </o:CustomDocumentProperties>
+  <w:fonts>
+    <w:defaultFonts w:ascii="Times New Roman" w:fareast="宋体" w:h-ansi="Times New Roman" w:cs="Times New Roman"/>
+    <w:font w:name="Times New Roman">
+      <w:panose-1 w:val="02020603050405020304"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="E0002AEF" w:usb-1="C0007841" w:usb-2="00000009" w:usb-3="00000000" w:csb-0="400001FF" w:csb-1="FFFF0000"/>
+    </w:font>
+    <w:font w:name="宋体">
+      <w:altName w:val="汉仪书宋二KW"/>
+      <w:panose-1 w:val="00000000000000000000"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="00000000" w:usb-1="00000000" w:usb-2="00000000" w:usb-3="00000000" w:csb-0="00000000" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="DejaVu Sans">
+      <w:altName w:val="苹方-简"/>
+      <w:panose-1 w:val="02020603050405020304"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Roman"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="20007A87" w:usb-1="80000000" w:usb-2="00000008" w:usb-3="00000000" w:csb-0="000001FF" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="方正书宋_GBK">
+      <w:panose-1 w:val="02000000000000000000"/>
+      <w:charset w:val="86"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="A00002BF" w:usb-1="38CF7CFA" w:usb-2="00082016" w:usb-3="00000000" w:csb-0="00040001" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="方正黑体_GBK">
+      <w:altName w:val="苹方-简"/>
+      <w:panose-1 w:val="02000000000000000000"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="00000001" w:usb-1="08000000" w:usb-2="00000000" w:usb-3="00000000" w:csb-0="00040000" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="Cambria">
+      <w:altName w:val="苹方-简"/>
+      <w:panose-1 w:val="02040503050406030204"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Roman"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="00000000" w:usb-1="00000000" w:usb-2="00000000" w:usb-3="00000000" w:csb-0="0000019F" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="Calibri">
+      <w:altName w:val="Helvetica Neue"/>
+      <w:panose-1 w:val="020F0502020204030204"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="SWiss"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="00000000" w:usb-1="00000000" w:usb-2="00000001" w:usb-3="00000000" w:csb-0="0000019F" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="汉仪书宋二KW">
+      <w:panose-1 w:val="00020600040101010101"/>
+      <w:charset w:val="86"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="A00002BF" w:usb-1="18EF7CFA" w:usb-2="00000016" w:usb-3="00000000" w:csb-0="00040000" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="苹方-简">
+      <w:panose-1 w:val="020B0400000000000000"/>
+      <w:charset w:val="86"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="A00002FF" w:usb-1="7ACFFDFB" w:usb-2="00000017" w:usb-3="00000000" w:csb-0="00040001" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="Helvetica Neue">
+      <w:panose-1 w:val="02000503000000020004"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="E50002FF" w:usb-1="500079DB" w:usb-2="00000010" w:usb-3="00000000" w:csb-0="00000000" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="Droid Sans Mono">
+      <w:altName w:val="苹方-简"/>
+      <w:panose-1 w:val="00000000000000000000"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="00000000" w:usb-1="00000000" w:usb-2="00000000" w:usb-3="00000000" w:csb-0="00000000" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="Calibri Light">
+      <w:altName w:val="Helvetica Neue"/>
+      <w:panose-1 w:val="00000000000000000000"/>
+      <w:charset w:val="00"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="00000000" w:usb-1="00000000" w:usb-2="00000000" w:usb-3="00000000" w:csb-0="00000000" w:csb-1="00000000"/>
+    </w:font>
+    <w:font w:name="宋体-简">
+      <w:panose-1 w:val="02010800040101010101"/>
+      <w:charset w:val="86"/>
+      <w:family w:val="Auto"/>
+      <w:pitch w:val="Default"/>
+      <w:sig w:usb-0="00000001" w:usb-1="080F0000" w:usb-2="00000000" w:usb-3="00000000" w:csb-0="00040000" w:csb-1="00000000"/>
+    </w:font>
+  </w:fonts>
+  <w:lists>
+    <w:listDef w:listDefId="0">
+      <w:plt w:val="SingleLevel"/>
+      <w:lvl w:ilvl="0">
+        <w:start w:val="5"/>
+        <w:nfc w:val="37"/>
+        <w:suff w:val="Nothing"/>
+        <w:lvlText w:val="%1、"/>
+        <w:lvlJc w:val="left"/>
+      </w:lvl>
+    </w:listDef>
+    <w:listDef w:listDefId="1">
+      <w:plt w:val="SingleLevel"/>
+      <w:lvl w:ilvl="0">
+        <w:start w:val="1"/>
+        <w:nfc w:val="37"/>
+        <w:suff w:val="Nothing"/>
+        <w:lvlText w:val="%1、"/>
+        <w:lvlJc w:val="left"/>
+      </w:lvl>
+    </w:listDef>
+    <w:list w:ilfo="1">
+      <w:ilst w:val="1"/>
+    </w:list>
+    <w:list w:ilfo="2">
+      <w:ilst w:val="0"/>
+    </w:list>
+  </w:lists>
+  <w:styles>
+    <w:latentStyles w:defLockedState="off" w:latentStyleCount="260">
+      <w:lsdException w:name="Normal"/>
+      <w:lsdException w:name="heading 1"/>
+      <w:lsdException w:name="heading 2"/>
+      <w:lsdException w:name="heading 3"/>
+      <w:lsdException w:name="heading 4"/>
+      <w:lsdException w:name="heading 5"/>
+      <w:lsdException w:name="heading 6"/>
+      <w:lsdException w:name="heading 7"/>
+      <w:lsdException w:name="heading 8"/>
+      <w:lsdException w:name="heading 9"/>
+      <w:lsdException w:name="index 1"/>
+      <w:lsdException w:name="index 2"/>
+      <w:lsdException w:name="index 3"/>
+      <w:lsdException w:name="index 4"/>
+      <w:lsdException w:name="index 5"/>
+      <w:lsdException w:name="index 6"/>
+      <w:lsdException w:name="index 7"/>
+      <w:lsdException w:name="index 8"/>
+      <w:lsdException w:name="index 9"/>
+      <w:lsdException w:name="toc 1"/>
+      <w:lsdException w:name="toc 2"/>
+      <w:lsdException w:name="toc 3"/>
+      <w:lsdException w:name="toc 4"/>
+      <w:lsdException w:name="toc 5"/>
+      <w:lsdException w:name="toc 6"/>
+      <w:lsdException w:name="toc 7"/>
+      <w:lsdException w:name="toc 8"/>
+      <w:lsdException w:name="toc 9"/>
+      <w:lsdException w:name="Normal Indent"/>
+      <w:lsdException w:name="footnote text"/>
+      <w:lsdException w:name="annotation text"/>
+      <w:lsdException w:name="header"/>
+      <w:lsdException w:name="footer"/>
+      <w:lsdException w:name="index heading"/>
+      <w:lsdException w:name="caption"/>
+      <w:lsdException w:name="table of figures"/>
+      <w:lsdException w:name="envelope address"/>
+      <w:lsdException w:name="envelope return"/>
+      <w:lsdException w:name="footnote reference"/>
+      <w:lsdException w:name="annotation reference"/>
+      <w:lsdException w:name="line number"/>
+      <w:lsdException w:name="page number"/>
+      <w:lsdException w:name="endnote reference"/>
+      <w:lsdException w:name="endnote text"/>
+      <w:lsdException w:name="table of authorities"/>
+      <w:lsdException w:name="macro"/>
+      <w:lsdException w:name="toa heading"/>
+      <w:lsdException w:name="List"/>
+      <w:lsdException w:name="List Bullet"/>
+      <w:lsdException w:name="List Number"/>
+      <w:lsdException w:name="List 2"/>
+      <w:lsdException w:name="List 3"/>
+      <w:lsdException w:name="List 4"/>
+      <w:lsdException w:name="List 5"/>
+      <w:lsdException w:name="List Bullet 2"/>
+      <w:lsdException w:name="List Bullet 3"/>
+      <w:lsdException w:name="List Bullet 4"/>
+      <w:lsdException w:name="List Bullet 5"/>
+      <w:lsdException w:name="List Number 2"/>
+      <w:lsdException w:name="List Number 3"/>
+      <w:lsdException w:name="List Number 4"/>
+      <w:lsdException w:name="List Number 5"/>
+      <w:lsdException w:name="Title"/>
+      <w:lsdException w:name="Closing"/>
+      <w:lsdException w:name="Signature"/>
+      <w:lsdException w:name="Default Paragraph Font"/>
+      <w:lsdException w:name="Body Text"/>
+      <w:lsdException w:name="Body Text Indent"/>
+      <w:lsdException w:name="List Continue"/>
+      <w:lsdException w:name="List Continue 2"/>
+      <w:lsdException w:name="List Continue 3"/>
+      <w:lsdException w:name="List Continue 4"/>
+      <w:lsdException w:name="List Continue 5"/>
+      <w:lsdException w:name="Message Header"/>
+      <w:lsdException w:name="Subtitle"/>
+      <w:lsdException w:name="Salutation"/>
+      <w:lsdException w:name="Date"/>
+      <w:lsdException w:name="Body Text First Indent"/>
+      <w:lsdException w:name="Body Text First Indent 2"/>
+      <w:lsdException w:name="Note Heading"/>
+      <w:lsdException w:name="Body Text 2"/>
+      <w:lsdException w:name="Body Text 3"/>
+      <w:lsdException w:name="Body Text Indent 2"/>
+      <w:lsdException w:name="Body Text Indent 3"/>
+      <w:lsdException w:name="Block Text"/>
+      <w:lsdException w:name="Hyperlink"/>
+      <w:lsdException w:name="FollowedHyperlink"/>
+      <w:lsdException w:name="Strong"/>
+      <w:lsdException w:name="Emphasis"/>
+      <w:lsdException w:name="Document Map"/>
+      <w:lsdException w:name="Plain Text"/>
+      <w:lsdException w:name="E-mail Signature"/>
+      <w:lsdException w:name="Normal (Web)"/>
+      <w:lsdException w:name="HTML Acronym"/>
+      <w:lsdException w:name="HTML Address"/>
+      <w:lsdException w:name="HTML Cite"/>
+      <w:lsdException w:name="HTML Code"/>
+      <w:lsdException w:name="HTML Definition"/>
+      <w:lsdException w:name="HTML Keyboard"/>
+      <w:lsdException w:name="HTML Preformatted"/>
+      <w:lsdException w:name="HTML Sample"/>
+      <w:lsdException w:name="HTML Typewriter"/>
+      <w:lsdException w:name="HTML Variable"/>
+      <w:lsdException w:name="Normal Table"/>
+      <w:lsdException w:name="annotation subject"/>
+      <w:lsdException w:name="Table Simple 1"/>
+      <w:lsdException w:name="Table Simple 2"/>
+      <w:lsdException w:name="Table Simple 3"/>
+      <w:lsdException w:name="Table Classic 1"/>
+      <w:lsdException w:name="Table Classic 2"/>
+      <w:lsdException w:name="Table Classic 3"/>
+      <w:lsdException w:name="Table Classic 4"/>
+      <w:lsdException w:name="Table Colorful 1"/>
+      <w:lsdException w:name="Table Colorful 2"/>
+      <w:lsdException w:name="Table Colorful 3"/>
+      <w:lsdException w:name="Table Columns 1"/>
+      <w:lsdException w:name="Table Columns 2"/>
+      <w:lsdException w:name="Table Columns 3"/>
+      <w:lsdException w:name="Table Columns 4"/>
+      <w:lsdException w:name="Table Columns 5"/>
+      <w:lsdException w:name="Table Grid 1"/>
+      <w:lsdException w:name="Table Grid 2"/>
+      <w:lsdException w:name="Table Grid 3"/>
+      <w:lsdException w:name="Table Grid 4"/>
+      <w:lsdException w:name="Table Grid 5"/>
+      <w:lsdException w:name="Table Grid 6"/>
+      <w:lsdException w:name="Table Grid 7"/>
+      <w:lsdException w:name="Table Grid 8"/>
+      <w:lsdException w:name="Table List 1"/>
+      <w:lsdException w:name="Table List 2"/>
+      <w:lsdException w:name="Table List 3"/>
+      <w:lsdException w:name="Table List 4"/>
+      <w:lsdException w:name="Table List 5"/>
+      <w:lsdException w:name="Table List 6"/>
+      <w:lsdException w:name="Table List 7"/>
+      <w:lsdException w:name="Table List 8"/>
+      <w:lsdException w:name="Table 3D effects 1"/>
+      <w:lsdException w:name="Table 3D effects 2"/>
+      <w:lsdException w:name="Table 3D effects 3"/>
+      <w:lsdException w:name="Table Contemporary"/>
+      <w:lsdException w:name="Table Elegant"/>
+      <w:lsdException w:name="Table Professional"/>
+      <w:lsdException w:name="Table Subtle 1"/>
+      <w:lsdException w:name="Table Subtle 2"/>
+      <w:lsdException w:name="Table Web 1"/>
+      <w:lsdException w:name="Table Web 2"/>
+      <w:lsdException w:name="Table Web 3"/>
+      <w:lsdException w:name="Balloon Text"/>
+      <w:lsdException w:name="Table Grid"/>
+      <w:lsdException w:name="Table Theme"/>
+      <w:lsdException w:name="Light Shading"/>
+      <w:lsdException w:name="Light List"/>
+      <w:lsdException w:name="Light Grid"/>
+      <w:lsdException w:name="Medium Shading 1"/>
+      <w:lsdException w:name="Medium Shading 2"/>
+      <w:lsdException w:name="Medium List 1"/>
+      <w:lsdException w:name="Medium List 2"/>
+      <w:lsdException w:name="Medium Grid 1"/>
+      <w:lsdException w:name="Medium Grid 2"/>
+      <w:lsdException w:name="Medium Grid 3"/>
+      <w:lsdException w:name="Dark List"/>
+      <w:lsdException w:name="Colorful Shading"/>
+      <w:lsdException w:name="Colorful List"/>
+      <w:lsdException w:name="Colorful Grid"/>
+      <w:lsdException w:name="Light Shading Accent 1"/>
+      <w:lsdException w:name="Light List Accent 1"/>
+      <w:lsdException w:name="Light Grid Accent 1"/>
+      <w:lsdException w:name="Medium Shading 1 Accent 1"/>
+      <w:lsdException w:name="Medium Shading 2 Accent 1"/>
+      <w:lsdException w:name="Medium List 1 Accent 1"/>
+      <w:lsdException w:name="Medium List 2 Accent 1"/>
+      <w:lsdException w:name="Medium Grid 1 Accent 1"/>
+      <w:lsdException w:name="Medium Grid 2 Accent 1"/>
+      <w:lsdException w:name="Medium Grid 3 Accent 1"/>
+      <w:lsdException w:name="Dark List Accent 1"/>
+      <w:lsdException w:name="Colorful Shading Accent 1"/>
+      <w:lsdException w:name="Colorful List Accent 1"/>
+      <w:lsdException w:name="Colorful Grid Accent 1"/>
+      <w:lsdException w:name="Light Shading Accent 2"/>
+      <w:lsdException w:name="Light List Accent 2"/>
+      <w:lsdException w:name="Light Grid Accent 2"/>
+      <w:lsdException w:name="Medium Shading 1 Accent 2"/>
+      <w:lsdException w:name="Medium Shading 2 Accent 2"/>
+      <w:lsdException w:name="Medium List 1 Accent 2"/>
+      <w:lsdException w:name="Medium List 2 Accent 2"/>
+      <w:lsdException w:name="Medium Grid 1 Accent 2"/>
+      <w:lsdException w:name="Medium Grid 2 Accent 2"/>
+      <w:lsdException w:name="Medium Grid 3 Accent 2"/>
+      <w:lsdException w:name="Dark List Accent 2"/>
+      <w:lsdException w:name="Colorful Shading Accent 2"/>
+      <w:lsdException w:name="Colorful List Accent 2"/>
+      <w:lsdException w:name="Colorful Grid Accent 2"/>
+      <w:lsdException w:name="Light Shading Accent 3"/>
+      <w:lsdException w:name="Light List Accent 3"/>
+      <w:lsdException w:name="Light Grid Accent 3"/>
+      <w:lsdException w:name="Medium Shading 1 Accent 3"/>
+      <w:lsdException w:name="Medium Shading 2 Accent 3"/>
+      <w:lsdException w:name="Medium List 1 Accent 3"/>
+      <w:lsdException w:name="Medium List 2 Accent 3"/>
+      <w:lsdException w:name="Medium Grid 1 Accent 3"/>
+      <w:lsdException w:name="Medium Grid 2 Accent 3"/>
+      <w:lsdException w:name="Medium Grid 3 Accent 3"/>
+      <w:lsdException w:name="Dark List Accent 3"/>
+      <w:lsdException w:name="Colorful Shading Accent 3"/>
+      <w:lsdException w:name="Colorful List Accent 3"/>
+      <w:lsdException w:name="Colorful Grid Accent 3"/>
+      <w:lsdException w:name="Light Shading Accent 4"/>
+      <w:lsdException w:name="Light List Accent 4"/>
+      <w:lsdException w:name="Light Grid Accent 4"/>
+      <w:lsdException w:name="Medium Shading 1 Accent 4"/>
+      <w:lsdException w:name="Medium Shading 2 Accent 4"/>
+      <w:lsdException w:name="Medium List 1 Accent 4"/>
+      <w:lsdException w:name="Medium List 2 Accent 4"/>
+      <w:lsdException w:name="Medium Grid 1 Accent 4"/>
+      <w:lsdException w:name="Medium Grid 2 Accent 4"/>
+      <w:lsdException w:name="Medium Grid 3 Accent 4"/>
+      <w:lsdException w:name="Dark List Accent 4"/>
+      <w:lsdException w:name="Colorful Shading Accent 4"/>
+      <w:lsdException w:name="Colorful List Accent 4"/>
+      <w:lsdException w:name="Colorful Grid Accent 4"/>
+      <w:lsdException w:name="Light Shading Accent 5"/>
+      <w:lsdException w:name="Light List Accent 5"/>
+      <w:lsdException w:name="Light Grid Accent 5"/>
+      <w:lsdException w:name="Medium Shading 1 Accent 5"/>
+      <w:lsdException w:name="Medium Shading 2 Accent 5"/>
+      <w:lsdException w:name="Medium List 1 Accent 5"/>
+      <w:lsdException w:name="Medium List 2 Accent 5"/>
+      <w:lsdException w:name="Medium Grid 1 Accent 5"/>
+      <w:lsdException w:name="Medium Grid 2 Accent 5"/>
+      <w:lsdException w:name="Medium Grid 3 Accent 5"/>
+      <w:lsdException w:name="Dark List Accent 5"/>
+      <w:lsdException w:name="Colorful Shading Accent 5"/>
+      <w:lsdException w:name="Colorful List Accent 5"/>
+      <w:lsdException w:name="Colorful Grid Accent 5"/>
+      <w:lsdException w:name="Light Shading Accent 6"/>
+      <w:lsdException w:name="Light List Accent 6"/>
+      <w:lsdException w:name="Light Grid Accent 6"/>
+      <w:lsdException w:name="Medium Shading 1 Accent 6"/>
+      <w:lsdException w:name="Medium Shading 2 Accent 6"/>
+      <w:lsdException w:name="Medium List 1 Accent 6"/>
+      <w:lsdException w:name="Medium List 2 Accent 6"/>
+      <w:lsdException w:name="Medium Grid 1 Accent 6"/>
+      <w:lsdException w:name="Medium Grid 2 Accent 6"/>
+      <w:lsdException w:name="Medium Grid 3 Accent 6"/>
+      <w:lsdException w:name="Dark List Accent 6"/>
+      <w:lsdException w:name="Colorful Shading Accent 6"/>
+      <w:lsdException w:name="Colorful List Accent 6"/>
+      <w:lsdException w:name="Colorful Grid Accent 6"/>
+    </w:latentStyles>
+    <w:style w:type="paragraph" w:styleId="a1" w:default="on">
+      <w:name w:val="Normal"/>
+      <w:pPr>
+        <w:widowControl w:val="off"/>
+        <w:jc w:val="both"/>
+      </w:pPr>
+      <w:rPr>
+        <w:rFonts w:ascii="Calibri" w:h-ansi="Calibri" w:fareast="宋体" w:cs="Times New Roman" w:hint="default"/>
+        <w:kern w:val="2"/>
+        <w:sz w:val="21"/>
+        <w:sz-cs w:val="24"/>
+        <w:lang w:val="EN-US" w:fareast="ZH-CN"/>
+      </w:rPr>
+    </w:style>
+    <w:style w:type="paragraph" w:styleId="2">
+      <w:name w:val="heading 1"/>
+      <w:basedOn w:val="a1"/>
+      <w:next w:val="a1"/>
+      <w:pPr>
+        <w:keepNext/>
+        <w:keepLines/>
+        <w:adjustRightInd w:val="off"/>
+        <w:snapToGrid w:val="off"/>
+        <w:spacing w:before="240" w:before-lines="0" w:before-autospacing="off" w:after="240" w:after-autospacing="off" w:line="240" w:line-rule="auto"/>
+        <w:outlineLvl w:val="0"/>
+      </w:pPr>
+      <w:rPr>
+        <w:rFonts w:ascii="Calibri" w:h-ansi="Calibri" w:hint="default"/>
+        <w:b/>
+        <w:kern w:val="44"/>
+        <w:sz w:val="44"/>
+      </w:rPr>
+    </w:style>
+    <w:style w:type="character" w:styleId="a4" w:default="on">
+      <w:name w:val="Default Paragraph Font"/>
+      <w:semiHidden/>
+    </w:style>
+    <w:style w:type="table" w:styleId="a5" w:default="on">
+      <w:name w:val="Normal Table"/>
+      <w:semiHidden/>
+      <w:tblPr>
+        <w:tblCellMar>
+          <w:top w:w="0" w:type="dxa"/>
+          <w:left w:w="108" w:type="dxa"/>
+          <w:bottom w:w="0" w:type="dxa"/>
+          <w:right w:w="108" w:type="dxa"/>
+        </w:tblCellMar>
+      </w:tblPr>
+    </w:style>
+    <w:style w:type="paragraph" w:styleId="a3">
+      <w:name w:val="HTML Preformatted"/>
+      <w:basedOn w:val="a1"/>
+      <w:pPr>
+        <w:tabs>
+          <w:tab w:val="left" w:pos="916"/>
+          <w:tab w:val="left" w:pos="1832"/>
+          <w:tab w:val="left" w:pos="2748"/>
+          <w:tab w:val="left" w:pos="3664"/>
+          <w:tab w:val="left" w:pos="4580"/>
+          <w:tab w:val="left" w:pos="5496"/>
+          <w:tab w:val="left" w:pos="6412"/>
+          <w:tab w:val="left" w:pos="7328"/>
+          <w:tab w:val="left" w:pos="8244"/>
+          <w:tab w:val="left" w:pos="9160"/>
+          <w:tab w:val="left" w:pos="10076"/>
+          <w:tab w:val="left" w:pos="10992"/>
+          <w:tab w:val="left" w:pos="11908"/>
+          <w:tab w:val="left" w:pos="12824"/>
+          <w:tab w:val="left" w:pos="13740"/>
+          <w:tab w:val="left" w:pos="14656"/>
+        </w:tabs>
+        <w:jc w:val="left"/>
+      </w:pPr>
+      <w:rPr>
+        <w:rFonts w:ascii="宋体" w:h-ansi="宋体" w:fareast="宋体" w:cs="宋体" w:hint="fareast"/>
+        <w:kern w:val="0"/>
+        <w:sz w:val="24"/>
+        <w:sz-cs w:val="24"/>
+        <w:lang w:val="EN-US" w:fareast="ZH-CN" w:bidi="AR-SA"/>
+      </w:rPr>
+    </w:style>
+    <w:style w:type="table" w:styleId="a6">
+      <w:name w:val="Table Grid"/>
+      <w:basedOn w:val="a5"/>
+      <w:pPr>
+        <w:pStyle w:val="a5"/>
+        <w:widowControl w:val="off"/>
+        <w:jc w:val="both"/>
+      </w:pPr>
+      <w:tblPr>
+        <w:tblBorders>
+          <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+        </w:tblBorders>
+      </w:tblPr>
+    </w:style>
+  </w:styles>
+  <w:bgPict>
+    <w:background/>
+    <v:background id="_x0000_s1025">
+      <v:fill on="f" focussize="0,0"/>
+    </v:background>
+  </w:bgPict>
+  <w:docPr>
+    <w:view w:val="print"/>
+    <w:zoom w:percent="170"/>
+    <w:characterSpacingControl w:val="CompressPunctuation"/>
+    <w:documentProtection w:enforcement="off"/>
+    <w:defaultTabStop w:val="420"/>
+    <w:drawingGridVerticalSpacing w:val="156"/>
+    <w:displayHorizontalDrawingGridEvery w:val="1"/>
+    <w:displayVerticalDrawingGridEvery w:val="1"/>
+    <w:compat>
+      <w:adjustLineHeightInTable/>
+      <w:ulTrailSpace/>
+      <w:doNotExpandShiftReturn/>
+      <w:balanceSingleByteDoubleByteWidth/>
+      <w:useFELayout/>
+      <w:spaceForUL/>
+      <w:breakWrappedTables/>
+      <w:dontGrowAutofit/>
+      <w:useFELayout/>
+    </w:compat>
+  </w:docPr>
+  <w:body>
+    <wx:sect>
+      <w:p>
+        <w:pPr>
+          <w:pStyle w:val="2"/>
+          <w:jc w:val="center"/>
+          <w:rPr>
+            <w:rFonts w:ascii="Droid Sans Mono" w:h-ansi="Droid Sans Mono" w:fareast="Droid Sans Mono" w:cs="Droid Sans Mono" w:hint="default"/>
+            <w:color w:val="auto"/>
+            <w:sz w:val="21"/>
+            <w:sz-cs w:val="21"/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:ascii="Droid Sans Mono" w:h-ansi="Droid Sans Mono" w:fareast="Droid Sans Mono" w:cs="Droid Sans Mono" w:hint="default"/>
+            <w:color w:val="auto"/>
+            <w:sz w:val="21"/>
+            <w:sz-cs w:val="21"/>
+            <w:shd w:val="clear" w:color="auto" w:fill="FFFFFF"/>
+          </w:rPr>
+          <w:t>${year}</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:ascii="Droid Sans Mono" w:h-ansi="Droid Sans Mono" w:fareast="Droid Sans Mono" w:cs="Droid Sans Mono" w:hint="fareast"/>
+            <w:color w:val="auto"/>
+            <w:sz w:val="21"/>
+            <w:sz-cs w:val="21"/>
+            <w:shd w:val="clear" w:color="auto" w:fill="FFFFFF"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>年</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:ascii="Droid Sans Mono" w:h-ansi="Droid Sans Mono" w:fareast="Droid Sans Mono" w:cs="Droid Sans Mono" w:hint="default"/>
+            <w:color w:val="auto"/>
+            <w:sz w:val="21"/>
+            <w:sz-cs w:val="21"/>
+            <w:shd w:val="clear" w:color="auto" w:fill="FFFFFF"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>${quarterly}</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:ascii="Droid Sans Mono" w:h-ansi="Droid Sans Mono" w:fareast="Droid Sans Mono" w:cs="Droid Sans Mono" w:hint="default"/>
+            <w:color w:val="auto"/>
+            <w:sz w:val="21"/>
+            <w:sz-cs w:val="21"/>
+            <w:shd w:val="clear" w:color="auto" w:fill="FFFFFF"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>${month}</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:ascii="Droid Sans Mono" w:h-ansi="Droid Sans Mono" w:fareast="Droid Sans Mono" w:cs="Droid Sans Mono" w:hint="default"/>
+            <w:color w:val="auto"/>
+            <w:sz w:val="21"/>
+            <w:sz-cs w:val="21"/>
+            <w:shd w:val="clear" w:color="auto" w:fill="FFFFFF"/>
+          </w:rPr>
+          <w:t>南京市社会艺术水平考级监管报告</w:t>
+        </w:r>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="1"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>总统计</w:t>
+        </w:r>
+      </w:p>
+      <w:tbl>
+        <w:tblPr>
+          <w:tblStyle w:val="a6"/>
+          <w:tblW w:w="0" w:type="auto"/>
+          <w:tblInd w:w="0" w:type="dxa"/>
+          <w:tblBorders>
+            <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          </w:tblBorders>
+          <w:tblCellMar>
+            <w:top w:w="0" w:type="dxa"/>
+            <w:left w:w="108" w:type="dxa"/>
+            <w:bottom w:w="0" w:type="dxa"/>
+            <w:right w:w="108" w:type="dxa"/>
+          </w:tblCellMar>
+        </w:tblPr>
+        <w:tblGrid>
+          <w:gridCol w:w="2094"/>
+          <w:gridCol w:w="2204"/>
+          <w:gridCol w:w="2119"/>
+          <w:gridCol w:w="2105"/>
+        </w:tblGrid>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2129" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>备案条数</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2130" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>报考人数</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2130" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>投诉数量</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2130" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>检查数量</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2129" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${record}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2130" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${totalExamQuantity}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2130" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${totalComplain}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="2130" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${totalAudit}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+      </w:tbl>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="0"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="0"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>二</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>、</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>各专业报考人数统计</w:t>
+        </w:r>
+      </w:p>
+      <w:tbl>
+        <w:tblPr>
+          <w:tblStyle w:val="a6"/>
+          <w:tblW w:w="0" w:type="auto"/>
+          <w:tblInd w:w="0" w:type="dxa"/>
+          <w:tblBorders>
+            <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          </w:tblBorders>
+          <w:tblCellMar>
+            <w:top w:w="0" w:type="dxa"/>
+            <w:left w:w="108" w:type="dxa"/>
+            <w:bottom w:w="0" w:type="dxa"/>
+            <w:right w:w="108" w:type="dxa"/>
+          </w:tblCellMar>
+        </w:tblPr>
+        <w:tblGrid>
+          <w:gridCol w:w="1704"/>
+          <w:gridCol w:w="1704"/>
+          <w:gridCol w:w="1704"/>
+          <w:gridCol w:w="1705"/>
+          <w:gridCol w:w="1705"/>
+        </w:tblGrid>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>音乐</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>舞蹈</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>美术</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1705" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>戏曲戏剧</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1705" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>曲艺</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${music}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${dance}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${fineArt}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1705" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${operaDrama}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1705" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:listPr>
+                  <w:ilvl w:val="0"/>
+                  <w:ilfo w:val="0"/>
+                </w:listPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${folkArt}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+      </w:tbl>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="0"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="0"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>${specialtyPie}</w:t>
+        </w:r>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="0"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>三</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>、</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>考级机构统计</w:t>
+        </w:r>
+      </w:p>
+      <w:tbl>
+        <w:tblPr>
+          <w:tblStyle w:val="a6"/>
+          <w:tblW w:w="0" w:type="auto"/>
+          <w:tblInd w:w="0" w:type="dxa"/>
+          <w:tblBorders>
+            <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          </w:tblBorders>
+          <w:tblCellMar>
+            <w:top w:w="0" w:type="dxa"/>
+            <w:left w:w="108" w:type="dxa"/>
+            <w:bottom w:w="0" w:type="dxa"/>
+            <w:right w:w="108" w:type="dxa"/>
+          </w:tblCellMar>
+        </w:tblPr>
+        <w:tblGrid>
+          <w:gridCol w:w="1106"/>
+          <w:gridCol w:w="2272"/>
+          <w:gridCol w:w="1752"/>
+          <w:gridCol w:w="1385"/>
+          <w:gridCol w:w="2007"/>
+        </w:tblGrid>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>名称</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1060" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>考级数量</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1069" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>报考人数</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1131" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>投诉条数</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="3558" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>投诉内容</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+        <#list list as go>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${go.name}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1060" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${go.examCenterQuantity}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1069" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${go.examQuantity}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1131" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${go.complain}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="3558" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${go.complainContent}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+        </#list>
+      </w:tbl>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>四</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>、</w:t>
+        </w:r>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>承办单位统计</w:t>
+        </w:r>
+      </w:p>
+      <w:tbl>
+        <w:tblPr>
+          <w:tblStyle w:val="a6"/>
+          <w:tblW w:w="0" w:type="auto"/>
+          <w:tblInd w:w="0" w:type="dxa"/>
+          <w:tblBorders>
+            <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+          </w:tblBorders>
+          <w:tblCellMar>
+            <w:top w:w="0" w:type="dxa"/>
+            <w:left w:w="108" w:type="dxa"/>
+            <w:bottom w:w="0" w:type="dxa"/>
+            <w:right w:w="108" w:type="dxa"/>
+          </w:tblCellMar>
+        </w:tblPr>
+        <w:tblGrid>
+          <w:gridCol w:w="1089"/>
+          <w:gridCol w:w="2289"/>
+          <w:gridCol w:w="1753"/>
+          <w:gridCol w:w="1377"/>
+          <w:gridCol w:w="2014"/>
+        </w:tblGrid>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>名称</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1060" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>考级数量</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1069" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>报考人数</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1131" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>投诉条数</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="3558" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="fareast"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang w:val="EN-US"/>
+                </w:rPr>
+                <w:t>投诉内容</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+        <#list listOr as or>
+        <w:tr>
+          <w:tblPrEx>
+            <w:tblBorders>
+              <w:top w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:left w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:bottom w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:right w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideH w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+              <w:insideV w:val="single" w:sz="4" wx:bdrwidth="10" w:space="0" w:color="auto"/>
+            </w:tblBorders>
+            <w:tblCellMar>
+              <w:top w:w="0" w:type="dxa"/>
+              <w:left w:w="108" w:type="dxa"/>
+              <w:bottom w:w="0" w:type="dxa"/>
+              <w:right w:w="108" w:type="dxa"/>
+            </w:tblCellMar>
+          </w:tblPrEx>
+          <w:trPr/>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1704" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${or.name}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1060" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${or.examCenterQuantity}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1069" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${or.examQuantity}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="1131" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:jc w:val="center"/>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${or.complain}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+          <w:tc>
+            <w:tcPr>
+              <w:tcW w:w="3558" w:type="dxa"/>
+              <w:shd w:val="clear" w:color="auto" w:fill="auto"/>
+            </w:tcPr>
+            <w:p>
+              <w:pPr>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+              </w:pPr>
+              <w:r>
+                <w:rPr>
+                  <w:rFonts w:hint="default"/>
+                  <w:vertAlign w:val="baseline"/>
+                  <w:lang/>
+                </w:rPr>
+                <w:t>${or.complainContent}</w:t>
+              </w:r>
+            </w:p>
+          </w:tc>
+        </w:tr>
+        </#list>
+      </w:tbl>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="2"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>投诉饼图</w:t>
+        </w:r>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>${complainPie}</w:t>
+        </w:r>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:listPr>
+            <w:ilvl w:val="0"/>
+            <w:ilfo w:val="2"/>
+          </w:listPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang w:val="EN-US"/>
+          </w:rPr>
+          <w:t>备案柱状图</w:t>
+        </w:r>
+      </w:p>
+      <w:p>
+        <w:pPr>
+          <w:rPr>
+            <w:rFonts w:hint="fareast"/>
+            <w:lang/>
+          </w:rPr>
+        </w:pPr>
+        <w:r>
+          <w:rPr>
+            <w:rFonts w:hint="default"/>
+            <w:lang/>
+          </w:rPr>
+          <w:t>&amp;{recordBar}</w:t>
+        </w:r>
+      </w:p>
+      <w:sectPr>
+        <w:pgSz w:w="11906" w:h="16838"/>
+        <w:pgMar w:top="1440" w:right="1800" w:bottom="1440" w:left="1800" w:header="851" w:footer="992" w:gutter="0"/>
+        <w:cols w:space="425"/>
+        <w:docGrid w:type="lines" w:line-pitch="312"/>
+      </w:sectPr>
+    </wx:sect>
+  </w:body>
+</w:wordDocument>

BIN
src/main/resources/templates/chart/PieTemplate.docx


+ 3 - 1
src/main/vue/src/views/record/ReportList.vue

@@ -267,7 +267,9 @@ export default {
             this.loading = true;
             this.$alert('确认生成吗?', '警告', { type: 'error' })
                 .then(() => {
-                    return this.$http.post('/report/word', this.form, { body: 'json' });
+                    return this.$http.post('/report/word', this.form, { body: 'json' })(() => {
+                        this.getData();
+                    });
                 })
                 .then(() => {
                     this.$message.success('生成成功');

+ 5 - 1
src/main/vue/src/widgets/PassWidget.vue

@@ -24,7 +24,11 @@ export default {
         this.$http
             .post(
                 '/reportStatistic/all',
-                { sort: 'examQuantity,desc', size: 20, query: { unitType: 'ORGANIZATION' } },
+                {
+                    sort: 'examQuantity,desc',
+                    size: 20,
+                    query: { unitType: 'ORGANIZATION', reportId: this.$route.query.id }
+                },
                 { body: 'json' }
             )
             .then(res => {

+ 48 - 0
src/test/java/com/izouma/wenlvju/service/regulation/ReportServiceTest.java

@@ -4,9 +4,18 @@ package com.izouma.wenlvju.service.regulation;
 import com.izouma.wenlvju.ApplicationTests;
 import com.izouma.wenlvju.domain.regulation.Report;
 import com.izouma.wenlvju.enums.ReportType;
+import com.izouma.wenlvju.utils.ChartUtils;
+import org.apache.poi.xwpf.usermodel.XWPFChart;
+import org.apache.poi.xwpf.usermodel.XWPFDocument;
 import org.junit.Test;
 import org.springframework.beans.factory.annotation.Autowired;
 
+import java.io.*;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
 public class ReportServiceTest extends ApplicationTests {
     @Autowired
     private ReportService reportService;
@@ -30,4 +39,43 @@ public class ReportServiceTest extends ApplicationTests {
                 .build();
         reportService.getDate(report);
     }
+
+    @Test
+    public void test2() throws IOException {
+        String templatePath = "/Users/qiufangchao/Desktop/template.docx";
+
+        InputStream is = new FileInputStream(templatePath);
+        XWPFDocument doc = new XWPFDocument(is);
+
+        //模拟统计图数据
+        //系列
+        String[] seriesTitles = {"专业"};
+        //x轴
+        String[] categories = {"音乐", "舞蹈", "美术", "戏曲戏剧", "曲艺"};
+        List<Number[]> values = new ArrayList<>();
+        //日处理能力
+        Number[] value1 = {1432, 500, 1675, 234, 0};
+        values.add(value1);
+
+        XWPFChart xChart = doc.getCharts().get(0);//获取第1个图表
+        ChartUtils.generateChart(xChart, seriesTitles, categories, values, "专业统计");
+
+        try (FileOutputStream fos = new FileOutputStream("/Users/qiufangchao/Desktop/test.docx")) {
+            doc.write(fos);
+        }
+    }
+
+    @Test
+    public void test3() throws IOException {
+        Map<String,Integer> map = new HashMap();
+        map.put("音乐",100);
+        map.put("舞蹈",89);
+        map.put("美术",109);
+        map.put("戏曲戏剧",120);
+
+        XWPFDocument x = reportService.chart(map, "/templates/chart/PieTemplate.docx", "专业");
+        try (FileOutputStream fos = new FileOutputStream("/Users/qiufangchao/Desktop/test.docx")) {
+            x.write(fos);
+        }
+    }
 }