|
@@ -132,14 +132,6 @@ public class ExamControlServiceImpl implements ExamControlService {
|
|
public StartExamInfo startExam(Long examStudentId, User user) {
|
|
public StartExamInfo startExam(Long examStudentId, User user) {
|
|
Long studentId = user.getUserId();
|
|
Long studentId = user.getUserId();
|
|
long st = System.currentTimeMillis();
|
|
long st = System.currentTimeMillis();
|
|
- SysPropertyCacheBean stuClientLoginLimit = CacheHelper.getSysProperty("STU_CLIENT_LOGIN_LIMIT");
|
|
|
|
- Boolean stuClientLoginLimitBoolean = false;
|
|
|
|
- if (stuClientLoginLimit.getHasValue()) {
|
|
|
|
- stuClientLoginLimitBoolean = Boolean.valueOf(stuClientLoginLimit.getValue().toString());
|
|
|
|
- }
|
|
|
|
- if (stuClientLoginLimitBoolean) {
|
|
|
|
- throw new StatusException("1001", "系统维护中... ...");
|
|
|
|
- }
|
|
|
|
|
|
|
|
long startTime = System.currentTimeMillis();
|
|
long startTime = System.currentTimeMillis();
|
|
if (log.isDebugEnabled()) {
|
|
if (log.isDebugEnabled()) {
|
|
@@ -240,10 +232,9 @@ public class ExamControlServiceImpl implements ExamControlService {
|
|
|
|
|
|
//保存考试次数控制信息
|
|
//保存考试次数控制信息
|
|
ExamBoss eb = examBossService.getExamBoss(examingSession.getExamId());
|
|
ExamBoss eb = examBossService.getExamBoss(examingSession.getExamId());
|
|
- if (eb == null) {
|
|
|
|
- eb = new ExamBoss();
|
|
|
|
- eb.setStartCount(0);
|
|
|
|
- }
|
|
|
|
|
|
+ if (eb == null) {
|
|
|
|
+ throw new StatusException("008001", "ExamBoss is not created");
|
|
|
|
+ }
|
|
eb.setStartCount(eb.getStartCount() + 1);
|
|
eb.setStartCount(eb.getStartCount() + 1);
|
|
examBossService.saveExamBoss(examId, eb);
|
|
examBossService.saveExamBoss(examId, eb);
|
|
|
|
|