Przeglądaj źródła

完善试题统计

tags/正式版本
王宁 2 lat temu
rodzic
commit
f626aea1f1

+ 0
- 7
sexam/src/main/java/com/xhkjedu/sexam/mapper/reportclass/ERclassQuestionErrorMapper.java Wyświetl plik

@@ -1,7 +0,0 @@
1
-package com.xhkjedu.sexam.mapper.reportclass;
2
-
3
-import com.xhkjedu.sexam.base.TkMapper;
4
-import com.xhkjedu.sexam.model.reportclass.ERclassQuestionError;
5
-
6
-public interface ERclassQuestionErrorMapper extends TkMapper<ERclassQuestionError> {
7
-}

+ 0
- 42
sexam/src/main/java/com/xhkjedu/sexam/model/reportclass/ERclassQuestionError.java Wyświetl plik

@@ -1,42 +0,0 @@
1
-package com.xhkjedu.sexam.model.reportclass;
2
-
3
-import com.xhkjedu.sexam.model.BaseBean;
4
-import lombok.Data;
5
-
6
-import javax.persistence.Id;
7
-import javax.persistence.Table;
8
-
9
-@Table(name = "e_rclass_question_error")
10
-@Data
11
-public class ERclassQuestionError extends BaseBean {
12
-    @Id
13
-    //考试报告班级单科高频错题表
14
-    private Integer rceqid;
15
-
16
-    //考试id
17
-    private Integer examid;
18
-
19
-    //班级id
20
-    private Integer classid;
21
-
22
-    //科目id
23
-    private String subjectid;
24
-
25
-    //题号
26
-    private String qn;
27
-
28
-    //题型名称
29
-    private String qtypename;
30
-
31
-    //知识点
32
-    private String pointname;
33
-
34
-    //班级得分率
35
-    private Double classrate;
36
-
37
-    //年级得分率
38
-    private Double graderate;
39
-
40
-    //高频错误项
41
-    private String errormsg;
42
-}

+ 25
- 7
sexam/src/main/java/com/xhkjedu/sexam/service/report/EReportGenerateService.java Wyświetl plik

@@ -2,6 +2,7 @@ package com.xhkjedu.sexam.service.report;
2 2
 
3 3
 import com.alibaba.fastjson.JSON;
4 4
 import com.xhkjedu.sexam.mapper.exam.EClassMapper;
5
+import com.xhkjedu.sexam.mapper.paper.EPaperAnalyzeMapper;
5 6
 import com.xhkjedu.sexam.mapper.paper.EPaperQtypeMapper;
6 7
 import com.xhkjedu.sexam.mapper.paperstudent.EPaperStudentMapper;
7 8
 import com.xhkjedu.sexam.mapper.paperstudent.EPaperStudentQuestionMapper;
@@ -10,17 +11,16 @@ import com.xhkjedu.sexam.mapper.report.EReportGenerateMapper;
10 11
 import com.xhkjedu.sexam.mapper.report.ERsubjectMapper;
11 12
 import com.xhkjedu.sexam.mapper.reportclass.ERclassMapper;
12 13
 import com.xhkjedu.sexam.mapper.reportclass.ERclassQtypeMapper;
13
-import com.xhkjedu.sexam.mapper.reportclass.ERclassQuestionErrorMapper;
14 14
 import com.xhkjedu.sexam.mapper.reportclass.ERclassQuestionMapper;
15 15
 import com.xhkjedu.sexam.mapper.reportclass.ERclassQuestionPointMapper;
16 16
 import com.xhkjedu.sexam.mapper.reportstu.ERstudentMapper;
17
+import com.xhkjedu.sexam.model.paper.EPaperAnalyze;
17 18
 import com.xhkjedu.sexam.model.paperstudent.EPaperStudentQuestion;
18 19
 import com.xhkjedu.sexam.model.report.ERbase;
19 20
 import com.xhkjedu.sexam.model.report.ERsubject;
