|
@@ -4,10 +4,8 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
import com.qmth.themis.business.annotation.ApiJsonObject;
|
|
import com.qmth.themis.business.annotation.ApiJsonObject;
|
|
import com.qmth.themis.business.annotation.ApiJsonProperty;
|
|
import com.qmth.themis.business.annotation.ApiJsonProperty;
|
|
import com.qmth.themis.business.constant.SystemConstant;
|
|
import com.qmth.themis.business.constant.SystemConstant;
|
|
-import com.qmth.themis.business.entity.TBUser;
|
|
|
|
import com.qmth.themis.business.entity.TIeExamInvigilateCall;
|
|
import com.qmth.themis.business.entity.TIeExamInvigilateCall;
|
|
import com.qmth.themis.business.service.TIeExamInvigilateCallService;
|
|
import com.qmth.themis.business.service.TIeExamInvigilateCallService;
|
|
-import com.qmth.themis.business.util.ServletUtil;
|
|
|
|
import com.qmth.themis.common.enums.ExceptionResultEnum;
|
|
import com.qmth.themis.common.enums.ExceptionResultEnum;
|
|
import com.qmth.themis.common.exception.BusinessException;
|
|
import com.qmth.themis.common.exception.BusinessException;
|
|
import com.qmth.themis.common.util.Result;
|
|
import com.qmth.themis.common.util.Result;
|
|
@@ -79,13 +77,14 @@ public class TIeInvigilateCallController {
|
|
if (Objects.isNull(mapParameter.get("recordId")) || Objects.equals(mapParameter.get("recordId"), "")) {
|
|
if (Objects.isNull(mapParameter.get("recordId")) || Objects.equals(mapParameter.get("recordId"), "")) {
|
|
throw new BusinessException(ExceptionResultEnum.RECORD_ID_IS_NULL);
|
|
throw new BusinessException(ExceptionResultEnum.RECORD_ID_IS_NULL);
|
|
}
|
|
}
|
|
- TBUser tbUser = (TBUser) ServletUtil.getRequestAccount();
|
|
|
|
Long recordId = Long.parseLong(String.valueOf(mapParameter.get("recordId")));
|
|
Long recordId = Long.parseLong(String.valueOf(mapParameter.get("recordId")));
|
|
QueryWrapper<TIeExamInvigilateCall> tIeExamInvigilateCallQueryWrapper = new QueryWrapper<>();
|
|
QueryWrapper<TIeExamInvigilateCall> tIeExamInvigilateCallQueryWrapper = new QueryWrapper<>();
|
|
tIeExamInvigilateCallQueryWrapper.lambda().eq(TIeExamInvigilateCall::getExamRecordId, recordId);
|
|
tIeExamInvigilateCallQueryWrapper.lambda().eq(TIeExamInvigilateCall::getExamRecordId, recordId);
|
|
TIeExamInvigilateCall tIeExamInvigilateCall = tIeExamInvigilateCallService.getOne(tIeExamInvigilateCallQueryWrapper);
|
|
TIeExamInvigilateCall tIeExamInvigilateCall = tIeExamInvigilateCallService.getOne(tIeExamInvigilateCallQueryWrapper);
|
|
|
|
+ if (Objects.isNull(tIeExamInvigilateCall)) {
|
|
|
|
+ throw new BusinessException("监控通话信息为空");
|
|
|
|
+ }
|
|
tIeExamInvigilateCall.setStatus("apply");
|
|
tIeExamInvigilateCall.setStatus("apply");
|
|
- tIeExamInvigilateCall.setCreateId(tbUser.getId());
|
|
|
|
tIeExamInvigilateCallService.updateById(tIeExamInvigilateCall);
|
|
tIeExamInvigilateCallService.updateById(tIeExamInvigilateCall);
|
|
return ResultUtil.ok(SystemConstant.SUCCESS);
|
|
return ResultUtil.ok(SystemConstant.SUCCESS);
|
|
}
|
|
}
|
|
@@ -100,13 +99,14 @@ public class TIeInvigilateCallController {
|
|
if (Objects.isNull(mapParameter.get("recordId")) || Objects.equals(mapParameter.get("recordId"), "")) {
|
|
if (Objects.isNull(mapParameter.get("recordId")) || Objects.equals(mapParameter.get("recordId"), "")) {
|
|
throw new BusinessException(ExceptionResultEnum.RECORD_ID_IS_NULL);
|
|
throw new BusinessException(ExceptionResultEnum.RECORD_ID_IS_NULL);
|
|
}
|
|
}
|
|
- TBUser tbUser = (TBUser) ServletUtil.getRequestAccount();
|
|
|
|
Long recordId = Long.parseLong(String.valueOf(mapParameter.get("recordId")));
|
|
Long recordId = Long.parseLong(String.valueOf(mapParameter.get("recordId")));
|
|
QueryWrapper<TIeExamInvigilateCall> tIeExamInvigilateCallQueryWrapper = new QueryWrapper<>();
|
|
QueryWrapper<TIeExamInvigilateCall> tIeExamInvigilateCallQueryWrapper = new QueryWrapper<>();
|
|
tIeExamInvigilateCallQueryWrapper.lambda().eq(TIeExamInvigilateCall::getExamRecordId, recordId);
|
|
tIeExamInvigilateCallQueryWrapper.lambda().eq(TIeExamInvigilateCall::getExamRecordId, recordId);
|
|
TIeExamInvigilateCall tIeExamInvigilateCall = tIeExamInvigilateCallService.getOne(tIeExamInvigilateCallQueryWrapper);
|
|
TIeExamInvigilateCall tIeExamInvigilateCall = tIeExamInvigilateCallService.getOne(tIeExamInvigilateCallQueryWrapper);
|
|
|
|
+ if (Objects.isNull(tIeExamInvigilateCall)) {
|
|
|
|
+ throw new BusinessException("监控通话信息为空");
|
|
|
|
+ }
|
|
tIeExamInvigilateCall.setStatus("cancel");
|
|
tIeExamInvigilateCall.setStatus("cancel");
|
|
- tIeExamInvigilateCall.setUpdateId(tbUser.getId());
|
|
|
|
tIeExamInvigilateCallService.updateById(tIeExamInvigilateCall);
|
|
tIeExamInvigilateCallService.updateById(tIeExamInvigilateCall);
|
|
return ResultUtil.ok(SystemConstant.SUCCESS);
|
|
return ResultUtil.ok(SystemConstant.SUCCESS);
|
|
}
|
|
}
|