Explorar o código

Merge branch 'dev'
1

wangliang %!s(int64=4) %!d(string=hai) anos
pai
achega
233afe20ed

+ 8 - 4
themis-business/src/main/java/com/qmth/themis/business/service/impl/TEExamServiceImpl.java

@@ -539,7 +539,8 @@ public class TEExamServiceImpl extends ServiceImpl<TEExamMapper, TEExam> impleme
      * 提交作答结果
      */
     @Override
-    public AnswerSubmitBean answerSubmit(Long studentId, Long recordId, Integer mainNumber, Integer subNumber, Integer subIndex,
+    public AnswerSubmitBean answerSubmit(Long studentId, Long recordId, Integer mainNumber, Integer
+            subNumber, Integer subIndex,
                                          String answer, Long version, Integer durationSeconds) {
 
         // 校验当前登录用户和参数一致性
@@ -626,7 +627,8 @@ public class TEExamServiceImpl extends ServiceImpl<TEExamMapper, TEExam> impleme
      * 更新音频剩余播放次数
      */
     @Override
-    public AudioLeftPlayCountSubmitBean audioLeftPlayCountSubmit(Long studentId, Long recordId, String key, Integer count) {
+    public AudioLeftPlayCountSubmitBean audioLeftPlayCountSubmit(Long studentId, Long recordId, String key, Integer
+            count) {
 
         // 校验当前登录用户和参数一致性
         if (ExamRecordCacheUtil.getId(recordId) == null) {
@@ -656,7 +658,8 @@ public class TEExamServiceImpl extends ServiceImpl<TEExamMapper, TEExam> impleme
      * 文件上传
      */
     @Override
-    public ExamFileUploadBean fileUpload(Long studentId, Long recordId, MultipartFile file, String suffix, String md5) {
+    public ExamFileUploadBean fileUpload(Long studentId, Long recordId, MultipartFile file, String suffix, String
+            md5) {
 
         // 校验当前登录用户和参数一致性
         if (ExamRecordCacheUtil.getId(recordId) == null) {
@@ -1060,7 +1063,8 @@ public class TEExamServiceImpl extends ServiceImpl<TEExamMapper, TEExam> impleme
      * @param mqDto
      */
     @Override
-    public void sendOeLogMessage(SystemOperationEnum systemOperationEnum, Long examStudentId, Long recordId, MqDto mqDto) {
+    public void sendOeLogMessage(SystemOperationEnum systemOperationEnum, Long examStudentId, Long recordId, MqDto
+            mqDto) {
         //mq发送消息start
         Map<String, Object> properties = new HashMap<>();
         properties.put("remark", systemOperationEnum.getCode());

+ 6 - 6
themis-business/src/main/resources/mapper/TOeExamRecordMapper.xml

@@ -148,10 +148,10 @@
 			<if test="identity != null and identity !=''">
 				and s.identity like CONCAT('%', #{identity},'%')
 			</if>
-			<if test="maxWarningCount != null and maxWarningCount != ''">
+			<if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
 				and t.warning_count &lt;= #{maxWarningCount}
 			</if>
-			<if test="minWarningCount != null and minWarningCount != ''">
+			<if test="minWarningCount != null and minWarningCount != '' or minWarningCount == 0">
 				and t.warning_count &gt;= #{minWarningCount}
 			</if>
 			<if
@@ -181,7 +181,7 @@
 		,date_format(date_sub(from_unixtime(IFNULL(teea.max_duration_seconds, tee.max_duration_seconds) - t.duration_seconds),INTERVAL 8 HOUR), '%H:%i:%s') as remainTime
         <include refid="invigilatePageMiddle"/>
 		<include refid="invigilatePageFoot"/>
-        <if test="paperDownload != null and paperDownload != ''">
+        <if test="paperDownload != null and paperDownload != '' or paperDownload == 0">
             and t.paper_download = #{paperDownload}
         </if>
 		<if test="status == null or status == ''">
@@ -204,7 +204,7 @@
 		,date_format(date_sub(from_unixtime(IFNULL(teea.max_duration_seconds, tee.max_duration_seconds) - t.duration_seconds),INTERVAL 8 HOUR), '%H:%i:%s') as remainTime
 		<include refid="invigilatePageMiddle" />
 		<include refid="invigilatePageFoot" />
-		<if test="paperDownload != null and paperDownload != ''">
+		<if test="paperDownload != null and paperDownload != '' or paperDownload == 0">
 			and t.paper_download = #{paperDownload}
 		</if>
 		<if test="status == null or status == ''">
@@ -317,10 +317,10 @@
 			<if test="identity != null and identity !=''">
 				and tees.identity like CONCAT('%', #{identity},'%')
 			</if>
-			<if test="maxWarningCount != null and maxWarningCount != ''">
+			<if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
 				and toer.warning_count &lt;= #{maxWarningCount}
 			</if>
-			<if test="minWarningCount != null and minWarningCount != ''">
+			<if test="minWarningCount != null and minWarningCount != '' or minWarningCount == 0">
 				and toer.warning_count &gt;= #{minWarningCount}
 			</if>
 			<if