Browse Source

Merge remote-tracking branch 'cloud-schoolapi/ywx'

tags/正式版本
王宁 2 years ago
parent
commit
0c497a17ae

+ 5
- 2
sstudy/src/main/java/com/xhkjedu/sstudy/service/paper/PaperAnalyzeService.java View File

@@ -137,10 +137,13 @@ public class PaperAnalyzeService {
137 137
      * @return com.xhkjedu.sstudy.vo.paper.QuestionAnalyzeVo
138 138
      **/
139 139
     public QuestionAnalyzeVo getQuestionDetailAnalyze(AnalyzeQuestionVo question) {
140
-        QuestionAnalyzeVo analyze = paperAnalyzeMapper.getQuestionDetailAnalyze(question);
141 140
         String questionpid = question.getQuestionpid();
142 141
         String questionid = question.getQuestionid();
143
-        if(N_Utils.isEmpty(questionpid)) question.setQuestionpid(questionid);
142
+        if(N_Utils.isEmpty(questionpid)) {
143
+            question.setQuestionpid(questionid);
144
+            questionpid=questionid;
145
+        }
146
+        QuestionAnalyzeVo analyze = paperAnalyzeMapper.getQuestionDetailAnalyze(question);
144 147
         if (!questionpid.equals(questionid)) {
145 148
             List<Map> sonqlist = questionMapper.listSonQuestionsForDetail(questionpid);
146 149
             analyze.setSonqlist(sonqlist);

+ 1
- 0
sstudy/src/main/java/com/xhkjedu/sstudy/service/paperstudent/PaperStudentService.java View File

@@ -145,6 +145,7 @@ public class PaperStudentService {
145 145
                 q.setMhashear(mt.getHashear());
146 146
                 q.setMhearfile(mt.getHearfile());
147 147
                 q.setMqlevel(mt.getQlevel());
148
+                q.setMctype(mt.getCtype());
148 149
             }
149 150
         }
150 151
         return list;

+ 1
- 0
sstudy/src/main/java/com/xhkjedu/sstudy/vo/paperstudent/PaperStudentQuestionVo.java View File

@@ -108,6 +108,7 @@ public class PaperStudentQuestionVo {
108 108
     private String hearfile;//听力题文件地址
109 109
     private Integer qlevel;//试题级别1单题2母题
110 110
     private Integer mqlevel;//母题试题级别1单题2母题
111
+    private Integer mctype;//母题处理题型
111 112
     private Integer sorder;//子题排序
112 113
     private String questionpid;//母题id
113 114
     private String qn;//显示题号

+ 1
- 1
sstudy/src/main/resources/mapper/paperstudent/PaperStudentQuestionMapper.xml View File

@@ -11,7 +11,7 @@
11 11
         ,(CASE WHEN q.ctype IN(16,17) THEN JSON_LENGTH(q.qoption) ELSE 0 END)qoptioncount
12 12
         ,(CASE WHEN q.questionpid IS NULL THEN ''
13 13
         ELSE (SELECT json_object('qstem',fq.qstem,'qoption',fq.qoption,'qanswer',fq.qanswer,'qanalyze',fq.qanalyze
14
-            ,'qtypename',fq.qtypename,'hashear',fq.hashear,'hearfile',fq.hearfile,'qlevel',fq.qlevel)
14
+            ,'qtypename',fq.qtypename,'hashear',fq.hashear,'hearfile',fq.hearfile,'qlevel',fq.qlevel,'ctype',fq.ctype)
15 15
         FROM t_question fq WHERE fq.questionid=q.questionpid) END)mqstem
16 16
         FROM t_paper_student_question psq LEFT JOIN t_question q ON psq.questionid=q.questionid
17 17
         LEFT JOIN t_user u ON psq.studentid=u.userid

+ 2
- 2
sstudy/src/main/resources/mapper/question/QuestionClassMapper.xml View File

@@ -3,13 +3,13 @@
3 3
 <mapper namespace="com.xhkjedu.sstudy.mapper.question.QuestionClassMapper">
4 4
     <!--作业统计按题-->
5 5
     <select id="getQuestionAnalyze" resultType="com.xhkjedu.sstudy.model.question.TQuestionClass">
6
-        select ptq.questionid,ptq.ptqorder qorder,ptq.ptqscore qscore,sum(ifnull(psq.stuscore,0))stuscore,ptq.schoolid,q.qtypeid
6
+        select ptq.questionpid,ptq.ptqorder qorder,ptq.mscore qscore,sum(ifnull(psq.stuscore,0))stuscore,ptq.schoolid,ptq.mqtypeid qtypeid
7 7
         ,(select count(*) from t_paper_student ps where ps.paperid=#{paperid} and ps.classid=#{classid}
8 8
         <if test="qctype==3">and locate(concat('"',ptq.questionid,'"'),ps.questionids)>0</if>)stunum
9 9
         from t_paper_qtype_question ptq left join t_question q on ptq.questionid=q.questionid
10 10
         left join t_paper_student_question psq on ptq.paperid = psq.paperid and ptq.questionid=psq.questionid and psq.classid=#{classid}
11 11
         where ptq.paperid=#{paperid}
12
-        group by ptq.questionid having stunum!=0 order by ptq.ptqorder
12
+        group by ptq.ptqorder having stunum!=0 order by ptq.ptqorder
13 13
     </select>
14 14
     <!--答题卡作业统计按题-->
15 15
     <select id="getSQuestionAnalyze" resultType="com.xhkjedu.sstudy.model.question.TQuestionClass">

Loading…
Cancel
Save