20 21
 import com.xhkjedu.sexam.model.reportclass.ERclass;
21 22
 import com.xhkjedu.sexam.model.reportclass.ERclassQtype;
22 23
 import com.xhkjedu.sexam.model.reportclass.ERclassQuestion;
23
-import com.xhkjedu.sexam.model.reportclass.ERclassQuestionError;
24 24
 import com.xhkjedu.sexam.model.reportclass.ERclassQuestionPoint;
25 25
 import com.xhkjedu.sexam.model.reportstu.ERstudent;
26 26
 import com.xhkjedu.sexam.utils.ExamUtil;
@@ -56,7 +56,8 @@ public class EReportGenerateService {
56 56
     private EPaperQtypeMapper ePaperQtypeMapper;
57 57
     @Resource
58 58
     private EPaperStudentQuestionMapper ePaperStudentQuestionMapper;
59
-
59
+    @Resource
60
+    private EPaperAnalyzeMapper ePaperAnalyzeMapper;
60 61
 
61 62
     @Resource
62 63
     private ERbaseMapper eRbaseMapper;
@@ -72,8 +73,6 @@ public class EReportGenerateService {
72 73
     private ERclassQuestionMapper eRclassQuestionMapper;
73 74
     @Resource
74 75
     private ERclassQuestionPointMapper eRclassQuestionPointMapper;
75
-    @Resource
76
-    private ERclassQuestionErrorMapper eRclassQuestionErrorMapper;
77 76
 
78 77
 
79 78
     //生成考试报告
@@ -161,7 +160,6 @@ public class EReportGenerateService {
161 160
         List<ERclass> classList = new ArrayList<>();//考试报告班级情况
162 161
         List<ERclassQtype> qtypeList = new ArrayList<>();//考试报告班级题型情况
163 162
         List<ERclassQuestion> questionList = new ArrayList<>();//考试报告班级试题情况
164
-        List<ERclassQuestionError> errorList = new ArrayList<>();//考试报告班级高频错题情况
165 163
         List<ERclassQuestionPoint> pointList = new ArrayList<>();//考试报告班级试题知识点情况
166 164
         for (Map.Entry<String, List<ERstudent>> ssEntry : subCollect.entrySet()) {
167 165
             subjectid = ssEntry.getKey();
@@ -336,7 +334,7 @@ public class EReportGenerateService {
336 334
         }
337 335
     }
338 336
 
339
-    //题型试题
337
+    //试卷题型试题、知识点
340 338
     private void setClassQuestion(Integer examid,List<Map> subjects,List<Map> classes){
341 339
         //考试所有学生提交试卷情况
342 340
         List<EPaperStudentQuestion> stulist = ePaperStudentQuestionMapper.listExamStudentsAnswer(examid);
@@ -462,6 +460,26 @@ public class EReportGenerateService {
462 460
                     rtypelist.add(eRclassQtype);
463 461
                 }
464 462
             }
463
+
464
+            if(ptype == 1){
465
+                //获取试卷只是分析
466
+                Map epa = ePaperAnalyzeMapper.getPaperAnalzyeByEpid(epid);
467
+                String pointjson = epa.get("pointjson").toString();
468
+                List<Map> pointlist = JSON.parseArray(pointjson,Map.class);
469
+                //遍历知识点处理年级班级知识点情况
470
+                for(int j=0;j<pointlist.size();j++){
471
+                    Map pointmap = pointlist.get(j);
472
+                    String pointname = pointmap.get("pointname").toString();
473
+                    Double score = Double.parseDouble(pointmap.get("score").toString());
474
+                    Double scorerate = Double.parseDouble(pointmap.get("scorerate").toString());
475
+                    String order = pointmap.get("order").toString();
476
+
477
+                
478
+                }
479
+
480
+            }
481
+
482
+
465 483
         }
466 484
         eRclassQtypeMapper.insertList(rtypelist);
467 485
         eRclassQuestionMapper.insertList(rqlist);

Ładowanie…
Anuluj
Zapisz