2024-02-16 19:45 기소유예 중복 등록 수정
This commit is contained in:
parent
8a0334242d
commit
9795cc92b2
@ -495,7 +495,27 @@ public class CndtnTrgtMngController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 조건부기소유예대상자 중복확인 화면
|
||||
* 조건부기소유예대상자 중복확인 화면-등록관리
|
||||
*/
|
||||
//@RequestMapping("trgtDplctChk.do")
|
||||
@RequestMapping("/kccadr/oprtn/cndtnSspnIdtmt/trgtMngDplctChk.do")
|
||||
public String trgtMngDplctChk(
|
||||
@ModelAttribute("cndtnTrgtInfoMngVO") CndtnTrgtMngVO cndtnTrgtInfoMngVO
|
||||
, ModelMap model
|
||||
, HttpServletRequest request
|
||||
) throws Exception {
|
||||
|
||||
//로그인 처리====================================
|
||||
//로그인 정보 가져오기
|
||||
String s_oprtnLoginCheckNInfo = checkLoginUtil.oprtnCheckNInfo(model);
|
||||
if (!"".equals(s_oprtnLoginCheckNInfo)) return s_oprtnLoginCheckNInfo;
|
||||
|
||||
//로그인 처리====================================
|
||||
return "oprtn/cndtnSspnIdtmt/trgtMngDplctChk";
|
||||
}
|
||||
|
||||
/**
|
||||
* 조건부기소유예대상자 중복확인 화면-대상자관리
|
||||
*/
|
||||
//@RequestMapping("trgtDplctChk.do")
|
||||
@RequestMapping("/kccadr/oprtn/cndtnSspnIdtmt/trgtDplctChk.do")
|
||||
@ -553,6 +573,14 @@ public class CndtnTrgtMngController {
|
||||
model.addAttribute("CmmnDetailCodeList", uniqueCodes);
|
||||
|
||||
|
||||
//병합대상자 정보
|
||||
CndtnTrgtMngVO cndtnTrgtInfoVO = new CndtnTrgtMngVO();
|
||||
cndtnTrgtInfoVO.setSspnIdtmtTrgtOrd(cndtnTrgtInfoMngVO.getPrcsAplctPrdOrdCmplt());
|
||||
cndtnTrgtInfoVO = cndtnTrgtInfoMngService.selectDetail(cndtnTrgtInfoVO);
|
||||
|
||||
model.addAttribute("mergeInfo", cndtnTrgtInfoVO);
|
||||
|
||||
|
||||
return "oprtn/cndtnSspnIdtmt/trgtReg";
|
||||
}
|
||||
|
||||
|
||||
@ -108,7 +108,7 @@
|
||||
, #prsctrNm#
|
||||
, #reqStateCd#
|
||||
, #atchFileId#
|
||||
, ''
|
||||
, #prcsAplctPrdOrdCmplt#
|
||||
, ''
|
||||
, #rmrks#
|
||||
)
|
||||
|
||||
@ -229,10 +229,10 @@
|
||||
<div class="btn_left">
|
||||
</div>
|
||||
<div class="btn_center">
|
||||
<button type="button" class="btn_type04" id="duplInsert" onclick="fncCreateWithDupl(); return false;">병합처리</button>
|
||||
<button type="button" class="btn_type04" id="newInsert" onclick="fncCreate(); return false;">신규등록</button>
|
||||
</div>
|
||||
<div class="btn_right">
|
||||
<button type="button" class="btn_type02" id="duplInsert" onclick="fncCreateWithDupl(); return false;">병합처리</button>
|
||||
<button type="button" class="btn_type02" id="newInsert" onclick="fncCreate(); return false;">신규등록</button>
|
||||
<button type="button" class="btn_type02" id="duplChk" onclick="fn_duplChk(); return false;">중복확인</button>
|
||||
<button type="button" class="btn_type03" onclick="fncGoList(); return false;">목록</button>
|
||||
</div>
|
||||
|
||||
@ -0,0 +1,246 @@
|
||||
<!DOCTYPE html>
|
||||
<%@ page language="java" contentType="text/html; charset=utf-8"
|
||||
pageEncoding="utf-8"%>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
<%@ taglib prefix="ui" uri="http://egovframework.gov/ctl/ui"%>
|
||||
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
|
||||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
|
||||
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
|
||||
<%@ taglib prefix="ve" uri="/WEB-INF/tlds/kcc_tld.tld"%>
|
||||
<%@ taglib prefix="validator" uri="http://www.springmodules.org/tags/commons-validator" %>
|
||||
<%
|
||||
/**
|
||||
* @Class Name : cndtnEduPrcsMngReg.jsp
|
||||
* @Description : 조건부기소유예 과정 등록
|
||||
* @Modification Information
|
||||
* @
|
||||
* @ 수정일 수정자 수정내용
|
||||
* @ ------- -------- ---------------------------
|
||||
* @ 2021.12.16 조용준 최초 생성
|
||||
* @author 조용주
|
||||
* @since 2021.12.16
|
||||
* @version 1.0
|
||||
* @see
|
||||
*
|
||||
*/
|
||||
%>
|
||||
<html lang="ko">
|
||||
<head>
|
||||
<title>교육과정관리</title>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
||||
<script type="text/javascript">
|
||||
//세부과정 추가 버튼 클릭 시 세부과정 추가
|
||||
$(document).ready(function() {
|
||||
$("#duplInsert").hide();
|
||||
$("#newInsert").hide();
|
||||
});
|
||||
|
||||
// 중복 대상자가 있는지 확인
|
||||
function fn_duplChk(){
|
||||
|
||||
if(fn_valChk())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
var data = new FormData(document.getElementById("createForm"));
|
||||
|
||||
// if(confirm("저장하시겠습니까?")){
|
||||
var url = "${pageContext.request.contextPath}/kccadr/oprtn/cndtnSspnIdtmt/duplChkAjax.do";
|
||||
console.log(data);
|
||||
$.ajax({
|
||||
type:"POST",
|
||||
enctype: 'multipart/form-data',
|
||||
url: url,
|
||||
data: data,
|
||||
dataType:'json',
|
||||
async: false,
|
||||
processData: false,
|
||||
contentType: false,
|
||||
cache: false,
|
||||
success:function(returnData){
|
||||
console.log('returnData :: ', returnData);
|
||||
if(returnData.result == "success"){
|
||||
if(returnData.trgtDuplSize == 0){
|
||||
alert("중복 대상자가 없습니다.");
|
||||
fncCreate();
|
||||
}else{
|
||||
alert("중복 대상자가 있습니다.");
|
||||
var sendData = $(document.createForm).serializeArray() ;
|
||||
$("#loadDiv").load("<c:url value='/kccadr/oprtn/cndtnSspnIdtmt/popup/duplChkTable.do' />", sendData ,function(response, status, xhr){
|
||||
$("#duplInsert").show();
|
||||
$("#newInsert").show();
|
||||
|
||||
});
|
||||
|
||||
}
|
||||
//
|
||||
}else if(returnData.result == "fail"){
|
||||
alert(returnData.message);
|
||||
fncGoList();
|
||||
}
|
||||
},
|
||||
error:function(request , status, error){
|
||||
alert("code:"+request.status+"\n"+"message:"+request.responseText+"\n"+"error:"+error);
|
||||
}
|
||||
});
|
||||
// }
|
||||
|
||||
}
|
||||
|
||||
|
||||
function fncCreate() {
|
||||
var createForm = document.createForm ;
|
||||
createForm.action = "<c:url value='/kccadr/oprtn/cndtnSspnIdtmt/trgtReg.do'/>";
|
||||
createForm.submit();
|
||||
}
|
||||
|
||||
|
||||
function fncCreateWithDupl() {
|
||||
var chkVal = $('input[name=chk]:checked').val();
|
||||
if(chkVal == null || chkVal ==''){
|
||||
alert("병합 대상을 선택해주세요.");
|
||||
return false;
|
||||
}
|
||||
|
||||
var createForm = document.createForm ;
|
||||
createForm.prcsAplctPrdOrdCmplt.value = chkVal;
|
||||
createForm.action = "<c:url value='/kccadr/oprtn/cndtnSspnIdtmt/trgtReg.do'/>";
|
||||
createForm.submit();
|
||||
}
|
||||
|
||||
|
||||
function fn_valChk(){
|
||||
|
||||
if($("#sex").val() == "선택" || $("#sex").val().trim() == ""){
|
||||
alert("성별을 선택해주세요.");
|
||||
$("#sex").focus();
|
||||
return true;
|
||||
}
|
||||
|
||||
// 성명 검사
|
||||
if($("input[name='trgtNm']").val().trim() == ""){
|
||||
alert("성명을 입력해주세요.");
|
||||
$("input[name='trgtNm']").focus();
|
||||
return true;
|
||||
}
|
||||
|
||||
// 생년월일 검사
|
||||
if($("#DBirth").val().trim() == ""){
|
||||
alert("생년월일을 입력해주세요.");
|
||||
$("#DBirth").focus();
|
||||
return true;
|
||||
}
|
||||
|
||||
return false; // 모든 검사를 통과하면 false 반환
|
||||
|
||||
|
||||
}
|
||||
|
||||
function fncGoList(){
|
||||
var listForm = document.listForm ;
|
||||
listForm.action = "<c:url value='/kccadr/oprtn/cndtnSspnIdtmt/trgtList.do'/>";
|
||||
listForm.submit();
|
||||
}
|
||||
|
||||
</script>
|
||||
|
||||
</head>
|
||||
<body>
|
||||
<form:form id="listForm" name="listForm" commandName="vEPrcsDetailVO" method="post">
|
||||
</form:form>
|
||||
<form:form id="createForm" name="createForm" commandName="adjustDeptManageVO" method="post">
|
||||
<input type="hidden" name="sspnIdtmtTrgtOrd" id="sspnIdtmtTrgtOrd" value="" />
|
||||
<input type="hidden" name="prcsAplctPrdOrdCmplt" id="prcsAplctPrdOrdCmplt" value="" />
|
||||
<input type="hidden" name="cmptntAthrtNm" id="cmptntAthrtNm" value="" />
|
||||
|
||||
|
||||
<!-- cont -->
|
||||
<div class="cont_wrap">
|
||||
<div class="box">
|
||||
|
||||
<!-- cont_tit -->
|
||||
<div class="cont_tit">
|
||||
<h2>대상자 중복확인</h2>
|
||||
<ul class="cont_nav">
|
||||
<li class="home"><a href="/"><i></i></a></li>
|
||||
<li>
|
||||
<p>조건부기소유예관리</p>
|
||||
</li>
|
||||
<li><span class="cur_nav">대상자 목록</span></li>
|
||||
<li><span class="cur_nav">대상자 중복확인</span></li>
|
||||
</ul>
|
||||
</div>
|
||||
<!-- //cont_tit -->
|
||||
|
||||
<div class="cont">
|
||||
<!-- list_상세 -->
|
||||
<div class="tb_type02">
|
||||
<table>
|
||||
<colgroup>
|
||||
<col style="width: 210px;">
|
||||
<col style="width: auto;">
|
||||
<col style="width: 210px;">
|
||||
<col style="width: auto;">
|
||||
</colgroup>
|
||||
|
||||
<tbody>
|
||||
<tr>
|
||||
<th scope="row">
|
||||
<p class="req_text"><span>필수입력 항목</span>*</p>
|
||||
<p>성별</p>
|
||||
</th>
|
||||
<td>
|
||||
<ve:select codeId="COM014" name="sex" id="sex" css="class='sel_type1'"
|
||||
selectedText="" defaultValue=""
|
||||
defaultText='선택'
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">
|
||||
<p class="req_text"><span>필수입력 항목</span>*</p>
|
||||
<p>성명</p>
|
||||
</th>
|
||||
<td>
|
||||
<input type="text" name="trgtNm" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th scope="row">
|
||||
<p class="req_text"><span>필수입력 항목</span>*</p>
|
||||
<p>생년월일</p>
|
||||
</th>
|
||||
<td>
|
||||
<input type="text" name="DBirth" id="DBirth" placeholder="00000000" maxlength="8"/>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<!-- //list_상세 -->
|
||||
|
||||
<!-- 대상자 중복 테이블 -->
|
||||
<div id="loadDiv">
|
||||
</div>
|
||||
|
||||
<!-- btn_wrap -->
|
||||
<div class="btn_wrap btn_layout01">
|
||||
<div class="btn_left">
|
||||
</div>
|
||||
<div class="btn_center">
|
||||
<button type="button" class="btn_type04" id="duplInsert" onclick="fncCreateWithDupl(); return false;">병합처리</button>
|
||||
<button type="button" class="btn_type04" id="newInsert" onclick="fncCreate(); return false;">신규등록</button>
|
||||
</div>
|
||||
<div class="btn_right">
|
||||
<button type="button" class="btn_type02" id="duplChk" onclick="fn_duplChk(); return false;">중복확인</button>
|
||||
<button type="button" class="btn_type03" onclick="fncGoList(); return false;">목록</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form:form>
|
||||
<!-- //cont -->
|
||||
</body>
|
||||
</html>
|
||||
@ -150,7 +150,8 @@
|
||||
|
||||
function fncCreate() {
|
||||
var listForm = document.listForm ;
|
||||
listForm.action = "<c:url value='/kccadr/oprtn/cndtnSspnIdtmt/trgtReg.do'/>";
|
||||
//listForm.action = "<c:url value='/kccadr/oprtn/cndtnSspnIdtmt/trgtReg.do'/>";
|
||||
listForm.action = "<c:url value='/kccadr/oprtn/cndtnSspnIdtmt/trgtDplctChk.do'/>";
|
||||
listForm.submit();
|
||||
}
|
||||
|
||||
|
||||
@ -88,10 +88,11 @@
|
||||
console.log('returnData :: ', returnData);
|
||||
if(returnData.result == "success"){
|
||||
alert("저장되었습니다.");
|
||||
// fncGoList();
|
||||
$('#sspnIdtmtTrgtOrd').val(returnData.sspnIdtmtTrgtOrd);
|
||||
// 중복체크 ajax
|
||||
fn_duplChk();
|
||||
fncGoList();
|
||||
|
||||
// 중복체크 ajax - 사전 중복체크로 변경되어 주석처리함.2024-02-16
|
||||
//$('#sspnIdtmtTrgtOrd').val(returnData.sspnIdtmtTrgtOrd);
|
||||
//fn_duplChk();
|
||||
}else if(returnData.result == "fail"){
|
||||
alert(returnData.message);
|
||||
$('#cmptntAthrt').prop('disabled', true);
|
||||
@ -201,6 +202,7 @@
|
||||
|
||||
|
||||
function fn_valChk(){
|
||||
|
||||
// 의뢰일 검사
|
||||
if($("#reqPnttm").val().trim() == ""){
|
||||
alert("의뢰일을 입력해주세요.");
|
||||
@ -229,6 +231,8 @@
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
if($("#sex").val() == "선택" || $("#sex").val().trim() == ""){
|
||||
alert("성별을 선택해주세요.");
|
||||
$("#sex").focus();
|
||||
@ -293,7 +297,7 @@
|
||||
|
||||
if($('#tbody_fiielist tr').length*1<=0){
|
||||
alert("으뢰통지서를 등록해 주세요");
|
||||
return false;
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
@ -399,6 +403,8 @@
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
<tr>
|
||||
<th scope="row">
|
||||
<p class="req_text"><span>필수입력 항목</span>*</p>
|
||||
@ -407,6 +413,44 @@
|
||||
<td>
|
||||
<input type="text" name="vntYear" style="width: 150px;margin-right: 10px;"/>형제
|
||||
<input type="text" name="vntNmbr" style="width: 150px;margin-left: 10px;" />
|
||||
<c:if test="${not empty mergeInfo}">
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
<button class="btnType01 btn_type08" onclick="fn_merge(true); return false;">교육의뢰병합</button>
|
||||
<button class="btnType01 btn_type08" onclick="fn_merge(false); return false;">교육의뢰병합취소</button>
|
||||
<br/>
|
||||
|
||||
<input type="text" name="dp_vnt" style="width: 250px;margin-left: 0px;"
|
||||
value="${mergeInfo.vntYear}형제${mergeInfo.vntNmbr}"
|
||||
readonly/>
|
||||
<input type="text" name="dp_reqNmbr" style="width: 250px;margin-left: 10px;"
|
||||
value="${mergeInfo.reqNmbr}"
|
||||
readonly/>
|
||||
<input type="hidden" name="prcsAplctPrdOrdCmplt" value="${mergeInfo.sspnIdtmtTrgtOrd}"/>
|
||||
|
||||
|
||||
<input type="hidden" name="merge_prcsAplctPrdOrdCmplt" value="${mergeInfo.sspnIdtmtTrgtOrd}"/>
|
||||
<input type="hidden" name="merge_vnt" value="${mergeInfo.vntYear}형제${mergeInfo.vntNmbr}"/>
|
||||
<input type="hidden" name="merge_reqNmbr" value="${mergeInfo.reqNmbr}"/>
|
||||
|
||||
<script>
|
||||
function fn_merge(p_bool){
|
||||
if (p_bool){ //병합
|
||||
$("input[name='prcsAplctPrdOrdCmplt']").val($("input[name='merge_prcsAplctPrdOrdCmplt']").val());
|
||||
$("input[name='dp_vnt']").val($("input[name='merge_vnt']").val());
|
||||
$("input[name='dp_reqNmbr']").val($("input[name='merge_reqNmbr']").val());
|
||||
|
||||
}else{ //병합취소
|
||||
$("input[name='prcsAplctPrdOrdCmplt']").val('');
|
||||
$("input[name='dp_vnt']").val('');
|
||||
$("input[name='dp_reqNmbr']").val('');
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
</c:if>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@ -451,7 +495,7 @@
|
||||
<td>
|
||||
<c:if test="${!empty cndtnTrgtInfoMngVO.sex}">
|
||||
<ve:code codeId="COM014" code="${cndtnTrgtInfoMngVO.sex}"/>
|
||||
<input type="hidden" name="sex" value="${cndtnTrgtInfoMngVO.sex}"/>
|
||||
<input type="hidden" name="sex" id="sex" value="${cndtnTrgtInfoMngVO.sex}"/>
|
||||
</c:if>
|
||||
<c:if test="${empty cndtnTrgtInfoMngVO.sex}">
|
||||
<ve:select codeId="COM014" name="sex" id="sex" css="class='sel_type1'"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user