考试申请审核功能修改。

This commit is contained in:
Renpc-kilig 2021-05-05 17:26:28 +08:00
parent f88f526861
commit f58efac12a
2 changed files with 18 additions and 10 deletions

View File

@ -113,6 +113,7 @@ public class ExamCheckServiceImpl extends DefaultBaseService implements IExamChe
if(2 == examCheckVO.getCheckStatus()) { if(2 == examCheckVO.getCheckStatus()) {
ExamApplyVO examApplyVO = new ExamApplyVO(); ExamApplyVO examApplyVO = new ExamApplyVO();
examApplyVO.setStatus(0); examApplyVO.setStatus(0);
examApplyVO.setUserStatus(0);
examApplyVO.setExamId(examCheckVO.getPlanId()); examApplyVO.setExamId(examCheckVO.getPlanId());
examApplyService.save(examApplyVO); examApplyService.save(examApplyVO);
} }

View File

@ -1,5 +1,6 @@
package cn.com.tenlion.service.examination.impl; package cn.com.tenlion.service.examination.impl;
import cn.com.tenlion.dao.examapply.IExamApplyDao;
import cn.com.tenlion.dao.examination.IExaminationDao; import cn.com.tenlion.dao.examination.IExaminationDao;
import cn.com.tenlion.pojo.bos.examination.ExaminationBO; import cn.com.tenlion.pojo.bos.examination.ExaminationBO;
import cn.com.tenlion.pojo.dtos.distribution.DistributionDTO; import cn.com.tenlion.pojo.dtos.distribution.DistributionDTO;
@ -11,7 +12,7 @@ import cn.com.tenlion.pojo.vos.distributionfield.DistributionFieldSaveVO;
import cn.com.tenlion.pojo.vos.examination.ExaminationVO; import cn.com.tenlion.pojo.vos.examination.ExaminationVO;
import cn.com.tenlion.service.examination.IExaminationService; import cn.com.tenlion.service.examination.IExaminationService;
import cn.com.tenlion.service.examination.distribution.IDistributionService; import cn.com.tenlion.service.examination.distribution.IDistributionService;
import cn.com.tenlion.service.examination.distributioncard.impl.DistributionCardServiceImpl; import cn.com.tenlion.service.examination.distributioncard.IDistributionCardService;
import cn.com.tenlion.service.examination.distributionfield.IDistributionFieldService; import cn.com.tenlion.service.examination.distributionfield.IDistributionFieldService;
import ink.wgink.common.base.DefaultBaseService; import ink.wgink.common.base.DefaultBaseService;
import ink.wgink.exceptions.SearchException; import ink.wgink.exceptions.SearchException;
@ -44,7 +45,9 @@ public class ExaminationServiceImpl extends DefaultBaseService implements IExami
@Autowired @Autowired
private IDistributionService distributionService; private IDistributionService distributionService;
@Autowired @Autowired
private DistributionCardServiceImpl distributionCardService; private IDistributionCardService distributionCardService;
@Autowired
private IExamApplyDao examApplyDao;
@Override @Override
public void save(ExaminationVO examinationVO) { public void save(ExaminationVO examinationVO) {
@ -292,10 +295,7 @@ public class ExaminationServiceImpl extends DefaultBaseService implements IExami
params.put("examinationId", examinationDTO.getExaminationId()); params.put("examinationId", examinationDTO.getExaminationId());
setUpdateInfo(params); setUpdateInfo(params);
examinationDao.updateExamHis(params); examinationDao.updateExamHis(params);
DistributionFieldSaveVO distributionFieldSaveVO = new DistributionFieldSaveVO(); updateDistributionField(params, examinationDTO, distributionFieldDTO);
distributionFieldSaveVO.setInvigilatorId(examinationDTO.getExaminationId());
distributionFieldService.update(distributionFieldDTO.getDistributionFieldId(), distributionFieldSaveVO);
distributionCardService.saveBuildingPictures(params.get("examId").toString(), params.get("examId").toString());
return examinationDTO; return examinationDTO;
} }
} }
@ -312,12 +312,19 @@ public class ExaminationServiceImpl extends DefaultBaseService implements IExami
params.put("examinationId", examinationDTO.getExaminationId()); params.put("examinationId", examinationDTO.getExaminationId());
setSaveInfo(params); setSaveInfo(params);
examinationDao.saveExamHis(params); examinationDao.saveExamHis(params);
DistributionFieldSaveVO distributionFieldSaveVO = new DistributionFieldSaveVO(); // 修改监考老师分配状态
distributionFieldSaveVO.setInvigilatorId(examinationDTO.getExaminationId()); params.put("userStatus", "1");
distributionFieldService.update(distributionFieldDTO.getDistributionFieldId(), distributionFieldSaveVO); examApplyDao.update(params);
distributionCardService.saveBuildingPictures(params.get("examId").toString(), params.get("examId").toString()); updateDistributionField(params, examinationDTO, distributionFieldDTO);
return examinationDTO; return examinationDTO;
} }
} }
private void updateDistributionField(Map<String, Object> params, ExaminationDTO examinationDTO, DistributionFieldDTO distributionFieldDTO) throws Exception {
DistributionFieldSaveVO distributionFieldSaveVO = new DistributionFieldSaveVO();
distributionFieldSaveVO.setInvigilatorId(examinationDTO.getExaminationId());
distributionFieldService.update(distributionFieldDTO.getDistributionFieldId(), distributionFieldSaveVO);
distributionCardService.saveBuildingPictures(params.get("examId").toString(), params.get("examId").toString());
}
} }