|
@@ -549,6 +549,20 @@ public class CdExamRoomServiceImpl extends ServiceImpl<CdExamRoomMapper, CdExamR
|
|
|
return cdUserSubscribeService.updateBatchById(entityList);
|
|
return cdUserSubscribeService.updateBatchById(entityList);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ @Override
|
|
|
|
|
+ public boolean addExamApplyNum(AddExamApplyNumBo bo) {
|
|
|
|
|
+ CdUserSubscribe userSubscribe = cdUserSubscribeService.getOne(new LambdaQueryWrapper<CdUserSubscribe>()
|
|
|
|
|
+ .eq(CdUserSubscribe::getUserId, bo.getUserId())
|
|
|
|
|
+ .eq(CdUserSubscribe::getOrderGoodsId, bo.getOrderGoodsId()));
|
|
|
|
|
+ if (ObjectUtils.isNull(userSubscribe)){
|
|
|
|
|
+ throw new CustomException("学员学习信息获取有误!");
|
|
|
|
|
+ }
|
|
|
|
|
+ //新增考试次数
|
|
|
|
|
+ userSubscribe.setExamNum(userSubscribe.getExamNum() + bo.getNum());
|
|
|
|
|
+
|
|
|
|
|
+ return cdUserSubscribeService.updateById(userSubscribe);
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
//预约校验
|
|
//预约校验
|
|
|
private void subscribeVerify(BatchSubscribeBo bo) {
|
|
private void subscribeVerify(BatchSubscribeBo bo) {
|
|
|
CdExamRoom courseRoom = getById(bo.getExamId());
|
|
CdExamRoom courseRoom = getById(bo.getExamId());
|