|
@@ -70,6 +70,8 @@ public class ExamRoomServiceImpl extends BaseServiceImpl<Long, ExamRoom> impleme
|
|
|
@Autowired
|
|
|
private StudentExamResultDao studentExamResultDao;
|
|
|
@Autowired
|
|
|
+ private ExamReviewDao examReviewDao;
|
|
|
+ @Autowired
|
|
|
private ExamOrganizationRelationDao examOrganizationRelationDao;
|
|
|
@Autowired
|
|
|
private ExamLifecycleLogDao examLifecycleLogDao;
|
|
@@ -788,10 +790,6 @@ public class ExamRoomServiceImpl extends BaseServiceImpl<Long, ExamRoom> impleme
|
|
|
}
|
|
|
if(openFlag == 0){
|
|
|
examRoom.setExamFlag(openFlag);
|
|
|
- Integer num = examRoomStudentRelationService.countSignInNum(examRoomId);
|
|
|
- if(num != null && num > 0){
|
|
|
- throw new BizException("操作失败,当前还有学员未考试");
|
|
|
- }
|
|
|
}
|
|
|
examRoomDao.update(examRoom);
|
|
|
SysUser sysUser = sysUserFeignService.queryUserInfo();
|
|
@@ -839,6 +837,19 @@ public class ExamRoomServiceImpl extends BaseServiceImpl<Long, ExamRoom> impleme
|
|
|
map,null,null,null,YimeiSmsPlugin.PLUGIN_NAME,examinationBasic.getName());
|
|
|
}
|
|
|
}else {
|
|
|
+ //没有未考试的学员
|
|
|
+ Integer num = examRoomStudentRelationService.countSignInNum(examRoomId);
|
|
|
+ if(num != null && num > 0){
|
|
|
+ throw new BizException("操作失败:当前还有学员未考试");
|
|
|
+ }
|
|
|
+ //没有未评审的学员
|
|
|
+ HashMap<String,Object> map = new HashMap();
|
|
|
+ map.put("reviewFlag",0);
|
|
|
+ map.put("teacherId",examRoom.getMainTeacherUserId());
|
|
|
+ int i = examReviewDao.countExamReviewRecordList(map);
|
|
|
+ if(i > 0){
|
|
|
+ throw new BizException("操作失败:存在未评审的学员");
|
|
|
+ }
|
|
|
imFeignService.dismissGroup(sysUser.getId().toString(),examRoomId.toString());
|
|
|
imFeignService.destroyRoom(examRoomId);
|
|
|
}
|