Browse Source

报告接口测试及完善

wn
王宁 9 hours ago
parent
commit
a65b934ecb

+ 1
- 1
smarking/src/main/java/com/xhkjedu/smarking/controller/report/XkReportController.java View File

@@ -55,7 +55,7 @@ public class XkReportController {
55 55
      * @Param [params]
56 56
      * @Return com.xhkjedu.vo.ResultVo
57 57
      **/
58
-    @PostMapping("/xkst_Nd")
58
+    @PostMapping("/xkst_nd")
59 59
     public ResultVo listQuestionForXhXhstNdGroup(@RequestBody ExamReportParams params){
60 60
         N_Utils.validation(new Object[]{params.getExamid(),"考试id",1,params.getSubjectid(),"科目id",2});
61 61
         return new ResultVo(0,"获取成功",msrClassQuestionService.listQuestionForXhXhstNdGroup(params));

+ 0
- 1
smarking/src/main/java/com/xhkjedu/smarking/controller/report/ZhReportController.java View File

@@ -4,7 +4,6 @@ import com.github.pagehelper.PageHelper;
4 4
 import com.github.pagehelper.PageInfo;
5 5
 import com.xhkjedu.smarking.model.exam.MsSubject;
6 6
 import com.xhkjedu.smarking.model.report.reportclass.MsrClassSubjectGrade;
7
-import com.xhkjedu.smarking.model.report.reportstu.MsrStudent;
8 7
 import com.xhkjedu.smarking.model.report.reportstu.MsrStudentAction;
9 8
 import com.xhkjedu.smarking.model.report.reportsubject.MsrSubject;
10 9
 import com.xhkjedu.smarking.service.report.report.*;

+ 2
- 1
smarking/src/main/java/com/xhkjedu/smarking/mapper/paper/MsTemplateMapper.java View File

@@ -2,6 +2,7 @@ package com.xhkjedu.smarking.mapper.paper;
2 2
 
3 3
 import com.xhkjedu.base.TkMapper;
4 4
 import com.xhkjedu.smarking.model.paper.MsTemplate;
5
+import com.xhkjedu.smarking.vo.scan.TemplateVo;
5 6
 import org.apache.ibatis.annotations.Param;
6 7
 
7 8
 import java.util.List;
@@ -30,7 +31,7 @@ public interface MsTemplateMapper extends TkMapper<MsTemplate> {
30 31
     int getUnSelTemplateCount(@Param("mpid")Integer mpid);
31 32
 
32 33
     //试卷所有模板信息
33
-    List<Map<String,Object>> listTemplateBlockQueByMpid(@Param("mpid") Integer mpid);
34
+    List<TemplateVo> listTemplateBlockQueByMpid(@Param("mpid") Integer mpid);
34 35
 
35 36
     //获取模版详情和考试id
36 37
     MsTemplate getTemplateAndExamidByMtid(@Param("mtid") Integer mtid);

+ 1
- 1
smarking/src/main/java/com/xhkjedu/smarking/mapper/report/reportclass/MsrClassSubjectGradeMapper.java View File

@@ -15,7 +15,7 @@ import java.util.Map;
15 15
 public interface MsrClassSubjectGradeMapper extends TkMapper<MsrClassSubjectGrade> {
16 16
 
17 17
     //综合报告-试题汇总表-全部班级-科目情况-四率等级分析
18
-    List<MsrClassSubjectGrade> listSubjectGrade(@Param("sg")MsrClassSubjectGrade sg);
18
+    List<Map<String,Object>> listSubjectGrade(@Param("sg")MsrClassSubjectGrade sg);
19 19
 
20 20
     //综合报告-班级对比-全科及格率分析
21 21
     List<MsrClassSubjectGrade> listSubjectGradeForQk(@Param("examid") Integer examid,@Param("reportcode") String reportcode);

+ 24
- 12
smarking/src/main/java/com/xhkjedu/smarking/service/report/report/MsrClassQuestionService.java View File

@@ -55,7 +55,7 @@ public class MsrClassQuestionService {
55 55
         subjectGrade.setClassid(0);
56 56
         subjectGrade.setReportcode("zh");
57 57
         //获取科目四率
58
-        List<MsrClassSubjectGrade> subjectGradeList = msrClassSubjectGradeMapper.listSubjectGrade(subjectGrade);
58
+        List<Map<String,Object>> subjectGradeList = msrClassSubjectGradeMapper.listSubjectGrade(subjectGrade);
59 59
         subjectMap.put("subjectGradeList",subjectGradeList);
60 60
 
61 61
         //获取四率参数
@@ -83,7 +83,7 @@ public class MsrClassQuestionService {
83 83
             List<Map<String,Object>> allSchool = questionList.stream().filter(m -> m.get("classid").equals(0)).collect(Collectors.toList());
84 84
             for(Map<String,Object> school : allSchool){
85 85
                 school.put("classname","学校全体");
86
-                if(school.get("qtype").equals("1")){
86
+                if(school.get("qtype").equals(1)){
87 87
                     objlist.add(school);
88 88
                 }else{
89 89
                     sublist.add(school);
@@ -94,7 +94,7 @@ public class MsrClassQuestionService {
94 94
                 List<Map<String,Object>> classQues = questionList.stream().filter(m -> m.get("classid").equals(c.getClassid())).collect(Collectors.toList());
95 95
                 for(Map<String,Object> cq : classQues){
96 96
                     cq.put("classname",c.getClassname());
97
-                    if(cq.get("qtype").equals("1")){
97
+                    if(cq.get("qtype").equals(1)){
98 98
                         objlist.add(cq);
99 99
                     }else{
100 100
                         sublist.add(cq);
@@ -102,8 +102,8 @@ public class MsrClassQuestionService {
102 102
                 }
103 103
             }
104 104
         }else{
105
-            objlist = questionList.stream().filter(m -> m.get("qtype").equals("1")).collect(Collectors.toList());
106
-            sublist = questionList.stream().filter(m -> m.get("qtype").equals("2")).collect(Collectors.toList());
105
+            objlist = questionList.stream().filter(m -> m.get("qtype").equals(1)).collect(Collectors.toList());
106
+            sublist = questionList.stream().filter(m -> m.get("qtype").equals(2)).collect(Collectors.toList());
107 107
         }
108 108
 
109 109
         Map<String,Object> rtnMap = new HashMap<>();
@@ -259,8 +259,8 @@ public class MsrClassQuestionService {
259 259
         }
260 260
 
261 261
         Map<String,Object> rtnMap = new HashMap<>();
262
-        rtnMap.put("firstN",firstN);
263
-        rtnMap.put("lastN",lastN);
262
+        rtnMap.put("firstN",firstN.stream().map(MsrClassQuestion::getQn).distinct().collect(Collectors.toList()));
263
+        rtnMap.put("lastN",lastN.stream().map(MsrClassQuestion::getQn).distinct().collect(Collectors.toList()));
264 264
         rtnMap.put("qfdList",qfdList);
265 265
         return rtnMap;
266 266
     }
@@ -358,7 +358,11 @@ public class MsrClassQuestionService {
358 358
                 classMap.put("classid",classid);
359 359
                 MsrClassQuestion classQues = entryList.stream().filter(m -> m.getClassid() == classid).findFirst().orElse(null);
360 360
                 if(classQues!= null){
361
-                    classMap.put("scorerate",classQues.getScorerate());
361
+                    if(classid == 0){
362
+                        classMap.put("scorerate",classQues.getSchoolavgrate());
363
+                    }else{
364
+                        classMap.put("scorerate",classQues.getScorerate());
365
+                    }
362 366
                 }else{
363 367
                     classMap.put("scorerate",0);
364 368
                 }
@@ -401,8 +405,12 @@ public class MsrClassQuestionService {
401 405
             }else{
402 406
                 //获取年级的
403 407
                 List<String> qnList = schoolQues.stream().map(MsrClassQuestion::getQn).distinct().collect(Collectors.toList());
404
-                double sumScoreRate = schoolQues.stream().mapToDouble(MsrClassQuestion::getScorerate).sum();
405
-                zsndMap.put("schoolscorerate", MarkingUtil.div(sumScoreRate,qnList.size()));
408
+                if(qnList.isEmpty()){
409
+                    zsndMap.put("schoolscorerate", 0);
410
+                }else{
411
+                    double sumScoreRate = schoolQues.stream().mapToDouble(MsrClassQuestion::getScorerate).sum();
412
+                    zsndMap.put("schoolscorerate", MarkingUtil.div(sumScoreRate,qnList.size()));
413
+                }
406 414
             }
407 415
 
408 416
             //获取班级的情况
@@ -411,8 +419,12 @@ public class MsrClassQuestionService {
411 419
                 zsndMap.put("classscorerate", 0);
412 420
             }else{
413 421
                 List<String> qnList = schoolQues.stream().map(MsrClassQuestion::getQn).distinct().collect(Collectors.toList());
414
-                double classScoreRate = schoolQues.stream().mapToDouble(MsrClassQuestion::getScorerate).sum();
415
-                zsndMap.put("classscorerate",MarkingUtil.div(classScoreRate,qnList.size()));
422
+                if(qnList.isEmpty()){
423
+                    zsndMap.put("classscorerate", 0);
424
+                }else{
425
+                    double classScoreRate = schoolQues.stream().mapToDouble(MsrClassQuestion::getScorerate).sum();
426
+                    zsndMap.put("classscorerate",MarkingUtil.div(classScoreRate,qnList.size()));
427
+                }
416 428
             }
417 429
 
418 430
             ndList.add(zsndMap);

+ 13
- 12
smarking/src/main/java/com/xhkjedu/smarking/service/scan/MsScanbatchPaperService.java View File

@@ -15,7 +15,6 @@ import com.xhkjedu.smarking.mapper.stupaper.MsPaperStudentQuestionMapper;
15 15
 import com.xhkjedu.smarking.mapper.system.SchoolMapper;
16 16
 import com.xhkjedu.smarking.mapper.system.UserMapper;
17 17
 import com.xhkjedu.smarking.model.paper.MsPaperBlockQuestion;
18
-import com.xhkjedu.smarking.model.paper.MsTemplate;
19 18
 import com.xhkjedu.smarking.model.scan.MsScanbatch;
20 19
 import com.xhkjedu.smarking.model.scan.MsScanbatchPaper;
21 20
 import com.xhkjedu.smarking.model.scan.MsScanbatchPaperBlock;
@@ -25,6 +24,7 @@ import com.xhkjedu.smarking.model.stupaper.MsPaperStudentBlock;
25 24
 import com.xhkjedu.smarking.model.stupaper.MsPaperStudentQuestion;
26 25
 import com.xhkjedu.smarking.utils.MarkingUtil;
27 26
 import com.xhkjedu.smarking.vo.scan.ScanParams;
27
+import com.xhkjedu.smarking.vo.scan.TemplateVo;
28 28
 import com.xhkjedu.smarking.vo.stupaper.PaperStudentWebVo;
29 29
 import com.xhkjedu.smarking.vo.system.SchoolCloudVo;
30 30
 import com.xhkjedu.utils.N_Utils;
@@ -95,7 +95,7 @@ public class MsScanbatchPaperService {
95 95
     }
96 96
 
97 97
     //获取试卷的所有模版信息
98
-    public List<Map<String,Object>> listTemplates(Integer mpid){
98
+    public List<TemplateVo> listTemplates(Integer mpid){
99 99
         return msTemplateMapper.listTemplateBlockQueByMpid(mpid);
100 100
     }
101 101
 
@@ -675,7 +675,7 @@ public class MsScanbatchPaperService {
675 675
         if(scanbatchPapers.isEmpty()) return;
676 676
 
677 677
         //获取考试对应的试卷模板及坐标信息
678
-        List<Map<String,Object>> templates = msTemplateMapper.listTemplateBlockQueByMpid(mpid);
678
+        List<TemplateVo> templates = msTemplateMapper.listTemplateBlockQueByMpid(mpid);
679 679
         if(templates.isEmpty()) throw new ServiceException("该考试未设置试卷模板");
680 680
 
681 681
         //清空学生题块试题信息和学生试卷扫描识别信息
@@ -684,22 +684,23 @@ public class MsScanbatchPaperService {
684 684
         msScanbatchPaperMapper.deleteScanPaperForReidentify(param);
685 685
     }
686 686
 
687
-    private void chandleIdentifyPaper(List<MsScanbatchPaper> scanbatchPapers,List<MsTemplate> templates){
688
-        MsTemplate template = getPaperTemplate(scanbatchPapers,templates);//试卷模板
687
+    private void chandleIdentifyPaper(List<MsScanbatchPaper> scanbatchPapers,List<TemplateVo> templates){
688
+        TemplateVo template = getPaperTemplate(scanbatchPapers,templates);//试卷模板
689 689
         for(MsScanbatchPaper scanbatchPaper : scanbatchPapers){
690 690
 
691
+
691 692
         }
692 693
     }
693
-    //重新识别-试卷模板
694
-    private MsTemplate getPaperTemplate(List<MsScanbatchPaper> scanbatchPapers,List<MsTemplate> templates){
695
-        MsTemplate template = null;//试卷模板
694
+    //重新识别-获取试卷模板
695
+    private TemplateVo getPaperTemplate(List<MsScanbatchPaper> scanbatchPapers,List<TemplateVo> templates){
696
+        TemplateVo template = null;//试卷模板
696 697
         if(templates.size() == 1){
697 698
             template = templates.get(0);
698 699
         }else{
699 700
             MsScanbatchPaper firstPaper = scanbatchPapers.get(0);
700 701
             Integer maxWidth = firstPaper.getTwidth() + 30;
701 702
             Integer minWidth = firstPaper.getTwidth() - 30;
702
-            for(MsTemplate t : templates){
703
+            for(TemplateVo t : templates){
703 704
                 if(t.getTwidth() >= minWidth && t.getTwidth() <= maxWidth){
704 705
                     template = t;
705 706
                     break;
@@ -709,9 +710,9 @@ public class MsScanbatchPaperService {
709 710
         return template;
710 711
     }
711 712
 
712
-    //重新识别-获取试卷正反面图片
713
-    private void settPaperFrontAndBack(MsScanbatchPaper scanbatchPaper,MsTemplate template){
714
-
713
+    //重新识别-获取试卷正反面正确图片
714
+    private void settPaperFrontAndBack(MsScanbatchPaper scanbatchPaper,TemplateVo template){
715
+        String paperPic = scanbatchPaper.getPaperpic();
715 716
     }
716 717
 
717 718
 

+ 2
- 2
smarking/src/main/java/com/xhkjedu/smarking/utils/MarkingUtil.java View File

@@ -412,7 +412,7 @@ public class MarkingUtil {
412 412
                 result += line;
413 413
             }
414 414
         } catch (Exception e) {
415
-            log.error("发送 POST 请求出现异常" + e.getMessage());
415
+            log.error("发送 POST 请求出现异常" + e.getMessage());
416 416
         }finally {
417 417
             try {
418 418
                 if(bufferedOutputStream!= null){
@@ -422,7 +422,7 @@ public class MarkingUtil {
422 422
                     bufferedReader.close();
423 423
                 }
424 424
             } catch (IOException ex) {
425
-                log.error("关闭输入输出流异常", ex.getMessage());
425
+                log.error("关闭输入输出流异常:" + ex.getMessage());
426 426
             }
427 427
         }
428 428
         return result;

+ 22
- 0
smarking/src/main/java/com/xhkjedu/smarking/vo/scan/TemplateBlockQuestionVo.java View File

@@ -0,0 +1,22 @@
1
+package com.xhkjedu.smarking.vo.scan;
2
+
3
+import lombok.Data;
4
+
5
+/**
6
+ * @Description:模板题块试题
7
+ * @Author: WN
8
+ * @Date: 2025/1/13 10:04:22
9
+ **/
10
+@Data
11
+public class TemplateBlockQuestionVo {
12
+    //阅卷模板题块定客观题ID
13
+    private Integer mtbqid;
14
+    //题号
15
+    private String qn;
16
+    //试卷试题ID
17
+    private Integer mptqid;
18
+    //定位坐标
19
+    private String qlocalcoor;
20
+    //排序或首题题号
21
+    private Integer mtbqorder;
22
+}

+ 34
- 0
smarking/src/main/java/com/xhkjedu/smarking/vo/scan/TemplateBlockVo.java View File

@@ -0,0 +1,34 @@
1
+package com.xhkjedu.smarking.vo.scan;
2
+
3
+import lombok.Data;
4
+
5
+import java.util.List;
6
+
7
+/**
8
+ * @Description:模板题块
9
+ * @Author: WN
10
+ * @Date: 2025/1/13 10:02:33
11
+ **/
12
+@Data
13
+public class TemplateBlockVo {
14
+    //阅卷模板题块定位区ID
15
+    private Integer mtbid;
16
+    //题块ID
17
+    private Integer mblockid;
18
+    //类型1客观题2主观题
19
+    private Integer mttype;
20
+    //客观题方向1横向2纵向
21
+    private Integer direct;
22
+    //排序/首题号
23
+    private Integer mtborder;
24
+    //定位区坐标
25
+    private String localcoor;
26
+    //主观题扩展区坐标列表
27
+    private String extendcoor;
28
+    //主观题打分区坐标
29
+    private String scorecoor;
30
+
31
+    //题块中试题
32
+    private List<TemplateBlockQuestionVo> tbquestions;
33
+
34
+}

+ 53
- 0
smarking/src/main/java/com/xhkjedu/smarking/vo/scan/TemplateVo.java View File

@@ -0,0 +1,53 @@
1
+package com.xhkjedu.smarking.vo.scan;
2
+
3
+import lombok.Data;
4
+
5
+import java.util.List;
6
+
7
+/**
8
+ * @Description:试卷模板
9
+ * @Author: WN
10
+ * @Date: 2025/1/13 10:00:24
11
+ **/
12
+@Data
13
+public class TemplateVo {
14
+    //阅卷扫描模板ID
15
+    private Integer mtid;
16
+    //试卷ID
17
+    private Integer mpid;
18
+    //模板尺寸1A4 2A3
19
+    private Integer tsize;
20
+    //纸张宽度(像素)
21
+    private Integer twidth;
22
+    //纸张高度(像素)
23
+    private Integer theight;
24
+    //正面图片
25
+    private String tfront;
26
+    //反面图片
27
+    private String tback;
28
+    //空白页索引
29
+    private Integer blankindex;
30
+    //定位正面旋转角度
31
+    private Integer anglefront;
32
+    //定位反面旋转角度
33
+    private Integer angleback;
34
+    //正面定位坐标
35
+    private String coorfront;
36
+    //反面定位坐标
37
+    private String coorback;
38
+    //正面定位图片地址
39
+    private String dwtfront;
40
+    //反面定位图片地址
41
+    private String dwtback;
42
+    //缺考标记坐标
43
+    private String misscoor;
44
+    //违规标记坐标
45
+    private String violatecoor;
46
+    //考号定位坐标
47
+    private String examnocoor;
48
+    //涂卡数字坐标列表
49
+    private String cardcoor;
50
+
51
+    //模板题块
52
+    private List<TemplateBlockVo> tblocks;
53
+}

+ 6
- 4
smarking/src/main/resources/mapper/paper/MsTemplateMapper.xml View File

@@ -51,12 +51,14 @@
51 51
     </select>
52 52
 
53 53
     <!--试卷所有模板信息-->
54
-    <resultMap id="paperTemplate" type="java.util.Map">
54
+    <resultMap id="paperTemplate" type="com.xhkjedu.smarking.vo.scan.TemplateVo">
55 55
         <result property="mtid" column="mtid"/>
56 56
         <result property="mpid" column="mpid"/>
57 57
         <result property="tsize" column="tsize"/>
58 58
         <result property="twidth" column="twidth"/>
59 59
         <result property="theight" column="theight"/>
60
+        <result property="tfront" column="tfront"/>
61
+        <result property="tback" column="tback"/>
60 62
         <result property="blankindex" column="blankindex"/>
61 63
         <result property="anglefront" column="anglefront"/>
62 64
         <result property="angleback" column="angleback"/>
@@ -68,7 +70,7 @@
68 70
         <result property="violatecoor" column="violatecoor"/>
69 71
         <result property="examnocoor" column="examnocoor"/>
70 72
         <result property="cardcoor" column="cardcoor"/>
71
-        <collection property="tblocks" ofType="java.util.Map" javaType="java.util.ArrayList">
73
+        <collection property="tblocks" ofType="com.xhkjedu.smarking.vo.scan.TemplateBlockVo" javaType="java.util.ArrayList">
72 74
             <result property="mtbid" column="mtbid"/>
73 75
             <result property="mblockid" column="mblockid"/>
74 76
             <result property="mttype" column="mttype"/>
@@ -76,7 +78,7 @@
76 78
             <result property="localcoor" column="localcoor"/>
77 79
             <result property="extendcoor" column="extendcoor"/>
78 80
             <result property="scorecoor" column="scorecoor"/>
79
-            <collection property="tbquestions" ofType="java.util.Map" javaType="java.util.ArrayList">
81
+            <collection property="tbquestions" ofType="com.xhkjedu.smarking.vo.scan.TemplateBlockQuestionVo" javaType="java.util.ArrayList">
80 82
                 <result property="mtbqid" column="mtbqid"/>
81 83
                 <result property="qn" column="qn"/>
82 84
                 <result property="mptqid" column="mptqid"/>
@@ -86,7 +88,7 @@
86 88
         </collection>
87 89
     </resultMap>
88 90
     <select id="listTemplateBlockQueByMpid" resultMap="paperTemplate">
89
-        select t.mtid,t.mpid,t.tsize,t.twidth,t.theight,t.blankindex,t.anglefront,t.angleback,t.coorfront,t.coorback,
91
+        select t.mtid,t.mpid,t.tsize,t.twidth,t.theight,t.tfront,t.tback,t.blankindex,t.anglefront,t.angleback,t.coorfront,t.coorback,
90 92
         t.dwtfront,t.dwtback,t.misscoor,t.violatecoor,t.examnocoor,t.cardcoor
91 93
         ,tb.mtbid,tb.mblockid,tb.mttype,tb.mtborder,tb.localcoor,tb.extendcoor,tb.scorecoor
92 94
         ,q.mtbqid,q.qn,q.mptqid,q.qlocalcoor,q.mtbqorder

+ 2
- 3
smarking/src/main/resources/mapper/report/reportclass/MsrClassQuestionMapper.xml View File

@@ -92,14 +92,13 @@
92 92
 
93 93
     <!--学科报告-各班学科试题分析-->
94 94
     <select id="listQuestionForXh" resultType="com.xhkjedu.smarking.model.report.reportclass.MsrClassQuestion">
95
-        select q.cqid,q.mptqid,q.classid,q.qn,q.qtype,q.fullscore,
95
+        select distinct q.cqid,q.mptqid,q.classid,q.qn,q.qtype,q.qorder,q.fullscore,
96 96
         q.classavgrate,q.schoolavgrate,q.scorerate,q.scoreratec,q.nd,q.ndms,q.ndfw,q.qfd,q.qfdms,c.classname
97 97
         from msr_class_question q left join ms_class c on q.examid=c.examid
98 98
         and q.subjectid=c.subjectid and q.classid=c.classid
99 99
         where q.examid=#{param.examid} and q.subjectid=#{param.subjectid}
100 100
         <if test="param.selclass == 3">
101
-            and q.classid in
102
-            <foreach collection="param.classids" item="item" open="(" separator="," close=")">#{item}</foreach>
101
+            and q.classid in (${param.classids})
103 102
         </if>
104 103
         <if test="param.selclass == 4"> and q.classid = #{param.classid}</if>
105 104
         order by q.mptqid

+ 3
- 3
smarking/src/main/resources/mapper/report/reportclass/MsrClassSubjectGradeMapper.xml View File

@@ -3,9 +3,9 @@
3 3
 <mapper namespace="com.xhkjedu.smarking.mapper.report.reportclass.MsrClassSubjectGradeMapper">
4 4
 
5 5
     <!--综合报告-试题汇总表-全部班级-科目情况-四率等级分析-->
6
-    <select id="listSubjectGrade" resultType="com.xhkjedu.smarking.model.report.reportclass.MsrClassSubjectGrade">
7
-        select * from msr_class_subject_grade where examid = #{sg.examid} and subjectid = #{sg.subjectId}
8
-        and reportcode = #{sg.reportCode} and classid = #{sg.classId}
6
+    <select id="listSubjectGrade" resultType="java.util.Map">
7
+        select csgid,rangename,rangenum,rangerate,djscore,djrate from msr_class_subject_grade where examid = #{sg.examid} and subjectid = #{sg.subjectid}
8
+        and reportcode = #{sg.reportcode} and classid = #{sg.classid}
9 9
     </select>
10 10
     <!--综合报告-班级对比-全科及格率分析-->
11 11
     <select id="listSubjectGradeForQk" resultType="com.xhkjedu.smarking.model.report.reportclass.MsrClassSubjectGrade">

+ 3
- 5
smarking/src/main/resources/mapper/report/reportstu/MsrStudentMapper.xml View File

@@ -32,27 +32,25 @@
32 32
         <result property="totalscore" column="totalscore"/>
33 33
         <collection property="questions" ofType="java.util.Map" javaType="java.util.ArrayList">
34 34
             <result property="mpsqid" column="mpsqid"/>
35
-            <result property="qn" column="qn"/>
36 35
             <result property="stuscore" column="xtscore"/>
37 36
             <result property="answertype" column="answertype"/>
38 37
             <result property="stuanswer" column="stuanswer"/>
39 38
             <result property="qanswer" column="qanswer"/>
40 39
             <result property="qscore" column="qscore"/>
41 40
             <result property="qtype" column="qtype"/>
42
-            <result property="mptqn" column="mptqn"/>
41
+            <result property="qnstr" column="qnstr"/>
43 42
         </collection>
44 43
     </resultMap>
45 44
     <select id="listStuScoreAndRankByExamidAndSubjectid" resultMap="studentChengji">
46 45
         select distinct s.rsid,s.examid,s.subjectid,s.studentid,s.classid,c.classname,s.stuscore,s.classrank,
47 46
         s.schoolrank,s.objscore,s.subscore,sq.mpsqid,sq.qn,sq.stuscore as xtscore,sq.answertype,sq.stuanswer,
48
-        q.qanswer,q.qscore,q.qtype,qt.mptqn
47
+        q.qanswer,q.qscore,q.qtype,q.qnstr
49 48
         from msr_student s left join ms_class c on s.classid=c.classid
50 49
         left join ms_paper_student_question sq on s.examid=sq.examid
51 50
         and s.subjectid=sq.subjectid and s.studentid=sq.studentid
52 51
         left join ms_paper_qtype_question q on sq.mptqid=q.mptqid
53
-        left join ms_paper_qtype qt on q.mptid=qt.mptid
54 52
         where s.examid=#{examid} and s.subjectid=#{subjectid}
55
-        order by s.schoolrank,s.rsid,qt.mptorder,q.qorder
53
+        order by s.schoolrank,s.rsid,q.qorder
56 54
     </select>
57 55
 
58 56
     <!--学生报告-学生学科试题分析-->

Loading…
Cancel
Save