사용자 기반강화 수강신청서 팝업 > 분야 수강여부 사전질의 추가

This commit is contained in:
hylee 2023-11-30 10:43:21 +09:00
parent 97795040a8
commit abd3e8fc4a
7 changed files with 148 additions and 52 deletions

View File

@ -516,8 +516,8 @@ public class FndtnEnhanceTrnController {
SsoLoginVO ssoLoginVO = checkLoginUtil.getSSOLoginVO(request); //SSO 로그인 정보 가져오기 SsoLoginVO ssoLoginVO = checkLoginUtil.getSSOLoginVO(request); //SSO 로그인 정보 가져오기
vEPrcsDetailVO.setFrstRegisterId(loginVO.getUniqId()); //esntl_id // vEPrcsDetailVO.setFrstRegisterId(loginVO.getUniqId()); //esntl_id
vEPrcsDetailVO.setLctrDivCd("50"); //강의구분코드 VE0011 10-청소년강의, 20-성인강의, 30-체험, 50-기반강화, 60-조건부 // vEPrcsDetailVO.setLctrDivCd("50"); //강의구분코드 VE0011 10-청소년강의, 20-성인강의, 30-체험, 50-기반강화, 60-조건부
VEEduAplctVO vEEduAplctVO = new VEEduAplctVO(); VEEduAplctVO vEEduAplctVO = new VEEduAplctVO();
@ -541,6 +541,10 @@ public class FndtnEnhanceTrnController {
vEEduAplctVO.setInsttNm(vEPrcsDetailVO.getInsttNm()); vEEduAplctVO.setInsttNm(vEPrcsDetailVO.getInsttNm());
vEEduAplctVO.setdBirth(vEPrcsDetailVO.getdBirth()); vEEduAplctVO.setdBirth(vEPrcsDetailVO.getdBirth());
vEEduAplctVO.setFld(vEPrcsDetailVO.getFld());
vEEduAplctVO.setLctrYn(vEPrcsDetailVO.getLctrYn());
vEEduAplctVO.setPrvsQs(vEPrcsDetailVO.getPrvsQs());
fndtnEnhanceTrnService.insertVeEduAplct(vEEduAplctVO); fndtnEnhanceTrnService.insertVeEduAplct(vEEduAplctVO);
@ -691,7 +695,7 @@ public class FndtnEnhanceTrnController {
} }
@RequestMapping("/web/ve/aplct/fndtnEnhanceTrn/eduRegPopup.do") @RequestMapping("/web/ve/aplct/fndtnEnhanceTrn/eduAplctPop.do")
public String eduRegPopup( public String eduRegPopup(
@ModelAttribute("vEPrcsDetailVO") VEPrcsDetailVO vEPrcsDetailVO @ModelAttribute("vEPrcsDetailVO") VEPrcsDetailVO vEPrcsDetailVO
, ModelMap model , ModelMap model

View File

@ -409,6 +409,9 @@ public class VEEduAplctVO extends ComDefaultVO implements Serializable {
private Boolean qestRsltExists; //설문여부 private Boolean qestRsltExists; //설문여부
private String fld; // 분야
private String lctrYn; // 저작권 교육 수강 여부
private String prvsQs; // 교육관련 사전질의
public String getSpecialWorkAllow() { public String getSpecialWorkAllow() {
@ -1786,6 +1789,24 @@ public class VEEduAplctVO extends ComDefaultVO implements Serializable {
public void setQestRsltExists(Boolean qestRsltExists) { public void setQestRsltExists(Boolean qestRsltExists) {
this.qestRsltExists = qestRsltExists; this.qestRsltExists = qestRsltExists;
} }
public String getFld() {
return fld;
}
public void setFld(String fld) {
this.fld = fld;
}
public String getLctrYn() {
return lctrYn;
}
public void setLctrYn(String lctrYn) {
this.lctrYn = lctrYn;
}
public String getPrvsQs() {
return prvsQs;
}
public void setPrvsQs(String prvsQs) {
this.prvsQs = prvsQs;
}
} }

View File

@ -169,6 +169,10 @@ public class VEPrcsDetailVO extends ComDefaultVO implements Serializable {
private String qustnrTmplatId; private String qustnrTmplatId;
private String fld; // 분야
private String lctrYn; // 저작권 교육 수강 여부
private String prvsQs; // 교육관련 사전질의
public String getSearchDiv() { public String getSearchDiv() {
return searchDiv; return searchDiv;
@ -816,6 +820,24 @@ public class VEPrcsDetailVO extends ComDefaultVO implements Serializable {
public void setQustnrTmplatId(String qustnrTmplatId) { public void setQustnrTmplatId(String qustnrTmplatId) {
this.qustnrTmplatId = qustnrTmplatId; this.qustnrTmplatId = qustnrTmplatId;
} }
public String getFld() {
return fld;
}
public void setFld(String fld) {
this.fld = fld;
}
public String getLctrYn() {
return lctrYn;
}
public void setLctrYn(String lctrYn) {
this.lctrYn = lctrYn;
}
public String getPrvsQs() {
return prvsQs;
}
public void setPrvsQs(String prvsQs) {
this.prvsQs = prvsQs;
}
} }

View File

@ -317,7 +317,10 @@
USE_YN, USE_YN,
CHRG_NM, CHRG_NM,
INSTT_NM, INSTT_NM,
D_BIRTH D_BIRTH,
FLD,
LCTR_YN,
PRVS_QS
) )
VALUES( VALUES(
#eduAplctOrd#, #eduAplctOrd#,
@ -336,7 +339,10 @@
'Y', 'Y',
#chrgNm#, #chrgNm#,
#insttNm#, #insttNm#,
#dBirth# #dBirth#,
#fld#,
#lctrYn#,
#prvsQs#
) )
WHEN MATCHED THEN WHEN MATCHED THEN
UPDATE UPDATE
@ -371,6 +377,15 @@
<isNotEmpty property="dBirth"> <isNotEmpty property="dBirth">
,D_BIRTH = #dBirth# ,D_BIRTH = #dBirth#
</isNotEmpty> </isNotEmpty>
<isNotEmpty property="fld">
,FLD = #fld#
</isNotEmpty>
<isNotEmpty property="lctrYn">
,LCTR_YN = #lctrYn#
</isNotEmpty>
<isNotEmpty property="prvsQs">
,PRVS_QS = #prvsQs#
</isNotEmpty>
</insert> </insert>

View File

@ -38,6 +38,7 @@
var regStatus = true; var regStatus = true;
// 텍스트가 비어있는지 확인 // 텍스트가 비어있는지 확인
console.log('$ddlnCdStts.text(): ',$ddlnCdStts.text());
if ($ddlnCdStts.text().trim() === "") { if ($ddlnCdStts.text().trim() === "") {
var dateText = $ddlnCdStts.closest('table').find("td:eq(2)").text().trim(); var dateText = $ddlnCdStts.closest('table').find("td:eq(2)").text().trim();
@ -70,6 +71,10 @@
else{ else{
$('#regBtn').text('신청'); $('#regBtn').text('신청');
} }
}else if($ddlnCdStts.text().trim() === "찜하기"){
$('#regBtn').text('신청');
regStatus = false;
} }
$('#regBtn').prop('disabled', regStatus); // 버튼 비활성화 $('#regBtn').prop('disabled', regStatus); // 버튼 비활성화
} }
@ -156,9 +161,9 @@
} }
commonPopLayeropen( commonPopLayeropen(
"${pageContext.request.contextPath}/web/ve/aplct/fndtnEnhanceTrn/eduRegPopup.do" "${pageContext.request.contextPath}/web/ve/aplct/fndtnEnhanceTrn/eduAplctPop.do"
, 800 , 850
, 800 , 900
, data , data
, "N" , "N"
, "eduRegPopup" , "eduRegPopup"

View File

@ -292,7 +292,7 @@ $(document).ready(function(){
} }
commonPopLayeropen( commonPopLayeropen(
"${pageContext.request.contextPath}/web/ve/aplct/fndtnEnhanceTrn/eduRegPopup.do" "${pageContext.request.contextPath}/web/ve/aplct/fndtnEnhanceTrn/eduAplctPop.do"
, 800 , 800
, 800 , 800
, data , data

View File

@ -17,6 +17,12 @@
<style> <style>
.duet-date__dialog-content,.duet-date__dialog{max-width:400px;width:364px;} .duet-date__dialog-content,.duet-date__dialog{max-width:400px;width:364px;}
.popup_wrap.popType01{left: 25%;width: 50%;} .popup_wrap.popType01{left: 25%;width: 50%;}
.twoRow{width: 100%;}
input::placeholder {
/* color: red; */
font-size: 0.7em;
/* font-style: italic; */
}
</style> </style>
<script type="text/javaScript" language="javascript"> <script type="text/javaScript" language="javascript">
@ -42,28 +48,40 @@ $(document).ready(function(){
}); });
// value 체크
// 20231130 이호영
function fnValidation(){ function fnValidation(){
var chrgNm = document.popForm.chrgNm.value;
var insttNm = document.popForm.insttNm.value;
var dBirth = document.popForm.dBirth.value;
if(chrgNm == ''){ var valChk = true
alert('성명을 입력해 주세요.');
return false; // 텍스트 입력 필드에 값이 있는지 확인
}else if(insttNm ==''){ $('input[type="text"]').each(function() {
alert('소속기업을 입력해 주세요.'); if ($(this).val() == '') {
return false; var fieldName = $(this).closest('td').prev('th').find('p').text();
}else if(dBirth ==''){ alert(fieldName + '를 입력해주세요.');
$(this).focus();
valChk = false
return false; // 함수 실행 중지
}
});
// duet-date라서 name밖에 없음
var $dBirth = $('input[name="dBirth"]');
if($dBirth.val() ==''){
alert('생년월일을 입력해 주세요.'); alert('생년월일을 입력해 주세요.');
$dBirth.focus();
return false; return false;
} }
// alert 두번 방지 if
if(valChk){
if(!$('#chkY').prop("checked")){ if(!$('#chkY').prop("checked")){
alert('개인정보 처리 동의해 주세요.') alert('개인정보 처리 동의해 주세요.')
return false; return false;
} }
}
return true;
return valChk;
} }
function fncEduReg(prcsAplctPrdOrd){ function fncEduReg(prcsAplctPrdOrd){
@ -72,12 +90,6 @@ $(document).ready(function(){
return false; return false;
} }
var regForm2 = document.regForm2;
regForm2.prcsAplctPrdOrd.value = prcsAplctPrdOrd;
regForm2.chrgNm.value = document.popForm.chrgNm.value;
regForm2.insttNm.value = document.popForm.insttNm.value;
regForm2.dBirth.value = document.popForm.dBirth.value;
var data = new FormData(document.getElementById("regForm2")); var data = new FormData(document.getElementById("regForm2"));
if(confirm("신청하시겠습니까?")){ if(confirm("신청하시겠습니까?")){
var url = "${pageContext.request.contextPath}/web/ve/aplct/fndtnEnhanceTrn/eduRegAjax.do"; var url = "${pageContext.request.contextPath}/web/ve/aplct/fndtnEnhanceTrn/eduRegAjax.do";
@ -108,15 +120,10 @@ $(document).ready(function(){
</script> </script>
<form name="regForm2" id="regForm2">
<input type="hidden" name="prcsAplctPrdOrd" value="${vEPrcsDetailVO.prcsAplctPrdOrd}">
<input type="hidden" name="chrgNm">
<input type="hidden" name="insttNm">
<input type="hidden" name="dBirth">
<input type="hidden" name="eduAplctOrd" value="${vEPrcsDetailVO.eduAplctOrd}">
</form>
<form id="popForm" name="popForm" method="post"> <form id="regForm2" name="regForm2" method="post">
<input type="hidden" name="prcsAplctPrdOrd" value="${vEPrcsDetailVO.prcsAplctPrdOrd}">
<input type="hidden" name="eduAplctOrd" value="${vEPrcsDetailVO.eduAplctOrd}">
<!-- 신청인정보 --> <!-- 신청인정보 -->
<div class="tooltip-wrap q_pop"> <div class="tooltip-wrap q_pop">
<div class="popup_wrap popType01" tabindex="0" data-tooltip-con="target_confirm_popup" data-focus="target_confirm_popup" data-focus-prev="target_confirm_popup_close"> <div class="popup_wrap popType01" tabindex="0" data-tooltip-con="target_confirm_popup" data-focus="target_confirm_popup" data-focus-prev="target_confirm_popup_close">
@ -130,7 +137,9 @@ $(document).ready(function(){
<table> <table>
<caption>신청인정보를 입력하는 표</caption> <caption>신청인정보를 입력하는 표</caption>
<colgroup> <colgroup>
<col style="width: 145px;"> <col style="width: 170px;">
<col style="width: auto;">
<col style="width: 170px;">
<col style="width: auto;"> <col style="width: auto;">
</colgroup> </colgroup>
<tbody> <tbody>
@ -139,18 +148,8 @@ $(document).ready(function(){
<p>성명</p> <p>성명</p>
</th> </th>
<td> <td>
<input type="text" name="chrgNm" id="chrgNm"/> <input type="text" class="twoRow" name="chrgNm" id="chrgNm"/>
</td> </td>
</tr>
<tr>
<th scope="row">
<p>소속기업</p>
</th>
<td>
<input type="text" name="insttNm" id="insttNm"/>
</td>
</tr>
<tr>
<th scope="row"> <th scope="row">
<p>생년월일</p> <p>생년월일</p>
</th> </th>
@ -160,9 +159,39 @@ $(document).ready(function(){
</div> </div>
</td> </td>
</tr> </tr>
<tr>
<th scope="row">
<p>소속기업</p>
</th>
<td>
<input type="text" class="twoRow" name="insttNm" id="insttNm"/>
</td>
<th scope="row">
<p>분야</p>
</th>
<td>
<input placeholder="어문, 음악, 영상, SW, 연극 등" type="text" class="twoRow" name="fld" id="fld"/>
</td>
</tr>
<tr>
<th scope="row">
<p>저작권 교육 수강 여부</p>
</th>
<td>
<input type="text" class="lctrYn" name="lctrYn" id="lctrYn"/>
</td>
</tr>
<tr>
<th scope="row">
<p>교육관련 사전질의</p>
</th>
<td colspan="2">
<input type="text" name="prvsQs" id="prvsQs" style="width: 100%;"/>
</td>
</tr>
<tr> <tr>
<td colspan="2"> <td colspan="3">
<pre>개인정보 처리 동의서 <pre>개인정보 처리 동의서
한국저작권위원회에서는 귀하의 개인정보를 중요시하며, 개인정보보호법 제15조, 제17조, 제22조, 제23조 및 제24조에 따라 아래와 같이 개인정보 처리에 관하여 동의를 얻고자 합니다. 한국저작권위원회에서는 귀하의 개인정보를 중요시하며, 개인정보보호법 제15조, 제17조, 제22조, 제23조 및 제24조에 따라 아래와 같이 개인정보 처리에 관하여 동의를 얻고자 합니다.