ソースを参照

수정사항처리

tsit14 5 年 前
コミット
bbf5d18a34

+ 28 - 5
src/main/webapp/WEB-INF/views/mob/order/OrderAddPaymentFormMob.html

@@ -211,11 +211,12 @@
 								</div>
 							</div>
 						</th:block>
+						
+						<div class="agree_payment">
+							위 주문내역을 확인 하였으며, 회원 본인은 결제에 동의합니다. (전자상거래법 제 8조 제2항)
+						</div>
 					</div>
 					
-					<div class="agree_payment">
-						위 주문내역을 확인 하였으며, 회원 본인은 결제에 동의합니다. (전자상거래법 제 8조 제2항)
-					</div>
 				</div>
 	
 				<!-- //결제 정보 -->
@@ -275,8 +276,9 @@ $("#btn_payment").on("click", function(){
 			} else if (pgGb == "KAKAO") {
 				fnKakaoPaymentReady();
 			} else if (pgGb == "KCP" || pgGb == "PAYCO") {
-				//jsf__pay(document.order_info);
-				$("#order_info input[name=Ret_URL]").val("http:" + _frontUrl + "/order/pay/result/response");
+				// 2021.06.02 태팔요청
+				var protocol = location.protocol;
+				$("#order_info input[name=Ret_URL]").val(protocol + _frontUrl + "/order/addPay/result/response");
 				kcp_AJAX();
 			}
 		}
@@ -284,6 +286,27 @@ $("#btn_payment").on("click", function(){
 });
 </script>
 <script type="text/javascript">
