2024-04-08 15:56 체험교실 상태값 변경 요청 적용
This commit is contained in:
parent
0e409196b3
commit
f46b4bab32
@ -222,72 +222,82 @@ public class ExprnClsrmAplctServiceImpl implements ExprnClsrmAplctService {
|
||||
veEduOprtnService.update(oprtn);
|
||||
|
||||
//저작권 체험교실 서류제출 시 차시별 운영계획서 제출
|
||||
if("30".equals(vEEduAplctVO.getLctrDivCd()) && ("50".equals(vEEduAplctVO.getAprvlCd()) || "60".equals(vEEduAplctVO.getAprvlCd()))) {
|
||||
if("30".equals(vEEduAplctVO.getLctrDivCd())
|
||||
&& ("50".equals(vEEduAplctVO.getAprvlCd())
|
||||
|| "60".equals(vEEduAplctVO.getAprvlCd())
|
||||
|| "40".equals(vEEduAplctVO.getAprvlCd())
|
||||
)) {
|
||||
|
||||
VEEduChasiVO vEEduChasiVO = new VEEduChasiVO();
|
||||
vEEduChasiVO.setEduAplctOrd(vEEduAplctVO.getEduAplctOrd()); //교육신청순번
|
||||
vEEduChasiVO.setFrstRegisterId(loginVO.getUniqId()); //esntl_id
|
||||
//기존 차시 삭제
|
||||
vVEEduChasiDAO.delete(vEEduChasiVO);
|
||||
try {
|
||||
VEEduChasiVO vEEduChasiVO = new VEEduChasiVO();
|
||||
vEEduChasiVO.setEduAplctOrd(vEEduAplctVO.getEduAplctOrd()); //교육신청순번
|
||||
vEEduChasiVO.setFrstRegisterId(loginVO.getUniqId()); //esntl_id
|
||||
//기존 차시 삭제
|
||||
vVEEduChasiDAO.delete(vEEduChasiVO);
|
||||
|
||||
//차시 저장
|
||||
String[] s_eduHopeDt = request.getParameterValues("eduHopeDt");
|
||||
String[] s_strtTm = request.getParameterValues("strtTm");
|
||||
String[] s_endTm = request.getParameterValues("endTm");
|
||||
String[] s_lrnTm = request.getParameterValues("lrnTm");
|
||||
String[] s_lrnSbjct = request.getParameterValues("lrnSbjct");
|
||||
String[] s_lrnCn = request.getParameterValues("lrnCn");
|
||||
String[] s_rmrks = request.getParameterValues("rmrks");
|
||||
|
||||
|
||||
for (int i=0;i<s_eduHopeDt.length;i++) {
|
||||
String eduChasiOrd = eduChasiGnrService.getNextStringId(); // 교육차시 순번
|
||||
vEEduChasiVO.setEduChasiOrd(eduChasiOrd);
|
||||
//vEEduChasiVO.setEduHopeDt(s_eduHopeDt[i].replaceAll("[^0-9]",""));
|
||||
vEEduChasiVO.setEduHopeDt(s_eduHopeDt[i]);
|
||||
|
||||
try {
|
||||
vEEduChasiVO.setStrtTm(s_strtTm[i].replaceAll("[^0-9]",""));
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
try {
|
||||
vEEduChasiVO.setEndTm(s_endTm[i].replaceAll("[^0-9]",""));
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
try {
|
||||
vEEduChasiVO.setLrnTm(s_lrnTm[i]);
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
|
||||
vEEduChasiVO.setLrnSbjct(s_lrnSbjct[i]);
|
||||
vEEduChasiVO.setLrnCn(s_lrnCn[i]);
|
||||
vEEduChasiVO.setRmrks(s_rmrks[i]);
|
||||
vVEEduChasiDAO.insert(vEEduChasiVO);
|
||||
|
||||
if(
|
||||
"50".equals(vEEduAplctVO.getAprvlCd()) //서류제출
|
||||
){
|
||||
try {
|
||||
iTNotiUtil.insertNotifyNew(
|
||||
vEEduAplctVO.getLctrDivCd(),
|
||||
loginVO.getUniqId(),
|
||||
VeConstants.NOTI_STATUS_50,
|
||||
vEEduAplctVO.getEduAplctOrd(),
|
||||
vEEduAplctVO.getEduChasiOrd(),
|
||||
"1",
|
||||
"1"
|
||||
);
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
//차시 저장
|
||||
String[] s_eduHopeDt = request.getParameterValues("eduHopeDt");
|
||||
String[] s_strtTm = request.getParameterValues("strtTm");
|
||||
String[] s_endTm = request.getParameterValues("endTm");
|
||||
String[] s_lrnTm = request.getParameterValues("lrnTm");
|
||||
String[] s_lrnSbjct = request.getParameterValues("lrnSbjct");
|
||||
String[] s_lrnCn = request.getParameterValues("lrnCn");
|
||||
String[] s_rmrks = request.getParameterValues("rmrks");
|
||||
|
||||
|
||||
for (int i=0;i<s_eduHopeDt.length;i++) {
|
||||
String eduChasiOrd = eduChasiGnrService.getNextStringId(); // 교육차시 순번
|
||||
vEEduChasiVO.setEduChasiOrd(eduChasiOrd);
|
||||
//vEEduChasiVO.setEduHopeDt(s_eduHopeDt[i].replaceAll("[^0-9]",""));
|
||||
vEEduChasiVO.setEduHopeDt(s_eduHopeDt[i]);
|
||||
|
||||
try {
|
||||
vEEduChasiVO.setStrtTm(s_strtTm[i].replaceAll("[^0-9]",""));
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
try {
|
||||
vEEduChasiVO.setEndTm(s_endTm[i].replaceAll("[^0-9]",""));
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
try {
|
||||
vEEduChasiVO.setLrnTm(s_lrnTm[i]);
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
|
||||
|
||||
vEEduChasiVO.setLrnSbjct(s_lrnSbjct[i]);
|
||||
vEEduChasiVO.setLrnCn(s_lrnCn[i]);
|
||||
vEEduChasiVO.setRmrks(s_rmrks[i]);
|
||||
vVEEduChasiDAO.insert(vEEduChasiVO);
|
||||
|
||||
if(
|
||||
"50".equals(vEEduAplctVO.getAprvlCd()) //서류제출
|
||||
){
|
||||
try {
|
||||
iTNotiUtil.insertNotifyNew(
|
||||
vEEduAplctVO.getLctrDivCd(),
|
||||
loginVO.getUniqId(),
|
||||
VeConstants.NOTI_STATUS_50,
|
||||
vEEduAplctVO.getEduAplctOrd(),
|
||||
vEEduAplctVO.getEduChasiOrd(),
|
||||
"1",
|
||||
"1"
|
||||
);
|
||||
}catch(Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}else if("30".equals(vEEduAplctVO.getLctrDivCd())
|
||||
&& "13".equals(vEEduAplctVO.getAprvlCd())
|
||||
|
||||
@ -239,6 +239,51 @@
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
//임시저장-상태값 변경만 없음
|
||||
function fncTmprrSave(){
|
||||
|
||||
if (!validCheck()) return;
|
||||
url = '${pageContext.request.contextPath}/web/ve/aplct/cpyrgExprnClsrm/exprnClsrmInfo/exprnClsrmAplctMdfyAjax.do';
|
||||
|
||||
if(confirm("임시저장합니까?")){
|
||||
$("#aprvlCd").val('40');
|
||||
|
||||
$('input[name="scholDivCd"]').val(""); /* 차시 최소시간 체크를 제외하기 위한 임시 scholDivCd를 update 처리에서 제외하기 위함 */
|
||||
|
||||
/* if($('input[name=oprtnStrtDt]').val() != null){
|
||||
$('input[name=oprtnStrtDt]').val($('input[name=oprtnStrtDt]').val().replace(/[.]/gi, ''));
|
||||
}
|
||||
if($('input[name=oprtnEndDt]').val() != null){
|
||||
$('input[name=oprtnEndDt]').val($('input[name=oprtnEndDt]').val().replace(/[.]/gi, ''));
|
||||
} */
|
||||
|
||||
|
||||
var data = new FormData(document.getElementById("createForm"));
|
||||
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
enctype: 'multipart/form-data',
|
||||
url: url,
|
||||
data: data,
|
||||
dataType:'json',
|
||||
async: false,
|
||||
processData: false,
|
||||
contentType: false,
|
||||
cache: false,
|
||||
success: function (returnData, status) {
|
||||
$("#eduAplctOrd").val(returnData.VO.eduAplctOrd);
|
||||
if(status == 'success'){
|
||||
alert("저장 되었습니다.");
|
||||
location.reload();
|
||||
} else if(status== 'fail'){
|
||||
alert("저장에 실패하였습니다.");
|
||||
}
|
||||
},
|
||||
error: function (e) { alert("저장에 실패하였습니다."); console.log("ERROR : ", e); }
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
function validCheck(){
|
||||
|
||||
@ -1124,6 +1169,10 @@
|
||||
|
||||
</div>
|
||||
<div class="btn_center">
|
||||
<c:if test="${info.aprvlCd eq VeConstants.EXPRN_APRVL_CD_40}">
|
||||
<button type="button" class="btnType06" onclick="fncTmprrSave();">임시저장</button>
|
||||
</c:if>
|
||||
|
||||
</div>
|
||||
<div class="btn_right">
|
||||
<%-- <button type="button" class="btnType05" onclick="location.href='<c:url value="/web/ve/aplct/cpyrgExprnClsrm/exprnClsrmEnd/exprnClsrmEndList.do"/>'">운영 목록으로 이동</button> --%>
|
||||
|
||||
@ -310,7 +310,13 @@
|
||||
|
||||
if(fn_innorixCmmAjax(sendData, url) == "OK")
|
||||
{
|
||||
fncStatusChange('60');
|
||||
if (document.getElementById('aprvlCd').value=='230'){
|
||||
fncStatusChange('50');
|
||||
}else{
|
||||
fncStatusChange('60');
|
||||
}
|
||||
//alert(document.getElementById('aprvlCd').value);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user