修复考试申请取消申请后无法再次提交的问题
This commit is contained in:
parent
43b158e7b8
commit
204dfc11b7
@ -220,4 +220,6 @@ public interface IClassPlanDao {
|
|||||||
List<Map<String, Object>> listSendDepartment(Map<String, Object> params);
|
List<Map<String, Object>> listSendDepartment(Map<String, Object> params);
|
||||||
|
|
||||||
List<Map<String, Object>> listSendClassPlan(Map<String, Object> query);
|
List<Map<String, Object>> listSendClassPlan(Map<String, Object> query);
|
||||||
|
|
||||||
|
void removeExamFile(String classPlanId);
|
||||||
}
|
}
|
@ -603,10 +603,10 @@ public class ClassPlanServiceImpl extends DefaultBaseService implements IClassPl
|
|||||||
/**
|
/**
|
||||||
* CBC 准考证生成基础信息关联 2021年6月19日16:29:30加入代码
|
* CBC 准考证生成基础信息关联 2021年6月19日16:29:30加入代码
|
||||||
*/
|
*/
|
||||||
DistributionSaveVO saveData = new DistributionSaveVO();
|
/*DistributionSaveVO saveData = new DistributionSaveVO();
|
||||||
saveData.setPlanId(classPlanId);
|
saveData.setPlanId(classPlanId);
|
||||||
saveData.setPlanName(classPlanDTO.getPlanName());
|
saveData.setPlanName(classPlanDTO.getPlanName());
|
||||||
iDistributionService.save(saveData);
|
iDistributionService.save(saveData);*/
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -1028,6 +1028,8 @@ public class ClassPlanServiceImpl extends DefaultBaseService implements IClassPl
|
|||||||
String classPlanId = params.get("classPlanId").toString();
|
String classPlanId = params.get("classPlanId").toString();
|
||||||
params.put("planId", classPlanId);
|
params.put("planId", classPlanId);
|
||||||
classPlanDao.removeCancelPlanExam(params);
|
classPlanDao.removeCancelPlanExam(params);
|
||||||
|
// 取消后删除之前申请上传的文件信息
|
||||||
|
classPlanDao.removeExamFile(classPlanId);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -1070,7 +1072,6 @@ public class ClassPlanServiceImpl extends DefaultBaseService implements IClassPl
|
|||||||
historyMap.put("checkTime",DateUtil.getTime());
|
historyMap.put("checkTime",DateUtil.getTime());
|
||||||
setSaveInfo(historyMap);
|
setSaveInfo(historyMap);
|
||||||
classPlanDao.saveExamPlanHistory(historyMap);
|
classPlanDao.saveExamPlanHistory(historyMap);
|
||||||
System.out.println(params);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -539,6 +539,12 @@
|
|||||||
limit 1
|
limit 1
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
<insert id="removeExamFile" parameterType="string">
|
||||||
|
DELETE FROM e_class_plan_exam_file
|
||||||
|
WHERE
|
||||||
|
class_plan_id = #{classPlanId}
|
||||||
|
</insert>
|
||||||
|
|
||||||
<update id="updateExamFile" parameterType="map">
|
<update id="updateExamFile" parameterType="map">
|
||||||
UPDATE e_class_plan_exam_file SET
|
UPDATE e_class_plan_exam_file SET
|
||||||
exam_images = #{examImages},
|
exam_images = #{examImages},
|
||||||
|
@ -272,6 +272,7 @@
|
|||||||
anim: 2,
|
anim: 2,
|
||||||
content: top.restAjax.path('route/classplan/update-exam-commit.html?classPlanId={classPlanId}', [obj.data.classPlanId]),
|
content: top.restAjax.path('route/classplan/update-exam-commit.html?classPlanId={classPlanId}', [obj.data.classPlanId]),
|
||||||
end: function () {
|
end: function () {
|
||||||
|
reloadTable();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -285,6 +286,7 @@
|
|||||||
anim: 2,
|
anim: 2,
|
||||||
content: top.restAjax.path('route/examination/distribution/show.html?planId={classPlanId}', [obj.data.classPlanId]),
|
content: top.restAjax.path('route/examination/distribution/show.html?planId={classPlanId}', [obj.data.classPlanId]),
|
||||||
end: function () {
|
end: function () {
|
||||||
|
reloadTable();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -39,7 +39,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-row">
|
<div class="layui-row">
|
||||||
<div class="layui-col-md3">
|
<div class="layui-col-md6">
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label"><span style="color: red">*</span>培训时间</label>
|
<label class="layui-form-label"><span style="color: red">*</span>培训时间</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
@ -47,7 +47,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-col-md3">
|
<div class="layui-col-md6">
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label"><span style="color: red">*</span>结培时间</label>
|
<label class="layui-form-label"><span style="color: red">*</span>结培时间</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
@ -57,7 +57,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-row">
|
<div class="layui-row">
|
||||||
<div class="layui-col-md3">
|
<div class="layui-col-md6">
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label"><span style="color: red">*</span>负责人</label>
|
<label class="layui-form-label"><span style="color: red">*</span>负责人</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
@ -66,7 +66,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-col-md3">
|
<div class="layui-col-md6">
|
||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label class="layui-form-label"><span style="color: red">*</span>联系方式</label>
|
<label class="layui-form-label"><span style="color: red">*</span>联系方式</label>
|
||||||
<div class="layui-input-block">
|
<div class="layui-input-block">
|
||||||
@ -86,36 +86,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-row">
|
<div class="layui-row">
|
||||||
<div class="layui-col-md6">
|
|
||||||
<div class="layui-form-item layui-form-text">
|
|
||||||
<label class="layui-form-label">上传考试申请图片</label>
|
|
||||||
<div class="layui-input-block">
|
|
||||||
<input type="hidden" id="examImages" name="examImages">
|
|
||||||
<div class="layui-btn-container" id="examImagesFileBox" style="border: 1px solid #e6e6e6;"></div>
|
|
||||||
<script id="examImagesFileDownload" type="text/html">
|
|
||||||
{{# var fileName = 'examImages'; }}
|
|
||||||
{{# if(d[fileName].length > 0) { }}
|
|
||||||
{{# var files = d[fileName];}}
|
|
||||||
{{# for(var i = 0, item = files[i]; item = files[i++];) { }}
|
|
||||||
<div class="upload-image-box">
|
|
||||||
<span class="upload-image-span">
|
|
||||||
<img src="route/file/download/false/{{item.fileId}}" align="加载失败">
|
|
||||||
</span>
|
|
||||||
<a class="layui-btn layui-btn-xs layui-btn-danger text-danger remove-image" href="javascript:void(0);" lay-form-button data-id="{{item.fileId}}" data-name="{{fileName}}" lay-filter="examImagesRemoveFile">
|
|
||||||
<i class="fa fa-trash-o"></i>
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
{{# } }}
|
|
||||||
{{# } }}
|
|
||||||
<div class="upload-image-box" style="width: auto; height: auto; padding: 5px;">
|
|
||||||
<a href="javascript:void(0);" lay-form-button data-explain="考试申请图片" data-name="examImages" lay-filter="examImagesUploadFile">
|
|
||||||
<i class="fa fa-plus-square-o" style="font-size: 70px;"></i>
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</script>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="layui-col-md6">
|
<div class="layui-col-md6">
|
||||||
<div class="layui-form-item layui-form-text">
|
<div class="layui-form-item layui-form-text">
|
||||||
<label class="layui-form-label">上传考试申请PDF</label>
|
<label class="layui-form-label">上传考试申请PDF</label>
|
||||||
@ -128,9 +98,9 @@
|
|||||||
{{# var files = d[fileName];}}
|
{{# var files = d[fileName];}}
|
||||||
{{# for(var i = 0, item = files[i]; item = files[i++];) { }}
|
{{# for(var i = 0, item = files[i]; item = files[i++];) { }}
|
||||||
<div class="upload-image-box">
|
<div class="upload-image-box">
|
||||||
<span class="upload-image-span">
|
<span class="upload-image-span">
|
||||||
<img src="assets/images/pdf_icon.jpg" title="{{item.fileName}}" data-id="{{item.fileId}}" align="加载失败" class="pdf-open-show">
|
<img src="assets/images/pdf_icon.jpg" title="{{item.fileName}}" data-id="{{item.fileId}}" align="加载失败" class="pdf-open-show">
|
||||||
</span>
|
</span>
|
||||||
<a class="layui-btn layui-btn-xs layui-btn-danger text-danger remove-image" href="javascript:void(0);" lay-form-button data-id="{{item.fileId}}" data-name="{{fileName}}" lay-filter="examPDFRemoveFile">
|
<a class="layui-btn layui-btn-xs layui-btn-danger text-danger remove-image" href="javascript:void(0);" lay-form-button data-id="{{item.fileId}}" data-name="{{fileName}}" lay-filter="examPDFRemoveFile">
|
||||||
<i class="fa fa-trash-o"></i>
|
<i class="fa fa-trash-o"></i>
|
||||||
</a>
|
</a>
|
||||||
@ -217,7 +187,6 @@
|
|||||||
var laytpl = layui.laytpl;
|
var laytpl = layui.laytpl;
|
||||||
var laydate = layui.laydate;
|
var laydate = layui.laydate;
|
||||||
var classPlanId = top.restAjax.params(window.location.href).classPlanId;
|
var classPlanId = top.restAjax.params(window.location.href).classPlanId;
|
||||||
var examImagesViewerObj = {};
|
|
||||||
|
|
||||||
// 初始化内容
|
// 初始化内容
|
||||||
function initData() {
|
function initData() {
|
||||||
@ -239,7 +208,6 @@
|
|||||||
initExamPlaceCheckbox(dataFormData['examPlace']);
|
initExamPlaceCheckbox(dataFormData['examPlace']);
|
||||||
$('.exam-place-div').show();
|
$('.exam-place-div').show();
|
||||||
}
|
}
|
||||||
initExamImagesUploadFile();
|
|
||||||
initExamPDFUploadFile();
|
initExamPDFUploadFile();
|
||||||
getPlanExamAuditHistory();
|
getPlanExamAuditHistory();
|
||||||
$('.layui-card').height($win.height());
|
$('.layui-card').height($win.height());
|
||||||
@ -283,59 +251,6 @@
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// 初始化图片上传
|
|
||||||
function initExamImagesUploadFile() {
|
|
||||||
var files = $('#examImages').val();
|
|
||||||
initFileList('examImages', files, function(fileName) {
|
|
||||||
var viewer = new Viewer(document.getElementById(fileName +'FileBox'), {navbar: false});
|
|
||||||
examImagesViewerObj[fileName] = viewer;
|
|
||||||
});
|
|
||||||
|
|
||||||
form.on('button(examImagesUploadFile)', function(obj) {
|
|
||||||
var name = this.dataset.name;
|
|
||||||
var explain = this.dataset.explain;
|
|
||||||
top.dialog.file({
|
|
||||||
type: 'image',
|
|
||||||
title: '上传'+ explain,
|
|
||||||
width: '400px',
|
|
||||||
height: '420px',
|
|
||||||
maxFileCount: '1',
|
|
||||||
onClose: function() {
|
|
||||||
var uploadFileArray = top.dialog.dialogData.uploadFileArray;
|
|
||||||
if(typeof(uploadFileArray) != 'undefined' && uploadFileArray.length > 0) {
|
|
||||||
var files = $('#'+ name).val();
|
|
||||||
for(var j = 0, file = uploadFileArray[j]; file = uploadFileArray[j++];) {
|
|
||||||
if(files.length > 0) {
|
|
||||||
files += ',';
|
|
||||||
}
|
|
||||||
files += file.data;
|
|
||||||
}
|
|
||||||
initFileList(name, files, function(fileName) {
|
|
||||||
examImagesViewerObj[fileName].update();
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
form.on('button(examImagesRemoveFile)', function(obj) {
|
|
||||||
var name = this.dataset.name;
|
|
||||||
var id = this.dataset.id;
|
|
||||||
var files = $('#'+ name).val().replace(id, '');
|
|
||||||
files = files.replace(/\,+/g, ',');
|
|
||||||
if(files.charAt(0) == ',') {
|
|
||||||
files = files.substring(1);
|
|
||||||
}
|
|
||||||
if(files.charAt(files.length - 1) == ',') {
|
|
||||||
files = files.substring(0, files.length - 1);
|
|
||||||
}
|
|
||||||
initFileList(name, files, function(fileName) {
|
|
||||||
examImagesViewerObj[fileName].update();
|
|
||||||
});
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 初始化PDF上传
|
// 初始化PDF上传
|
||||||
function initExamPDFUploadFile() {
|
function initExamPDFUploadFile() {
|
||||||
var files = $('#examPDF').val();
|
var files = $('#examPDF').val();
|
||||||
|
Loading…
Reference in New Issue
Block a user