|
@@ -222,7 +222,7 @@ public class MqLogicServiceImpl implements MqLogicService {
|
|
|
if (Objects.nonNull(objectMap)) {
|
|
|
Integer diff = 0;
|
|
|
if (Objects.nonNull(clientLastSyncTime)) {//大于等于当前时间,说明未重连或重登录
|
|
|
- Long l = (System.currentTimeMillis() - clientLastSyncTime.getTime()) / 1000 / 60;
|
|
|
+ Long l = (System.currentTimeMillis() - clientLastSyncTime.getTime()) / 1000;
|
|
|
if (l >= 2 && !Objects.equals(objectMap.get("status"), ExamRecordStatusEnum.FINISHED)) {
|
|
|
diff = l.intValue();
|
|
|
//是否增加断点记录或者交卷处理统一放登录逻辑里处理,这里只更新考试记录状态为中断
|
|
@@ -234,7 +234,7 @@ public class MqLogicServiceImpl implements MqLogicService {
|
|
|
Long examId = Long.parseLong(String.valueOf(objectMap.get("examId")));
|
|
|
Long examActivityId = Long.parseLong(String.valueOf(objectMap.get("examActivityId")));
|
|
|
Long examStudentId = Long.parseLong(String.valueOf(objectMap.get("examStudentId")));
|
|
|
- TIeInvigilateExceptionInfo tIeInvigilateExceptionInfo = new TIeInvigilateExceptionInfo(examId, examActivityId, recordId, examStudentId, ExceptionEnum.NET_TIME_OUT.getCode(), ExceptionEnum.NET_TIME_OUT, String.valueOf(diff));
|
|
|
+ TIeInvigilateExceptionInfo tIeInvigilateExceptionInfo = new TIeInvigilateExceptionInfo(examId, examActivityId, recordId, examStudentId, ExceptionEnum.NET_TIME_OUT.getCode(), ExceptionEnum.NET_TIME_OUT, diff);
|
|
|
tIeInvigilateExceptionInfoService.saveOrUpdate(tIeInvigilateExceptionInfo);
|
|
|
}
|
|
|
TMRocketMessage tmRocketMessage = gson.fromJson(gson.toJson(mqDto), TMRocketMessage.class);
|
|
@@ -447,7 +447,7 @@ public class MqLogicServiceImpl implements MqLogicService {
|
|
|
Date clientLastSyncTime = ExamRecordCacheUtil.getClientLastSyncTime(recordId);
|
|
|
Integer diff = 0;
|
|
|
if (Objects.nonNull(clientLastSyncTime)) {
|
|
|
- Long l = ((System.currentTimeMillis() - clientLastSyncTime.getTime()) / 1000 / 60);
|
|
|
+ Long l = ((System.currentTimeMillis() - clientLastSyncTime.getTime()) / 1000);
|
|
|
diff = l.intValue();
|
|
|
}
|
|
|
|
|
@@ -485,7 +485,6 @@ public class MqLogicServiceImpl implements MqLogicService {
|
|
|
objectMap.put("lastBreakTime", new Date());
|
|
|
objectMap.put("leftBreakResumeCount", leftBreakResumeCount);
|
|
|
objectMap.put("lastStartTime", new Date());
|
|
|
- objectMap.put("exceptionStatus", exceptionEnum);
|
|
|
redisUtil.setForHash(RedisKeyHelper.examRecordCacheKey(recordId), objectMap);
|
|
|
UpdateWrapper<TOeExamRecord> tOeExamRecordUpdateWrapper = new UpdateWrapper<>();
|
|
|
tOeExamRecordUpdateWrapper.lambda().set(TOeExamRecord::getLastBreakId, tOeExamBreakHistory.getId())
|
|
@@ -493,7 +492,6 @@ public class MqLogicServiceImpl implements MqLogicService {
|
|
|
.set(TOeExamRecord::getLastBreakTime, objectMap.get("lastBreakTime"))
|
|
|
.set(TOeExamRecord::getLeftBreakResumeCount, leftBreakResumeCount)
|
|
|
.set(TOeExamRecord::getLastStartTime, objectMap.get("lastStartTime"))
|
|
|
- .set(TOeExamRecord::getExceptionStatus, exceptionEnum)
|
|
|
.eq(TOeExamRecord::getId, recordId);
|
|
|
examRecordService.update(tOeExamRecordUpdateWrapper);
|
|
|
teExamStudentLogService.saveStudentLogInfo(SystemOperationEnum.RESUME_PREPARE.name(), SystemOperationEnum.RESUME_PREPARE.getCode(), SystemOperationEnum.RESUME_PREPARE.getCode(), examStudentCacheBean.getStudentId(), examStudentId, recordId);
|
|
@@ -502,7 +500,7 @@ public class MqLogicServiceImpl implements MqLogicService {
|
|
|
//增加异常日志
|
|
|
Long examId = Long.parseLong(String.valueOf(objectMap.get("examId")));
|
|
|
Long examActivityId = Long.parseLong(String.valueOf(objectMap.get("examActivityId")));
|
|
|
- TIeInvigilateExceptionInfo tIeInvigilateExceptionInfo = new TIeInvigilateExceptionInfo(examId, examActivityId, recordId, examStudentId, String.valueOf(jsonObject.getJSONObject("reason").get("reason")), exceptionEnum, String.valueOf(diff));
|
|
|
+ TIeInvigilateExceptionInfo tIeInvigilateExceptionInfo = new TIeInvigilateExceptionInfo(examId, examActivityId, recordId, examStudentId, String.valueOf(jsonObject.getJSONObject("reason").get("reason")), exceptionEnum, diff);
|
|
|
tIeInvigilateExceptionInfoService.saveOrUpdate(tIeInvigilateExceptionInfo);
|
|
|
} else if (tag.contains(MqTagEnum.WARNING_LOG.name())) {//考试预警日志
|
|
|
|