瀏覽代碼

班级错题报告 v3.3.2

学生错题集 v3.3.2
课堂批量结束 v3.3.1
tags/正式3.4.0
雍文秀 2 年之前
父節點
當前提交
3778990ca1

+ 1
- 1
sapi/src/main/resources/application.properties 查看文件

@@ -100,4 +100,4 @@ cron.syncnum=100
100 100
 #每隔3s清除一下请求地址map
101 101
 cron.deleteUriMap=0/3 * * * * ?
102 102
 #版本号
103
-versionname=Test_v3.3.1
103
+versionname=Test_v3.3.2

+ 1
- 1
sapi/src/main/resources/mapper/classreport/ClassReportMapper.xml 查看文件

@@ -257,7 +257,7 @@
257 257
         left join t_paper_student_question psq on psq.paperid=p.paperid and psq.classid=qc.classid
258 258
         left join t_question_point qp on psq.questionid=qp.questionid
259 259
         where qc.schoolid=#{type.schoolid} AND qc.classid=#{type.classid} AND p.subjectid=#{type.subjectid}
260
-        and qc.qctype=1 and qp.pointid is not null
260
+        and qc.qctype in(1,3) and qp.pointid is not null
261 261
         <if test="type.reporttype==1">and YEARWEEK(FROM_UNIXTIME(qc.createtime,'%Y-%m-%d'),1)=YEARWEEK(now(),1)-#{type.basenum}</if>
262 262
         <if test="type.reporttype==2">and MONTH(FROM_UNIXTIME(qc.createtime))=MONTH(now())-#{type.basenum}</if>
263 263
         <if test="type.reporttype==3">and YEARWEEK(FROM_UNIXTIME(qc.createtime,'%Y-%m-%d'),1)=YEARWEEK(now(),1)</if>

+ 1
- 1
sclass/src/main/resources/application.properties 查看文件

@@ -63,4 +63,4 @@ enable.scheduled=false
63 63
 cron.deleteUriMap=0/3 * * * * ?
64 64
 
65 65
 #版本号
66
-versionname=Test_v3.3.0
66
+versionname=Test_v3.3.1

+ 1
- 1
sclass/src/main/resources/mapper/classroom/ClassroomMapper.xml 查看文件

@@ -383,7 +383,7 @@
383 383
     <update id="updateBatchRoomState" parameterType="java.util.List">
384 384
         UPDATE t_classroom set roomstate=2,endtime=createtime+60 * 45 WHERE
385 385
         <foreach collection="list" item="classid" index="index" separator="or">
