개인통관부호 처리 추가(1)

This commit is contained in:
김현욱
2026-03-03 18:15:11 +09:00
parent 1b0a6f9624
commit 38f85a7409
5 changed files with 95 additions and 4 deletions

View File

@@ -212,6 +212,7 @@ public class BOOrderService {
dlvyMap.put("otrCouponSmtmUseAt", ""); dlvyMap.put("otrCouponSmtmUseAt", "");
dlvyMap.put("mngrFreeDlvyUseAt", "N"); dlvyMap.put("mngrFreeDlvyUseAt", "N");
dlvyMap.put("dlvylcAreaCd", shipping.get("dlvylcAreaCd")); dlvyMap.put("dlvylcAreaCd", shipping.get("dlvylcAreaCd"));
dlvyMap.put("cstmclerCd", shipping.get("cstmclerCd"));
dlvyMap.put("dlvylcZip", shipping.get("dlvylcZip")); dlvyMap.put("dlvylcZip", shipping.get("dlvylcZip"));
dlvyMap.put("prefcd", shipping.get("prefcd")); dlvyMap.put("prefcd", shipping.get("prefcd"));
dlvyMap.put("recpntNm", shipping.get("recpntNm")); dlvyMap.put("recpntNm", shipping.get("recpntNm"));
@@ -254,6 +255,7 @@ public class BOOrderService {
dlvyMap.put("otrCouponSmtmUseAt", ""); dlvyMap.put("otrCouponSmtmUseAt", "");
dlvyMap.put("mngrFreeDlvyUseAt", "N"); dlvyMap.put("mngrFreeDlvyUseAt", "N");
dlvyMap.put("dlvylcAreaCd", shipping.get("dlvylcAreaCd")); dlvyMap.put("dlvylcAreaCd", shipping.get("dlvylcAreaCd"));
dlvyMap.put("cstmclerCd", shipping.get("cstmclerCd"));
dlvyMap.put("dlvylcZip", shipping.get("dlvylcZip")); dlvyMap.put("dlvylcZip", shipping.get("dlvylcZip"));
dlvyMap.put("prefcd", shipping.get("prefcd")); dlvyMap.put("prefcd", shipping.get("prefcd"));
dlvyMap.put("recpntNm", shipping.get("recpntNm")); dlvyMap.put("recpntNm", shipping.get("recpntNm"));
@@ -1409,6 +1411,7 @@ public class BOOrderService {
shippingVO.setRecpntMbtlnb((String) shipping.get("recpntMbtlnb")); shippingVO.setRecpntMbtlnb((String) shipping.get("recpntMbtlnb"));
shippingVO.setDlvylcAreaCd((String) shipping.get("dlvylcAreaCd")); shippingVO.setDlvylcAreaCd((String) shipping.get("dlvylcAreaCd"));
shippingVO.setCstmclerCd((String) shipping.get("cstmclerCd"));
shippingVO.setPrefcd((String) shipping.get("prefcd")); shippingVO.setPrefcd((String) shipping.get("prefcd"));
shippingVO.setDlvylcZip((String) shipping.get("dlvylcZip")); shippingVO.setDlvylcZip((String) shipping.get("dlvylcZip"));
shippingVO.setDlvylcAdresDvCd((String) shipping.get("dlvylcAdresDvCd")); shippingVO.setDlvylcAdresDvCd((String) shipping.get("dlvylcAdresDvCd"));
@@ -1449,6 +1452,7 @@ public class BOOrderService {
shippingVO.setRecpntMbtlnb(StringUtil.isNullToString(shipping.get("recpntMbtlnb"))); shippingVO.setRecpntMbtlnb(StringUtil.isNullToString(shipping.get("recpntMbtlnb")));
shippingVO.setDlvylcAreaCd(StringUtil.isNullToString(shipping.get("dlvylcAreaCd"))); shippingVO.setDlvylcAreaCd(StringUtil.isNullToString(shipping.get("dlvylcAreaCd")));
shippingVO.setCstmclerCd(StringUtil.isNullToString(shipping.get("cstmclerCd")));
shippingVO.setPrefcd(StringUtil.isNullToString(shipping.get("prefcd"))); shippingVO.setPrefcd(StringUtil.isNullToString(shipping.get("prefcd")));
shippingVO.setDlvylcZip(StringUtil.isNullToString(shipping.get("dlvylcZip"))); shippingVO.setDlvylcZip(StringUtil.isNullToString(shipping.get("dlvylcZip")));
shippingVO.setDlvylcAdresDvCd(StringUtil.isNullToString(shipping.get("dlvylcAdresDvCd"))); shippingVO.setDlvylcAdresDvCd(StringUtil.isNullToString(shipping.get("dlvylcAdresDvCd")));

View File

@@ -28,6 +28,8 @@ public class BOOrderShippingVO extends AbstractVO {
private String dlvylcAreaCd; private String dlvylcAreaCd;
private String cstmclerCd;
private String dlvylcZip; private String dlvylcZip;
private String prefcd; private String prefcd;

View File

@@ -387,6 +387,7 @@
, RECPNT_NM , RECPNT_NM
, RECPNT_MBTLNB , RECPNT_MBTLNB
, DLVYLC_AREA_CD , DLVYLC_AREA_CD
, CSTMCLER_CD
, DLVYLC_ZIP , DLVYLC_ZIP
, PREFCD , PREFCD
, DLVYLC_ADRES_DV_CD , DLVYLC_ADRES_DV_CD
@@ -425,6 +426,7 @@
, #{recpntNm} , #{recpntNm}
, HEX(AES_ENCRYPT(REPLACE(#{recpntMbtlnb}, '-', ''), '1df5be2f7e90ae36')) , HEX(AES_ENCRYPT(REPLACE(#{recpntMbtlnb}, '-', ''), '1df5be2f7e90ae36'))
, #{dlvylcAreaCd} , #{dlvylcAreaCd}
, #{cstmclerCd}
, #{dlvylcZip} , #{dlvylcZip}
, #{prefcd} , #{prefcd}
, #{dlvylcAdresDvCd} , #{dlvylcAdresDvCd}

View File

@@ -705,6 +705,10 @@
$('#recpntMbtlnb').val($('#mbtlnb').val()); $('#recpntMbtlnb').val($('#mbtlnb').val());
$('.recpntMbtlnb_ordrInfo_text').text($('#mbtlnb').val()); $('.recpntMbtlnb_ordrInfo_text').text($('#mbtlnb').val());
$('#cstmclerCd').val($('#cstmclerCd').val());
$('.cstmclerCd_ordrInfo_text').text($('#cstmclerCd').val());
} else { } else {
let data = { let data = {
@@ -723,6 +727,8 @@
$('.recpntNm_ordrInfo_text').text($('#recpntNm').val()); $('.recpntNm_ordrInfo_text').text($('#recpntNm').val());
$('#recpntMbtlnb').val(parseJson.dftDlvylc.mbtlnb); $('#recpntMbtlnb').val(parseJson.dftDlvylc.mbtlnb);
$('.recpntMbtlnb_ordrInfo_text').text($('#recpntMbtlnb').val()); $('.recpntMbtlnb_ordrInfo_text').text($('#recpntMbtlnb').val());
$('#cstmclerCd').val(parseJson.dftDlvylc.cstmclerCd);
$('.cstmclerCd_ordrInfo_text').text($('#cstmclerCd').val());
} }
}); });
@@ -1500,6 +1506,12 @@
html += ' <input type="text" name="recpntMbtlnb" oninput="fn_set_event(this, \'keyup\', fn_fmt_telno)" maxlength="13" class="new rqrd input-text number" title="휴대폰번호" placeholder="휴대폰번호 입력 (’-’ 없이)">'; html += ' <input type="text" name="recpntMbtlnb" oninput="fn_set_event(this, \'keyup\', fn_fmt_telno)" maxlength="13" class="new rqrd input-text number" title="휴대폰번호" placeholder="휴대폰번호 입력 (’-’ 없이)">';
html += ' </td>'; html += ' </td>';
html += ' </tr>'; html += ' </tr>';
html += ' <tr class="">';
html += ' <th> <span class="orderInfo__title">개인통관번호</span></th>';
html += ' <td>';
html += ' <input type="text" name="cstmclerCd" maxlength="13" class="m-input" title="개인통관번호" placeholder="P로 시작하는 13자리 부호를 입력하세요">';
html += ' </td>';
html += ' </tr>';
html += ' <!-- 신규 배송지 선택 시 End -->'; html += ' <!-- 신규 배송지 선택 시 End -->';
html += ' <tr>'; html += ' <tr>';
html += ' <th><span class="orderInfo__title">배송요청사항</span></th>'; html += ' <th><span class="orderInfo__title">배송요청사항</span></th>';
@@ -1763,6 +1775,8 @@
$('.presentArea').hide(); $('.presentArea').hide();
$('.presentArea').find('input').prop('disabled', true); $('.presentArea').find('input').prop('disabled', true);
$('.cstmclerArea').hide();
$('.cstmclerArea').find('input').prop('disabled', true);
$('.presentShowArea').show(); $('.presentShowArea').show();
$('.presentShowArea').find('input').prop('disabled', false); $('.presentShowArea').find('input').prop('disabled', false);
@@ -1783,6 +1797,8 @@
if (dlvylcDvCd === 'New') { if (dlvylcDvCd === 'New') {
$('.presentArea').show(); $('.presentArea').show();
$('.presentArea').find('input').prop('disabled', false); $('.presentArea').find('input').prop('disabled', false);
$('.cstmclerArea').show();
$('.cstmclerArea').find('input').prop('disabled', false);
$('.presentShowArea').hide(); $('.presentShowArea').hide();
$('.presentShowArea').find('input').prop('disabled', true); $('.presentShowArea').find('input').prop('disabled', true);
} }
@@ -1833,6 +1849,17 @@
$(form).find('input[name="dlvylcAdresDtl"]').val(data.dtlAdres); $(form).find('input[name="dlvylcAdresDtl"]').val(data.dtlAdres);
$(form).find('input[name="dlvylcAdres"]').val('01' === $(form).find('input[name="dlvylcAdresDvCd"]').val() ? $(form).find('input[name="dlvylcRnmAdres"]').val() : $(form).find('input[name="dlvylcLnbAdres"]').val()); $(form).find('input[name="dlvylcAdres"]').val('01' === $(form).find('input[name="dlvylcAdresDvCd"]').val() ? $(form).find('input[name="dlvylcRnmAdres"]').val() : $(form).find('input[name="dlvylcLnbAdres"]').val());
let dlvylcAreaCd = $(form).find('input[name="dlvylcAreaCd"]').val();
if('JP' === dlvylcAreaCd){
$('.cstmclerArea').hide();
$('.cstmclerArea').find('input').prop('disabled', true);
} else {
$('.cstmclerArea').show();
$('.cstmclerArea').find('input').prop('disabled', false);
}
// 배송지 정보 세팅 이후 결제예정금액 재계산 // 배송지 정보 세팅 이후 결제예정금액 재계산
fn_get_setle_amt(); fn_get_setle_amt();
} }
@@ -2701,12 +2728,19 @@
/* 선물하기 > 정합성 검사 종료 */ /* 선물하기 > 정합성 검사 종료 */
} else { } else {
// console.log("dlvylcDvCd : ",dlvylcDvCd);
if ('New' === dlvylcDvCd) { if ('New' === dlvylcDvCd) {
const dlvylcAreaCd2 = $('#dlvylcForm').find('input[name="dlvylcAreaCd"]').val();
console.log("dlvylcAreaCd(new) : ",dlvylcAreaCd2);
$('#dlvylcForm').find('.rqrd').each(function () { $('#dlvylcForm').find('.rqrd').each(function () {
const val = $(this).val(); const val = $(this).val();
if (fn_is_empty(val)) { if (fn_is_empty(val)) {
const name = $(this).attr('name'); const name = $(this).attr('name');
if('JP' !== dlvylcAreaCd2 || 'cstmclerCd' !== name ) {
const title = $(this).attr('title'); const title = $(this).attr('title');
alert(title + '을 입력해 주십시요'); alert(title + '을 입력해 주십시요');
@@ -2717,7 +2751,28 @@
return false; return false;
} }
}
}); });
} else {
const dlvylcAreaCd = $('#dlvylcAreaCd').val();
// console.log("dlvylcAreaCd(dft) : ",dlvylcAreaCd);
if('KR' === dlvylcAreaCd){
// console.log("KR");
const val = $('#cstmclerCd').val();
if (fn_is_empty(val)) {
alert('개인통관번호를 입력해 주십시요');
$('#dlvylcForm').find('input[name="' + name + '"]').focus();
isValid = false;
return false;
}
}
} }
} }
@@ -3592,6 +3647,28 @@
<span class="orderInfo__text recpntMbtlnb_ordrInfo_text"><c:out value="${dftDlvylc.mbtlnb}"/></span> <span class="orderInfo__text recpntMbtlnb_ordrInfo_text"><c:out value="${dftDlvylc.mbtlnb}"/></span>
</td> </td>
</tr> </tr>
<c:choose>
<c:when test="${dftDlvylc.dlvylcAreaCd eq 'KR'}">
<tr class="deliveryAddressDefault">
<th><span class="orderInfo__title">개인통관번호</span></th>
<td>
<input type="hidden" id="cstmclerCd" class="dft" value="<c:out value="${dftDlvylc.cstmclerCd}"/>">
<%-- <span class="orderInfo__text cstmclerCd_ordrInfo_text"><c:out value="${dftDlvylc.cstmclerCd}"/></span>--%>
<c:choose>
<c:when test="${not empty dftDlvylc.cstmclerCd}">
<input type="text" name="cstmclerCd" maxlength="13" class="orderInfo__text cstmclerCd_ordrInfo_text" title="개인통관번호" value="<c:out value="${dftDlvylc.cstmclerCd}"/>" placeholder="배송지 관리에서 입력하세요.">
</c:when>
<c:otherwise>
<input type="text" name="cstmclerCd" maxlength="13" class="orderInfo__text cstmclerCd_ordrInfo_text" title="개인통관번호" value="<c:out value="${dftDlvylc.cstmclerCd}"/>" placeholder="배송지 관리에서 입력하세요." readonly>
</c:otherwise>
</c:choose>
</tr>
</td>
</c:when>
<c:otherwise>
<input type="hidden" id="cstmclerCd" name="cstmclerCd" class="dft" value="<c:out value="${dftDlvylc.cstmclerCd}"/>">
</c:otherwise>
</c:choose>
<!-- 기본 배송지 선택 시 End --> <!-- 기본 배송지 선택 시 End -->
<!-- 신규 배송지 선택 시 Start --> <!-- 신규 배송지 선택 시 Start -->
<tr class="deliveryAddressNew" style="display:none;"> <tr class="deliveryAddressNew" style="display:none;">
@@ -3624,6 +3701,12 @@
<input type="text" name="recpntMbtlnb" oninput="fn_set_event(this, 'keyup', fn_fmt_telno)" maxlength="13" class="new rqrd input-text number rqrd_gift" title="휴대폰번호" placeholder="휴대폰번호 입력 (’-’ 없이)" readonly> <input type="text" name="recpntMbtlnb" oninput="fn_set_event(this, 'keyup', fn_fmt_telno)" maxlength="13" class="new rqrd input-text number rqrd_gift" title="휴대폰번호" placeholder="휴대폰번호 입력 (’-’ 없이)" readonly>
</td> </td>
</tr> </tr>
<tr class="deliveryAddressNew cstmclerArea" style="display:none;">
<th> <span class="orderInfo__title">개인통관번호</span></th>
<td>
<input type="text" name="cstmclerCd" maxlength="13" class="new rqrd input-text rqrd_gift" title="개인통관번호" placeholder="배송지 관리에서 입력하세요." readonly>
</td>
</tr>
<!-- 신규 배송지 선택 시 End --> <!-- 신규 배송지 선택 시 End -->
<tr class="presentShowArea" style="display:none;"> <tr class="presentShowArea" style="display:none;">
<th> <span class="orderInfo__title">선물메세지</span></th> <th> <span class="orderInfo__title">선물메세지</span></th>

View File

@@ -2496,7 +2496,7 @@
dlvylc = fn_get_dlvylc_data(); dlvylc = fn_get_dlvylc_data();
} }
order['shipping'] = dlvylc; setle['shipping'] = dlvylc;
setle['sopmalCd'] = $('#sopmalCd').val(); setle['sopmalCd'] = $('#sopmalCd').val();
setle['dlvylc'] = JSON.parse(localStorage.getItem('dlvylc')); setle['dlvylc'] = JSON.parse(localStorage.getItem('dlvylc'));