+
+//구매조건 확인 및 결제대행 서비스 약관 동의 클릭시
+$(document).on('click','.area_paymentinfo .payinfo_blk_wrap a',function(e){
+	e.preventDefault();
+	//$(this).parent('.payinfo_blk_wrap').toggleClass('on');
+	$(this).siblings('.payinfo_blk_parent').toggle();
+	$(this).parents('.payinfo_blk').siblings('.payinfo_blk').removeClass('on'); //210428_수정 : 아코디언 추가.
+	var privacyToggle = $(this).find('span');
+	$(privacyToggle).text($(privacyToggle).text() == '보기' ? '닫기' : '보기');
+	return false;
+});
+
+//개인정보동의 열고닫기
+$(document).on('click','.area_paymentinfo .payinfo_blk a',function(e){
+	e.preventDefault();
+	$(this).parents('.payinfo_blk').toggleClass('on');
+	var privacyToggle = $(this).find('span');
+	$(privacyToggle).text($(privacyToggle).text() == '보기' ? '닫기' : '보기');
+	return false;
+});
+
 $(document).ready( function() {
 	// 1. 타이틀설정
 	$("#htopTitle").text("추가결제");

+ 31 - 29
src/main/webapp/WEB-INF/views/mob/order/OrderFormMob.html

@@ -245,8 +245,8 @@
 				</div>
 				
 				<div class="area_paymentinfo">
-					<!-- @자사만,무통장,실시간있으면 미노출 -->
-					<!-- @입점있으면  -->
+					<!-- @ 2021.06.11 자사만, (무통장, 실시간) 미노출 -->
+					<!-- @ 입점있으면 무조건 노출  -->
 					<div class="paymentinfo">
 						<div class="payinfo_blk_wrap">
 							<a href="javascript:void(0);">구매조건 확인 및 결제대행 서비스 약관 동의<span>보기</span></a>
@@ -842,14 +842,11 @@ var freegiftInfoSet = function() {
 				$("#orderForm .freegiftRdo").each(function(){
 					var usepoint 	= parseInt($(this).attr("usepoint"));
 					var count 		= parseInt($(this).attr("count"));
-					
+
 					// 첫번째 무료 선택 
 					if (usepoint == 0 && count == 1) {
 						$(this).trigger("click");
 						
-						total_gift 		= 0;
-						total_deduct 	= 0;
-						
 						// 2021.04.14 사은품 사용 포인트가 보유포인트보다 작아야 한다.
 						var rmPntAmt 			= parseInt($("#orderForm input[name='rmPntAmt']").val());
 						var freegiftUsePnt 		= parseInt($("#orderAmtForm .freegiftUsePnt").text());
@@ -861,20 +858,15 @@ var freegiftInfoSet = function() {
 							return false;
 						}
 						
-						$("#orderForm .freegiftRdo").each(function(){
-							if ($(this).attr("allYn") == "Y" ) {
+						/*
+						// 라디오버튼 사은품 체크
+						if ($(this).is(":checked")) {
+							// 수령거부가 아닐때 체크
+							if ($(this).val() != "noSel") {
 								total_gift 		+= 1;
+								total_deduct 	+= parseInt($(this).attr("usepoint"));
 							}
-							
-							// 라디오버튼 사은품 체크
-							if ($(this).is(":checked")) {
-								// 수령거부가 아닐때 체크
-								if ($(this).val() != "noSel") {
-									total_gift 		+= 1;
-									total_deduct 	+= parseInt($(this).attr("usepoint"));
-								}
-							}
-						});
+						}
 						
 						$("#orderForm .total_gift").text(total_gift);							// 사은품총선택개수
 						$("#orderForm .total_deduct").text(total_deduct.addComma());			// 사은품총사용포인트
@@ -882,14 +874,17 @@ var freegiftInfoSet = function() {
 						
 						// 포인트초기화기능
 						pntDcAmtReset();
+						*/
 					}
 				});
-
-				total_gift = 0;
 				
-				// 사은품테이블 그리기
-				$("#orderForm .gift_box").each(function(){
-					$(this).find(".freegiftRdo").each(function(){
+				// 2021.06.11 사은품 초기화 작업
+				total_gift = 0;
+				$("#orderForm .freegiftRdo").each(function(){
+					if ($(this).attr("allYn") == "Y" ) {
+						total_gift += 1;
+					} else {
+						// 라디오버튼 사은품 체크
 						if ($(this).is(":checked")) {
 							// 수령거부가 아닐때 체크
 							if ($(this).val() != "noSel") {
@@ -897,10 +892,16 @@ var freegiftInfoSet = function() {
 								total_deduct 	+= parseInt($(this).attr("usepoint"));
 							}
 						}
-						$("#orderForm .total_gift").text(total_gift);						// 사은품총선택개수
-					});
+					}
 				});
 				
+				$("#orderForm .total_gift").text(total_gift);							// 사은품총선택개수
+				$("#orderForm .total_deduct").text(total_deduct.addComma());			// 사은품총사용포인트
+				$("#orderAmtForm .freegiftUsePnt").text(total_deduct);
+				
+				// 포인트초기화기능
+				pntDcAmtReset();
+				
 				// 2021.04.29 사은품동의 체크 기능
 				/*
 				$("#orderForm #chk-agree_gift").on("click", function(){
@@ -982,9 +983,9 @@ var paymentInfoSet = function() {
 						$("#orderForm .area_paymentinfo .agree1").hide();
 						
 						if (delvCnt > 0) {
-							$("#orderForm .area_paymentinfo .paymentinfo.agree2").show();
+							$("#orderForm .area_paymentinfo .paymentinfo").show();
 						} else {
-							$("#orderForm .area_paymentinfo .paymentinfo.agree2").hide();
+							$("#orderForm .area_paymentinfo .paymentinfo").hide();
 						}
 					}
 				});
@@ -992,10 +993,11 @@ var paymentInfoSet = function() {
 				// 2021.05.16 초기값설정
 				$("#orderForm .area_paymethod .agree_insurance").hide();
 				$("#orderForm .area_paymentinfo .agree1").hide();
+				
 				if (delvCnt > 0) {
-					$("#orderForm .area_paymentinfo .paymentinfo.agree2").show();
+					$("#orderForm .area_paymentinfo .paymentinfo").show();
 				} else {
-					$("#orderForm .area_paymentinfo .paymentinfo.agree2").hide();
+					$("#orderForm .area_paymentinfo .paymentinfo").hide();
 				}
 
 				// 결제하기

+ 32 - 43
src/main/webapp/WEB-INF/views/web/order/OrderFormWeb.html

@@ -230,11 +230,11 @@
 							</div>
 							
 							<div class="area_paymentinfo">
-								<!-- @자사만,무통장,실시간있으면 미노출 -->
-								<!-- @입점있으면  -->
+								<!-- @ 2021.06.11 자사만, (무통장, 실시간) 미노출 -->
+								<!-- @ 입점있으면 무조건 노출  -->
 								<div class="paymentinfo">
 									<div class="payinfo_blk">
-										<a href="">개인정보 제공에 대한 동의<span>보기</span></a>
+										<a href="javascript:void(0);">개인정보 제공에 대한 동의<span>보기</span></a>
 										<div class="infotxt">STYLE24는 다음과 같이 회원님의 개인정보를 제3자에게 제공합니다.
 											<table>
 												<colgroup>
@@ -835,14 +835,11 @@ var freegiftInfoSet = function() {
 				$("#orderForm .freegiftRdo").each(function(){
 					var usepoint 	= parseInt($(this).attr("usepoint"));
 					var count 		= parseInt($(this).attr("count"));
-					
+
 					// 첫번째 무료 선택 
 					if (usepoint == 0 && count == 1) {
 						$(this).trigger("click");
 						
-						total_gift 		= 0;
-						total_deduct 	= 0;
-						
 						// 2021.04.14 사은품 사용 포인트가 보유포인트보다 작아야 한다.
 						var rmPntAmt 			= parseInt($("#orderForm input[name='rmPntAmt']").val());
 						var freegiftUsePnt 		= parseInt($("#orderAmtForm .freegiftUsePnt").text());
@@ -853,41 +850,33 @@ var freegiftInfoSet = function() {
 							mcxDialog.alert("보유포인트가 부족합니다.");
 							return false;
 						}
-						
-						$("#orderForm .freegiftRdo").each(function(){
-							if ($(this).attr("allYn") == "Y" ) {
-								total_gift 		+= 1;
-							}
-							
-							// 라디오버튼 사은품 체크
-							if ($(this).is(":checked")) {
-								// 수령거부가 아닐때 체크
-								if ($(this).val() != "noSel") {
-									total_gift 		+= 1;
-									total_deduct 	+= parseInt($(this).attr("usepoint"));
-								}
-							}
-						});
-						
-						$("#orderForm .total_gift").text(total_gift);							// 사은품총선택개수
-						$("#orderForm .total_deduct").text(total_deduct.addComma());			// 사은품총사용포인트
-						$("#orderAmtForm .freegiftUsePnt").text(total_deduct);
-						
-						// 포인트초기화기능
-						pntDcAmtReset();
 					}
 				});
 				
-				// 사은품테이블 그리기
-				$("#orderForm .gift_box").each(function(){
-					$(this).find(".freegiftRdo").each(function(){
-						if ($(this).attr("allYn") == "Y" ) {
-							total_gift += 1;
+				// 2021.06.11 사은품 초기화 작업
+				total_gift = 0;
+				$("#orderForm .freegiftRdo").each(function(){
+					if ($(this).attr("allYn") == "Y" ) {
+						total_gift += 1;
+					} else {
+						// 라디오버튼 사은품 체크
+						if ($(this).is(":checked")) {
+							// 수령거부가 아닐때 체크
+							if ($(this).val() != "noSel") {
+								total_gift 		+= 1;
+								total_deduct 	+= parseInt($(this).attr("usepoint"));
+							}
 						}
-						$("#orderForm .total_gift").text(total_gift);						// 사은품총선택개수
-					});
+					}
 				});
 				
+				$("#orderForm .total_gift").text(total_gift);							// 사은품총선택개수
+				$("#orderForm .total_deduct").text(total_deduct.addComma());			// 사은품총사용포인트
+				$("#orderAmtForm .freegiftUsePnt").text(total_deduct);
+				
+				// 포인트초기화기능
+				pntDcAmtReset();
+				
 				// 2021.04.29 사은품동의 체크 기능
 				/*
 				$("#orderForm #chk-agree_gift").on("click", function(){
@@ -943,9 +932,9 @@ var paymentInfoSet = function() {
 					}
 					
 					if (delvCnt > 0) {
-						$("#orderForm .area_paymentinfo").show();
+						$("#orderForm .area_paymentinfo .paymentinfo").show();
 					} else {
-						$("#orderForm .area_paymentinfo").hide();
+						$("#orderForm .area_paymentinfo .paymentinfo").hide();
 					}
 				});
 				
@@ -956,7 +945,7 @@ var paymentInfoSet = function() {
 					if (payType == "실시간계좌이체" || payType == "무통장입금" ) {
 						if ($(this).is(":checked")) {
 							$("#orderForm .area_paymethod .agree_insurance").show();
-							$("#orderForm .area_paymentinfo").show();
+							$("#orderForm .area_paymentinfo .paymentinfo").show();
 							$("#orderForm .area_paymentinfo .agree1").show();
 						} else {
 							displayTemp = false;
@@ -969,9 +958,9 @@ var paymentInfoSet = function() {
 						$("#orderForm .area_paymentinfo .agree1").hide();
 						
 						if (delvCnt > 0) {
-							$("#orderForm .area_paymentinfo").show();
+							$("#orderForm .area_paymentinfo .paymentinfo").show();
 						} else {
-							$("#orderForm .area_paymentinfo").hide();
+							$("#orderForm .area_paymentinfo .paymentinfo").hide();
 						}
 					}
 				});
@@ -979,9 +968,9 @@ var paymentInfoSet = function() {
 				// 2021.05.16 초기값설정
 				$("#orderForm .area_paymentinfo .agree1").hide();
 				if (delvCnt > 0) {
-					$("#orderForm .area_paymentinfo").show();
+					$("#orderForm .area_paymentinfo .paymentinfo").show();
 				} else {
-					$("#orderForm .area_paymentinfo").hide();
+					$("#orderForm .area_paymentinfo .paymentinfo").hide();
 				}
 				
 				// 결제하기