Merge remote-tracking branch 'origin/master'

This commit is contained in:
Renpc-kilig 2021-05-12 15:12:41 +08:00
commit 78f4706313
3 changed files with 16 additions and 28 deletions

View File

@ -403,11 +403,19 @@ public class ClassPlanServiceImpl extends DefaultBaseService implements IClassPl
examApplyVO.setExamType(Integer.parseInt(classPlanVO.getExamType())); examApplyVO.setExamType(Integer.parseInt(classPlanVO.getExamType()));
examApplyVO.setTheoryExamStartTime(classPlanVO.getEstimateStart()); examApplyVO.setTheoryExamStartTime(classPlanVO.getEstimateStart());
examApplyVO.setTheoryExamEndTime(classPlanVO.getEstimateEnd()); examApplyVO.setTheoryExamEndTime(classPlanVO.getEstimateEnd());
examApplyVO.setCheckStatus(0);
examApplyVO.setUserStatus(0);
examApplyVO.setStatus(0);
examApplyVO.setReason("重新申请");
if("3".equals(classPlanVO.getExamType())){ if("3".equals(classPlanVO.getExamType())){
examApplyVO.setPracticeExamStartTime(classPlanVO.getEstimateStart()); examApplyVO.setPracticeExamStartTime(classPlanVO.getEstimateStart());
examApplyVO.setPracticeExamEndTime(classPlanVO.getEstimateEnd()); examApplyVO.setPracticeExamEndTime(classPlanVO.getEstimateEnd());
} }
examApplyService.save(examApplyVO); //先查询再修改
Map<String, Object> queryMap = getHashMap(8);
queryMap.put("examId",classPlanId);
ExamApplyDTO history = examApplyService.get(queryMap);
examApplyService.update(history.getExamApplyId(),examApplyVO);
} }
@Override @Override
@ -423,13 +431,13 @@ public class ClassPlanServiceImpl extends DefaultBaseService implements IClassPl
examDTO.setExamApplyId(examApplyDTO.getExamApplyId()); examDTO.setExamApplyId(examApplyDTO.getExamApplyId());
examDTO.setTheoryExamStartTime(examApplyDTO.getTheoryExamStartTime()); examDTO.setTheoryExamStartTime(examApplyDTO.getTheoryExamStartTime());
examDTO.setTheoryExamEndTime(examApplyDTO.getTheoryExamEndTime()); examDTO.setTheoryExamEndTime(examApplyDTO.getTheoryExamEndTime());
if(examApplyDTO.getCheckStatus() == 1){ if(examApplyDTO.getExamType() != 2 && examApplyDTO.getCheckStatus() == 1){
InstitutionDTO institutionDTO = iInstitutionService.get(examApplyDTO.getTheoryExamAddressId()); InstitutionDTO institutionDTO = iInstitutionService.get(examApplyDTO.getTheoryExamAddressId());
examDTO.setTheoryExamAddress(institutionDTO.getInstitutionName() + "-" + institutionDTO.getInstitutionAddress()); examDTO.setTheoryExamAddress(institutionDTO.getInstitutionName() + "-" + institutionDTO.getInstitutionAddress());
} }
examDTO.setPracticeExamStartTime(examApplyDTO.getPracticeExamStartTime()); examDTO.setPracticeExamStartTime(examApplyDTO.getPracticeExamStartTime());
examDTO.setPracticeExamEndTime(examApplyDTO.getPracticeExamEndTime()); examDTO.setPracticeExamEndTime(examApplyDTO.getPracticeExamEndTime());
if(examApplyDTO.getCheckStatus() == 2){ if(examApplyDTO.getExamType() != 1 && examApplyDTO.getCheckStatus() == 1){
InstitutionDTO institutionDTO = iInstitutionService.get(examApplyDTO.getPracticeExamAddressId()); InstitutionDTO institutionDTO = iInstitutionService.get(examApplyDTO.getPracticeExamAddressId());
examDTO.setPracticeExamAddress(institutionDTO.getInstitutionName() + "-" + institutionDTO.getInstitutionAddress()); examDTO.setPracticeExamAddress(institutionDTO.getInstitutionName() + "-" + institutionDTO.getInstitutionAddress());
} }

View File

@ -88,18 +88,8 @@
top.dialog.close(index); top.dialog.close(index);
var loadLayerIndex; var loadLayerIndex;
top.restAjax.put(top.restAjax.path('api/classplan/update-exam/{classPlanId}', [classPlanId]), formData.field, null, function(code, data) { top.restAjax.put(top.restAjax.path('api/classplan/update-exam/{classPlanId}', [classPlanId]), formData.field, null, function(code, data) {
var layerIndex = top.dialog.msg(top.dataMessage.commitSuccess, { top.dialog.msg("提交成功");
time: 0, closeBox();
btn: [top.dataMessage.button.yes, top.dataMessage.button.no],
shade: 0.3,
yes: function(index) {
top.dialog.close(index);
window.location.reload();
},
btn2: function() {
closeBox();
}
});
}, function(code, data) { }, function(code, data) {
top.dialog.msg(data.msg); top.dialog.msg(data.msg);
}, function() { }, function() {

View File

@ -43,7 +43,7 @@
<div class="layui-form-item layui-layout-admin" id="submit-div" style="display: none;"> <div class="layui-form-item layui-layout-admin" id="submit-div" style="display: none;">
<div class="layui-input-block"> <div class="layui-input-block">
<div class="layui-footer" style="left: 0;"> <div class="layui-footer" style="left: 0;">
<button type="button" class="layui-btn" lay-submit lay-filter="submitForm">提交申请</button> <button type="button" class="layui-btn" lay-submit lay-filter="submitForm">重新提交</button>
<button type="button" class="layui-btn layui-btn-primary close">返回上级</button> <button type="button" class="layui-btn layui-btn-primary close">返回上级</button>
</div> </div>
</div> </div>
@ -113,18 +113,8 @@
top.dialog.close(index); top.dialog.close(index);
var loadLayerIndex; var loadLayerIndex;
top.restAjax.put(top.restAjax.path('api/classplan/update-exam/{classPlanId}', [classPlanId]), formData.field, null, function(code, data) { top.restAjax.put(top.restAjax.path('api/classplan/update-exam/{classPlanId}', [classPlanId]), formData.field, null, function(code, data) {
var layerIndex = top.dialog.msg(top.dataMessage.commitSuccess, { top.dialog.msg("提交成功");
time: 0, closeBox();
btn: [top.dataMessage.button.yes, top.dataMessage.button.no],
shade: 0.3,
yes: function(index) {
top.dialog.close(index);
window.location.reload();
},
btn2: function() {
closeBox();
}
});
}, function(code, data) { }, function(code, data) {
top.dialog.msg(data.msg); top.dialog.msg(data.msg);
}, function() { }, function() {