|
@@ -16,6 +16,7 @@ import cn.com.qmth.examcloud.web.support.ControllerSupport;
|
|
|
import com.google.common.collect.Lists;
|
|
|
import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
+import org.apache.commons.lang3.StringUtils;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.LoggerFactory;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
@@ -68,8 +69,10 @@ public class SyncCloudServiceProvider extends ControllerSupport implements Handl
|
|
|
if (examStudent != null && (examStudent.getFinished() == null || !examStudent.getFinished())) {
|
|
|
examStudentRepo.delete(examStudent);
|
|
|
examStudentCache.remove(examStudent.getId());
|
|
|
- log.warn("删除考生信息成功!!studentId:{} studentCode:{} identityNumber:{} ew-examStudentId:{} oe-examStudentId:{} ",
|
|
|
- examStudent.getStudentId(), examStudent.getStudentCode(), examStudent.getIdentityNumber(), examStudent.getExamStudentId(), examStudent.getId());
|
|
|
+
|
|
|
+ log.warn("删除考生成功!studentId:{} studentCode:{} identityNumber:{} ew-examStudentId:{} oe-examStudentId:{}",
|
|
|
+ examStudent.getStudentId(), examStudent.getStudentCode(), examStudent.getIdentityNumber(),
|
|
|
+ examStudent.getExamStudentId(), examStudent.getId());
|
|
|
}
|
|
|
} else if ("update".equals(req.getSyncType())) {
|
|
|
ExamStudentInfo examStudent = ExamStudentBeanConvert.of(req);
|
|
@@ -77,10 +80,12 @@ public class SyncCloudServiceProvider extends ControllerSupport implements Handl
|
|
|
for (Long cur : examStudentIdList) {
|
|
|
examStudentCache.refresh(cur);
|
|
|
}
|
|
|
+
|
|
|
+ log.info("[syncExamStudent] examId:{} courseCode:{} studentId:{} examStudentId:{} studentCode:{} identityNumber:{}",
|
|
|
+ req.getExamId(), req.getCourseCode(), req.getStudentId(), req.getId(), req.getStudentCode(), req.getIdentityNumber());
|
|
|
}
|
|
|
|
|
|
- SyncExamStudentResp resp = new SyncExamStudentResp();
|
|
|
- return resp;
|
|
|
+ return new SyncExamStudentResp();
|
|
|
} finally {
|
|
|
SequenceLockHelper.releaseLockSimple(sequenceLockKey);
|
|
|
}
|
|
@@ -103,14 +108,17 @@ public class SyncCloudServiceProvider extends ControllerSupport implements Handl
|
|
|
long studentId = req.getId();
|
|
|
String studentName = req.getName();
|
|
|
|
|
|
- // examStudentRepo.updateStudentNameAndStudentCode(studentId, studentName, studentCode);
|
|
|
- // examRecordRepo.updateStudentNameAndStudentCode(studentId, studentName, studentCode);
|
|
|
examStudentRepo.updateStudentName(studentId, studentName);
|
|
|
examRecordDataRepo.updateStudentName(studentId, studentName);
|
|
|
+
|
|
|
//如果有需要解绑的学号信息,需要对学号进行解绑
|
|
|
if (null != req.getUnboundStudentCodeList() && !req.getUnboundStudentCodeList().isEmpty()) {
|
|
|
examStudentRepo.updateExamStudentCode(req.getIdentityNumber(), req.getUnboundStudentCodeList());
|
|
|
+
|
|
|
+ log.warn("解绑学号!studentId:{} identityNumber:{} studentCodes:{}",
|
|
|
+ studentId, req.getIdentityNumber(), StringUtils.join(req.getUnboundStudentCodeList(), ","));
|
|
|
}
|
|
|
+
|
|
|
return null;
|
|
|
}
|
|
|
|
|
@@ -134,9 +142,7 @@ public class SyncCloudServiceProvider extends ControllerSupport implements Handl
|
|
|
|
|
|
@Override
|
|
|
public SyncUserResp syncUser(SyncUserReq req) {
|
|
|
- // TODO Auto-generated method stub
|
|
|
return null;
|
|
|
}
|
|
|
|
|
|
-
|
|
|
}
|