deason 6 年 前
コミット
6a2e072433

+ 10 - 39
examcloud-core-questions-service/src/main/java/cn/com/qmth/examcloud/core/questions/service/temp/DdExcelService.java

@@ -29,36 +29,26 @@ import java.util.*;
 public class DdExcelService {
     private final String exportExcelPath = "D:/exportExcel.xlsx";
     private final String xianExcelPath = "D:/xianExcelNew.xlsx";
-
     private final String paperExcelPath = "D:/paperExcel.xlsx";
     private final String paperExcelPathNew = "D:/paperExcelNew.xlsx";
-
     private final String quesExcelPath = "D:/quesExcel.xlsx";
     private final String quesExcelPathNew = "D:/quesExcelNew.xlsx";
-
     private final String paperStructExcelPath = "D:/paperStructExcel.xlsx";
     private final String paperStructExcelPathNew = "D:/paperStructExcelNew.xlsx";
-
     @Autowired
     private QuesRepo quesRepo;
-
     @Autowired
-    PaperDetailUnitService paperDetailUnitService;
-
+    private PaperDetailUnitService paperDetailUnitService;
     @Autowired
-    PaperDetailUnitRepo paperDetailUnitRepo;
-
+    private PaperDetailUnitRepo paperDetailUnitRepo;
     @Autowired
-    PaperRepo paperRepo;
-
+    private PaperRepo paperRepo;
     @Autowired
     private QuesTypeNameRepo quesTypeRepo;
-
     @Autowired
-    MongoTemplate mongoTemplate;
-
+    private MongoTemplate mongoTemplate;
     @Autowired
-    PaperDetailRepo paperDetailRepo;
+    private PaperDetailRepo paperDetailRepo;
 
     public void insertQueryName(String orgId) {
         //查询所有课程
@@ -140,6 +130,9 @@ public class DdExcelService {
         return map;
     }
 
+    /**
+     * 导出按大题名称统计分布
+     */
     @SuppressWarnings("resource")
     public void exporExcel(String orgId) throws Exception {
         //导出Excel集合
@@ -386,9 +379,6 @@ public class DdExcelService {
 
     /**
      * 导出试卷详情
-     *
-     * @param orgId
-     * @throws Exception
      */
     @SuppressWarnings("resource")
     public void exportPaperExcel(String orgId) throws Exception {
@@ -484,10 +474,7 @@ public class DdExcelService {
     }
 
     /**
-     * 导出试卷结构
-     *
-     * @param orgId
-     * @throws Exception
+     * 导出课程下的精确试卷结构
      */
     @SuppressWarnings("resource")
     public void exportPaperStructExcel(String orgId) throws Exception {
@@ -563,11 +550,6 @@ public class DdExcelService {
 
     /**
      * 给定考试和课程集合,查询所有试卷中的主观题,导出一个Excel(课程名称,课程代码,试卷名称,试卷id,试题题干)
-     *
-     * @param orgId
-     * @param examId
-     * @param codes
-     * @throws Exception
      */
     @SuppressWarnings("resource")
     public void exportSubQues(String orgId, Long examId, List<String> codes) throws Exception {
@@ -672,15 +654,4 @@ public class DdExcelService {
         System.out.println("结束...");
     }
 
-
-    public static void main(String[] args) {
-//		File ddExcelFile = new File(exportExcelPath);
-        List<String> ss = new ArrayList<String>();
-        ss.add("单选");
-        ss.add("单选题");
-        ss.add("选择题");
-        System.out.println(ss);
-        System.out.println(ss.toString());
-    }
-
-}
+}