Pārlūkot izejas kodu

完善题库作业详情

tags/正式3.10.0
王宁 pirms 1 gada
vecāks
revīzija
9a2e0b0898

+ 1
- 0
sstudy/src/main/java/com/xhkjedu/sstudy/service/paper/PaperService.java Parādīt failu

@@ -969,6 +969,7 @@ public class PaperService {
969 969
                     q.setPtqorder(tq.getPtqorder());
970 970
                     q.setSonqlist(JSON.parseArray(JSON.toJSONString(list), Map.class));
971 971
                     q.setQtypename(type.getQtypename());
972
+                    q.setQtypeid(type.getQtypeid());
972 973
                     q.setComplexity(tq.getComplexity());
973 974
                 } else {
974 975
                     q = tq;

+ 3
- 2
sstudy/src/main/resources/mapper/paper/PaperMapper.xml Parādīt failu

@@ -25,13 +25,14 @@
25 25
             <result property="complexity" column="complexity"/>
26 26
             <result property="count" column="count"/>
27 27
             <result property="qtypename" column="typename"/>
28
+            <result property="qtypeid" column="typeid"/>
28 29
         </collection>
29 30
     </resultMap>
30 31
     <!--获取作业题型列表-->
31 32
     <select id="listPaperType" resultMap="typeResult">
32 33
         select pt.qtypeid,pt.qtypename,pt.ptorder,pt.ptscore,pt.ptnum,ptq.questionid,ptq.ptqscore as score,ptq.ptqorder,ptq.qn
33 34
         ,q.questionid,ifnull(q.questionpid,q.questionid)as questionpid,q.qlevel,q.ctype,q.qstem,q.qoption,q.qanswer,q.qanalyze
34
-        ,q.hashear,q.hearfile,q.complexity,q.count,q.qtypename typename,pt.ctype pctype
35
+        ,q.hashear,q.hearfile,q.complexity,q.count,q.qtypeid typeid,q.qtypename typename,pt.ctype pctype
35 36
         from t_paper_qtype pt left join t_paper_qtype_question ptq on pt.ptid = ptq.ptid
36 37
         left join t_question q on ptq.questionid = q.questionid
37 38
         where pt.paperid=#{paperid} order by pt.ptorder,ptq.ptqid
@@ -379,7 +380,7 @@
379 380
     </select>
380 381
     <!--作业母题列表-->
381 382
     <select id="listQuestionByQuestionIds" resultType="com.xhkjedu.sstudy.vo.question.QuestionVo">
382
-        select questionid,ctype,qstem,qoption,qanswer,qanalyze,q.hashear,q.hearfile
383
+        select questionid,ctype,qstem,qoption,qanswer,qanalyze,q.hashear,q.hearfile,q.count
383 384
         from t_question q where questionid in
384 385
         <foreach collection="questionids" item="questionid" open="(" separator="," close=")">
385 386
             #{questionid}

Notiek ielāde…
Atcelt
Saglabāt