386
-            classid=#{classid} and roomstate=1
386
+            (classid=#{classid} and roomstate=1)
387 387
         </foreach>
388 388
     </update>
389 389
     <!--课堂回顾详情-->

+ 3
- 2
sstudy/src/main/java/com/xhkjedu/sstudy/mapper/question/QuestionStudentMapper.java 查看文件

@@ -68,12 +68,13 @@ public interface QuestionStudentMapper extends TkMapper<TQuestionStudent> {
68 68
 
69 69
     /**
70 70
      * 结构试题详情
71
+     *
72
+     * @return com.xhkjedu.vo.question.QuestionStudentVo
71 73
      * @Param [questionid, studentid]
72 74
      * @Author ywx
73 75
      * @Date 2020/9/5 9:41
74
-     * @return com.xhkjedu.vo.question.QuestionStudentVo
75 76
      **/
76
-    QuestionStudentVo detail(String questionid, Integer studentid);
77
+    QuestionStudentVo detail(@Param("questionid") String questionid, @Param("studentid") Integer studentid, @Param("qctype") Integer qctype);
77 78
 
78 79
     /**
79 80
      * 附件试题详情

+ 2
- 1
sstudy/src/main/java/com/xhkjedu/sstudy/service/question/QuestionClassService.java 查看文件

@@ -151,7 +151,8 @@ public class QuestionClassService {
151 151
 
152 152
     //获取错题详情
153 153
     private void listQuestionDetail(List<QuestionClassVo> all, List<QuestionClassVo> questions, List<QuestionClassVo> scantrons, List<TQuestionExplain> explainAll) {
154
-        List<String> questionids = all.stream().filter(q -> q.getQctype() == 1).map(QuestionClassVo::getQuestionid).collect(Collectors.toList());
154
+        List<String> questionids = all.stream().filter(q -> q.getQctype() == 1 || q.getQctype() == 3)
155
+                .map(QuestionClassVo::getQuestionid).collect(Collectors.toList());
155 156
         List<String> sids = all.stream().filter(q -> q.getQctype() == 2).map(QuestionClassVo::getQuestionid).collect(Collectors.toList());
156 157
         if (N_Utils.isListNotEmpty(questionids)) questions.addAll(questionClassMapper.getQuestionById(questionids));
157 158
         if (N_Utils.isListNotEmpty(sids)) scantrons.addAll(questionClassMapper.getScantronById(sids));

+ 3
- 2
sstudy/src/main/java/com/xhkjedu/sstudy/service/question/QuestionStudentService.java 查看文件

@@ -106,7 +106,8 @@ public class QuestionStudentService {
106 106
 
107 107
     //获取错题详情
108 108
     private void listQuestionDetail(List<QuestionStudentVo> list, List<QuestionClassVo> questions, List<QuestionClassVo> scantrons, List<TQuestionExplain> explainAll) {
109
-        List<String> questionids = list.stream().filter(q -> q.getQctype() == 1).map(QuestionStudentVo::getQuestionid).collect(Collectors.toList());
109
+        List<String> questionids = list.stream().filter(q -> q.getQctype() == 1 || q.getQctype() == 3)
110
+                .map(QuestionStudentVo::getQuestionid).collect(Collectors.toList());
110 111
         List<String> sids = list.stream().filter(q -> q.getQctype() == 2).map(QuestionStudentVo::getQuestionid).collect(Collectors.toList());
111 112
         if (N_Utils.isListNotEmpty(questionids)) questions.addAll(questionClassMapper.getQuestionById(questionids));
112 113
         if (N_Utils.isListNotEmpty(sids)) scantrons.addAll(questionClassMapper.getScantronById(sids));
@@ -232,7 +233,7 @@ public class QuestionStudentService {
232 233
     public QuestionStudentVo detailStuWeb(String questionid, Integer qctype, Integer studentid) {
233 234
         QuestionStudentVo question = null;
234 235
         if (qctype == 1 || qctype == 3) {
235
-            question = questionStudentMapper.detail(questionid, studentid);
236
+            question = questionStudentMapper.detail(questionid, studentid, qctype);
236 237
         } else {
237 238
             question = questionStudentMapper.sdetail(questionid, studentid);
238 239
             if (question != null) {

+ 1
- 1
sstudy/src/main/resources/application.properties 查看文件

@@ -107,4 +107,4 @@ file.showurl=http://schoolstatictest.xhkjedu.com/static/
107 107
 dbname=xhkjedu_school_test
108 108
 
109 109
 #版本号
110
-versionname=Test_v3.3.1
110
+versionname=Test_v3.3.2

+ 3
- 3
sstudy/src/main/resources/mapper/question/QuestionClassMapper.xml 查看文件

@@ -91,7 +91,7 @@
91 91
         <if test="question.pointid!=null and question.pointid!='0'.toString() and question.pointid!=''">
92 92
             left join t_question_point qp on q.questionid = qp.questionid
93 93
         </if>
94
-        where qc.qctype=1 and qc.classid=#{question.classid}
94
+        where qc.qctype!=2 and qc.classid=#{question.classid}
95 95
         and UNIX_TIMESTAMP(FROM_UNIXTIME(qc.createtime,'%Y%m%d'))>=#{question.starttime}
96 96
         and UNIX_TIMESTAMP(FROM_UNIXTIME(qc.createtime,'%Y%m%d'))&lt;=#{question.stoptime}
97 97
         <if test="question.subjectid!=null and question.subjectid!='0'.toString() and question.subjectid!=''">
@@ -166,7 +166,7 @@
166 166
         ,(select group_concat(p.pointname separator '  ') from t_question_point qp
167 167
         left join t_point p on qp.pointid = p.pointid where qp.questionid=q.questionid)pointname
168 168
         from (select max(qcid)qcid,questionid from t_question_class
169
-        where questionid=#{question.questionid} and classid=#{question.classid} and qctype=1)a
169
+        where questionid=#{question.questionid} and classid=#{question.classid} and qctype!=2)a
170 170
         left join t_question_class qc on a.qcid=qc.qcid
171 171
         left join t_question q on qc.questionid=q.questionid
172 172
         left join t_paper_student_question psq on qc.paperid=psq.paperid and qc.classid=psq.classid
@@ -209,7 +209,7 @@
209 209
         ,(select group_concat(p.pointname separator '  ') from t_question_point qp
210 210
         left join t_point p on qp.pointid = p.pointid where qp.questionid=q.questionid)pointname
211 211
         from (select max(qcid)qcid,questionid from t_question_class
212
-        where questionid=#{question.questionid} and classid=#{question.classid} and qctype=1)a
212
+        where questionid=#{question.questionid} and classid=#{question.classid} and qctype!=2)a
213 213
         left join t_question_class qc on a.qcid=qc.qcid
214 214
         left join t_question q on qc.questionid=q.questionid
215 215
         left join t_paper_student_question psq on qc.paperid=psq.paperid and qc.classid=psq.classid

+ 1
- 1
sstudy/src/main/resources/mapper/question/QuestionExplainMapper.xml 查看文件

@@ -31,7 +31,7 @@
31 31
         from t_question_explain qe left join t_user u on qe.createid=u.userid
32 32
         where
33 33
         <foreach collection="questions" item="question" index="index" separator="or">
34
-            qe.questionid=#{question.questionid} and qe.qctype=#{question.qctype}
34
+            (qe.questionid=#{question.questionid} and qe.qctype=${question.qctype})
35 35
         </foreach>
36 36
         order by qe.createtime desc
37 37
     </select>

+ 1
- 1
sstudy/src/main/resources/mapper/question/QuestionStudentMapper.xml 查看文件

@@ -102,7 +102,7 @@
102 102
         ,(select group_concat(p.pointname separator '  ') from t_question_point qp
103 103
         left join t_point p on qp.pointid = p.pointid where qp.questionid=qs.questionid)pointname
104 104
         from t_question_student qs left join t_question q on qs.questionid=q.questionid
105
-        where qs.questionid=#{questionid} and qs.studentid=#{studentid} and qs.qctype=1 limit 1
105
+        where qs.questionid=#{questionid} and qs.studentid=#{studentid} and qs.qctype=#{qctype} limit 1
106 106
     </select>
107 107
     <!--附件试题详情-->
108 108
     <select id="sdetail" resultType="com.xhkjedu.sstudy.vo.question.QuestionStudentVo">

Loading…
取消
儲存