Просмотр исходного кода

비회원 취반교 목록 화면 개발 임시 커밋

card007 5 лет назад
Родитель
Сommit
eafd19d4e7

+ 58 - 105
src/main/java/com/style24/front/biz/web/TsfNoMemberController.java

@@ -6,7 +6,6 @@ import java.util.List;
 
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Controller;
-import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestMapping;
@@ -33,7 +32,6 @@ import com.style24.front.support.controller.TsfBaseController;
 import com.style24.front.support.security.session.TsfSession;
 import com.style24.persistence.TscPageRequest;
 import com.style24.persistence.domain.Cart;
-import com.style24.persistence.domain.Customer;
 import com.style24.persistence.domain.Order;
 import com.style24.persistence.domain.OrderChange;
 
@@ -457,7 +455,7 @@ public class TsfNoMemberController extends TsfBaseController {
 	 * @param Cart
 	 * @return Collecion<Cart>
 	 * @author card007
-	 * @since 2021. 03. 26
+	 * @since 2021. 04. 28
 	 */
 	@PostMapping("/cart/add/info")
 	@ResponseBody
@@ -573,7 +571,7 @@ public class TsfNoMemberController extends TsfBaseController {
 	 * @param OrderChange
 	 * @return GagaResponse
 	 * @author card007
-	 * @since 2021. 04. 20
+	 * @since 2021. 05. 02
 	 */
 	@PostMapping("/return/cancel")
 	@ResponseBody
@@ -604,7 +602,7 @@ public class TsfNoMemberController extends TsfBaseController {
 	 * @param OrderChange
 	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 04. 05
+	 * @since 2021. 05. 02
 	 */
 	@ResponseBody
 	@RequestMapping(value = "/refund/account/register/popup/form")
@@ -625,17 +623,13 @@ public class TsfNoMemberController extends TsfBaseController {
 		return mav;
 	}
 
-	// =========================================================================================
-	// ==================================    아직 처리 안함    =====================================
-	// =========================================================================================
-
 	/**
-	 * 마이페이지 교환신청 화면
+	 * 비회원 교환신청 화면
 	 *
 	 * @param Order
 	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 02. 22
+	 * @since 2021. 05. 02
 	 */
 	@PostMapping("/exchange/form")
 	@ResponseBody
@@ -645,22 +639,8 @@ public class TsfNoMemberController extends TsfBaseController {
 		// 주문번호 설정
 		mav.addObject("ordNo", order.getOrdNo());
 
-		// 고객번호 설정
-		int custNo = TsfSession.getInfo().getCustNo();
-		order.setCustNo(custNo);
-		mav.addObject("custNo", custNo);
-
-		// 고객정보 조회
-		Customer customer = new Customer();
-		customer.setSiteCd(TscConstants.Site.STYLE24.value());
-		customer.setCustNo(custNo);
-		customer.setCustStat(TscConstants.CustStat.ACTIVE.value());
-		customer = coreCustomerService.getCustomerInfo(customer);
-
-		mav.addObject("customerInfo", customer);
-
 		// 로그인여부 설정
-		mav.addObject("isLogin", TsfSession.isLogin());
+		mav.addObject("isLogin", false);
 
 		// 교환 가능 리스트 조회
 		order.setChgGb(TscConstants.OrderChangeGb.EXCHANGE.value());
@@ -675,31 +655,24 @@ public class TsfNoMemberController extends TsfBaseController {
 		// 교환 사유 목록 조회
 		mav.addObject("exchangeReason", rendererService.getCommonCodeList("G689", "Y"));
 
-		mav.setViewName(super.getDeviceViewName("/mypage/MypageExchangeForm"));
+		mav.setViewName(super.getDeviceViewName("/mypage/NoMemberExchangeForm"));
 
 		return mav;
 	}
 
 	/**
-	 * 마이페이지 교환 옵션 변경 팝업
-	 *
+	 * 비회원 교환 옵션 변경 팝업
+	 * 
 	 * @param Order
 	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 03. 30
+	 * @since 2021. 05. 02
 	 */
 	@PostMapping("/change/option/popup/form")
 	@ResponseBody
 	public ModelAndView changeOptionPopupForm(OrderChange orderChange) {
 		ModelAndView mav = new ModelAndView();
 
-		// custNo 설정
-		if (TsfSession.isLogin()) {
-			orderChange.setCustNo(TsfSession.getInfo().getCustNo());
-		} else {
-			orderChange.setCustNo(0);
-		}
-
 		// 교환 옵션 정보 조회
 		Collection<OrderChange> exchangeOptionInfo = orderChangeService.getExchangeOptionInfo(orderChange);
 		mav.addObject("exchangeOptionInfo", exchangeOptionInfo);
@@ -718,7 +691,7 @@ public class TsfNoMemberController extends TsfBaseController {
 	 * @param OrderChange
 	 * @return GagaMap
 	 * @author card007
-	 * @since 2021. 04. 06
+	 * @since 2021. 05. 02
 	 */
 	@SuppressWarnings("unchecked")
 	@PostMapping("/exchange")
@@ -733,10 +706,9 @@ public class TsfNoMemberController extends TsfBaseController {
 			return result;
 		}
 
-		// 세션 고객번호 설정
-		int custNo = TsfSession.getInfo().getCustNo();
-		orderChange.setUpdNo(custNo);
-		orderChange.setRegNo(custNo);
+		// 고객번호 설정
+		orderChange.setUpdNo(0);
+		orderChange.setRegNo(0);
 
 		// 교환처리
 		result = coreOrderChangeService.exchReq(orderChange);
@@ -770,10 +742,9 @@ public class TsfNoMemberController extends TsfBaseController {
 		}
 
 		// 1. 교환요청철회 정보 설정
-		int custNo = TsfSession.isLogin() ? TsfSession.getInfo().getCustNo() : 0;
-		orderChange.setCustNo(custNo);
-		orderChange.setRegNo(custNo);
-		orderChange.setUpdNo(custNo);
+		orderChange.setCustNo(0);
+		orderChange.setRegNo(0);
+		orderChange.setUpdNo(0);
 
 		String ipAddress = TsfSession.getIpAddress();
 		orderChange.setIpAddress(ipAddress);
@@ -786,20 +757,19 @@ public class TsfNoMemberController extends TsfBaseController {
 	}
 
 	/**
-	 * 마이페이지 상태별 수량 조회
+	 * 비회원 상태별 수량 조회
 	 *
-	 * @return
+	 * @param Order
+	 * @return GagaMap
 	 * @author card007
-	 * @since 2021. 02. 25
+	 * @since 2021. 05. 02
 	 */
 	@PostMapping("/status/count")
 	@ResponseBody
-	public GagaMap fnReloadStatusCount() {
+	public GagaMap fnReloadStatusCount(@RequestBody Order order) {
 		GagaMap result = new GagaMap();
 
-		// 쿠폰정보 조회
-		Order order = new Order();
-		order.setCustNo(TsfSession.getInfo().getCustNo());
+		// 상태별 수량 조회
 		result.set("orderCount", coreOrderService.getOrderStatCount(order));
 
 		result.set("status", GagaResponseStatus.SUCCESS.getCode());
@@ -808,35 +778,37 @@ public class TsfNoMemberController extends TsfBaseController {
 	}
 
 	/**
-	 * 마이페이지 취반교 목록 화면
-	 *
-	 * @return
+	 * 비회원 취반교 목록 화면
+	 * 
+	 * @param Order
+	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 02. 04
+	 * @since 2021. 05. 02
 	 */
-	@GetMapping({"/cre/list/form"})
-	public ModelAndView mypageCreListForm() {
+	@PostMapping("/cre/list/form")
+	public ModelAndView mypageCreListForm(Order order) {
 		ModelAndView mav = new ModelAndView();
 
-		// 고객번호 설정
-		int custNo = TsfSession.getInfo().getCustNo();
-		mav.addObject("custNo", custNo);
+		// 주문 정보 설정
+		mav.addObject("ordNo", order.getOrdNo());
+		mav.addObject("ordNm", order.getOrdNm());
+		mav.addObject("ordPhnno", order.getOrdPhnno());
 
 		// 주문 상태 별 수량 조회
-		Order order = new Order();
-		order.setCustNo(custNo);
 		mav.addObject("orderCount", coreOrderService.getOrderStatCount(order));
 
 		// 2021.04.21 모바일에서 사용하려고 추가
 		OrderChange orderChange = new OrderChange();
-		orderChange.setCustNo(custNo);
+		orderChange.setOrdNo(order.getOrdNo());
+		orderChange.setOrdNm(order.getOrdNm());
+		orderChange.setOrdPhnno(order.getOrdPhnno());
 		int totalCnt = orderChangeService.getPagingCreListCount(orderChange);
 		mav.addObject("totalCnt", totalCnt);
 
 		// 주문상세상태코드 설정
 		mav.addObject("chgStatList", rendererService.getCommonCodeList("G685", "Y", new String[] {"G685_10", "G685_11", "G685_19"}));
 
-		mav.setViewName(super.getDeviceViewName("mypage/MypageCreListForm"));
+		mav.setViewName(super.getDeviceViewName("mypage/NoMemberCreListForm"));
 
 		return mav;
 	}
@@ -847,21 +819,14 @@ public class TsfNoMemberController extends TsfBaseController {
 	 * @param OrderChange
 	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 02. 18
+	 * @since 2021. 05. 02
 	 */
 	@PostMapping("/cre/list")
 	@ResponseBody
 	public GagaMap getCreList(@RequestBody OrderChange orderChange) {
 		GagaMap map = new GagaMap();
 
-		// 고객번호 설정
-		int custNo = 0;
-		if(TsfSession.isLogin()) {
-			custNo = TsfSession.getInfo().getCustNo();
-		}
-
 		// 페이징 처리 설정
-		orderChange.setCustNo(custNo);
 		TscPageRequest pageable = new TscPageRequest((orderChange.getPageNo() > 0 ? orderChange.getPageNo() - 1 : 0), orderChange.getPageSize(), orderChange.getPageUnit());
 		pageable.setTotalCount(orderChangeService.getPagingCreListCount(orderChange));
 		orderChange.setPageable(pageable);
@@ -885,21 +850,17 @@ public class TsfNoMemberController extends TsfBaseController {
 
 	/**
 	 * 마이페이지 취반교 취소 상세 화면
-	 *
+	 * 
+	 * @param OrderChange
 	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 04. 12
+	 * @since 2021. 05. 02
 	 */
-	@PostMapping({"/cre/cancel/detail/form"})
+	@PostMapping("/cre/cancel/detail/form")
 	public ModelAndView mypageCreCancelDetailForm(OrderChange orderChange) {
 		ModelAndView mav = new ModelAndView();
 
-		// 고객번호 설정
-		int custNo = TsfSession.getInfo().getCustNo();
-		mav.addObject("custNo", custNo);
-
 		// 취소상세 데이터 조회
-		orderChange.setCustNo(custNo);
 		GagaMap map = orderChangeService.getCreCancelDetailInfo(orderChange);
 		OrderChange oneData = (OrderChange) map.get("oneData");
 		mav.addObject("cancelDetailList", map);
@@ -911,31 +872,27 @@ public class TsfNoMemberController extends TsfBaseController {
 		order.setOrdNo(orderChange.getOrdNo());
 		mav.addObject("paymentInfo", orderService.getPaymentInfoForMypage(order));
 
-		mav.setViewName(super.getDeviceViewName("mypage/MypageCreCancelDetailForm"));
+		mav.setViewName(super.getDeviceViewName("mypage/NoMemberCreCancelDetailForm"));
 
 		return mav;
 	}
 
 	/**
 	 * 마이페이지 취반교 반품 상세 화면
-	 *
+	 * 
+	 * @param OrderChange
 	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 04. 13
+	 * @since 2021. 05. 02
 	 */
-	@PostMapping({"/cre/return/detail/form"})
+	@PostMapping("/cre/return/detail/form")
 	public ModelAndView mypageCreReturnDetailForm(OrderChange orderChange) {
 		ModelAndView mav = new ModelAndView();
 
-		// 고객번호 설정
-		int custNo = TsfSession.getInfo().getCustNo();
-		mav.addObject("custNo", custNo);
-
 		// 로그인여부 설정
-		mav.addObject("isLogin", TsfSession.isLogin());
+		mav.addObject("isLogin", false);
 
 		// 취소상세 데이터 조회
-		orderChange.setCustNo(custNo);
 		GagaMap map = orderChangeService.getCreReturnDetailInfo(orderChange);
 		OrderChange oneData = (OrderChange) map.get("oneData");
 		mav.addObject("returnDetailList", map);
@@ -946,37 +903,33 @@ public class TsfNoMemberController extends TsfBaseController {
 		order.setOrdNo(orderChange.getOrdNo());
 		mav.addObject("paymentInfo", orderService.getPaymentInfoForMypage(order));
 
-		mav.setViewName(super.getDeviceViewName("mypage/MypageCreReturnDetailForm"));
+		mav.setViewName(super.getDeviceViewName("mypage/NoMemberCreReturnDetailForm"));
 
 		return mav;
 	}
 
 	/**
 	 * 마이페이지 취반교 교환 상세 화면
-	 *
+	 * 
+	 * @param OrderChange
 	 * @return ModelAndView
 	 * @author card007
-	 * @since 2021. 04. 13
+	 * @since 2021. 05. 02
 	 */
-	@PostMapping({"/cre/exchange/detail/form"})
+	@PostMapping("/cre/exchange/detail/form")
 	public ModelAndView mypageCreExchangeDetailForm(OrderChange orderChange) {
 		ModelAndView mav = new ModelAndView();
 
-		// 고객번호 설정
-		int custNo = TsfSession.getInfo().getCustNo();
-		mav.addObject("custNo", custNo);
-
 		// 로그인여부 설정
-		mav.addObject("isLogin", TsfSession.isLogin());
+		mav.addObject("isLogin", false);
 
 		// 취소상세 데이터 조회
-		orderChange.setCustNo(custNo);
 		GagaMap map = orderChangeService.getCreExchangeDetailInfo(orderChange);
 		OrderChange oneData = (OrderChange) map.get("oneData");
 		mav.addObject("exchangeDetailList", map);
 		mav.addObject("oneData", oneData);
 
-		mav.setViewName(super.getDeviceViewName("mypage/MypageCreExchangeDetailForm"));
+		mav.setViewName(super.getDeviceViewName("mypage/NoMemberCreExchangeDetailForm"));
 
 		return mav;
 	}
@@ -984,8 +937,8 @@ public class TsfNoMemberController extends TsfBaseController {
 	/**
 	 * WMS 주문 취소 가능 여부 조회
 	 *
-	 * @param
-	 * @return
+	 * @param OrderChange
+	 * @return GagaMap
 	 * @author card007
 	 * @since 2021. 04. 22
 	 */

+ 34 - 12
src/main/java/com/style24/persistence/mybatis/shop/TsfOrderChange.xml

@@ -522,12 +522,13 @@
 		            ON R.ORD_CHG_SQ = OC.ORD_CHG_SQ
 		         WHERE O.DISP_YN = 'Y'
 		<choose>
-			<when test="custNo != null and custNo != ''">
+			<when test="custNo > 0">
 		           AND O.CUST_NO = #{custNo}
 			</when>
 			<otherwise>
 		           AND O.ORD_NO = #{ordNo}
-		           AND O.ORD_NM = #{orderNm}
+		           AND O.ORD_NM = #{ordNm}
+		           AND O.ORD_PHNNO = #{ordPhnno}
 			</otherwise>
 		</choose>
 		<if test="ordChgSq != null and ordChgSq != ''">
@@ -614,8 +615,17 @@
 		         INNER JOIN TB_BRAND B
 		            ON G1.BRAND_CD = B.BRAND_CD
 		           AND B.USE_YN = 'Y'
-		         WHERE O.CUST_NO = #{custNo}
-		           AND O.DISP_YN = 'Y'
+		         WHERE O.DISP_YN = 'Y'
+		<choose>
+			<when test="custNo > 0">
+		           AND O.CUST_NO = #{custNo}
+			</when>
+			<otherwise>
+		           AND O.ORD_NO = #{ordNo}
+		           AND O.ORD_NM = #{ordNm}
+		           AND O.ORD_PHNNO = #{ordPhnno}
+			</otherwise>
+		</choose>
 		<if test="stDate != null and stDate != '' and edDate != null and edDate != ''">
 		           AND OCD.REG_DT BETWEEN CONCAT(#{stDate}, ' 00:00:00') AND CONCAT(#{edDate}, ' 23:59:59')
 		</if>
@@ -687,8 +697,17 @@
 		 INNER JOIN TB_BRAND B
 		    ON G1.BRAND_CD = B.BRAND_CD
 		   AND B.USE_YN = 'Y'
-		 WHERE O.CUST_NO = #{custNo}
-		   AND O.DISP_YN = 'Y'
+		 WHERE O.DISP_YN = 'Y'
+		<choose>
+			<when test="custNo > 0">
+		   AND O.CUST_NO = #{custNo}
+			</when>
+			<otherwise>
+		   AND O.ORD_NO = #{ordNo}
+		   AND O.ORD_NM = #{ordNm}
+		   AND O.ORD_PHNNO = #{ordPhnno}
+			</otherwise>
+		</choose>
 		<if test="stDate != null and stDate != '' and edDate != null and edDate != ''">
 		   AND OCD.REG_DT BETWEEN CONCAT(#{stDate}, ' 00:00:00') AND CONCAT(#{edDate}, ' 23:59:59')
 		</if>
@@ -918,12 +937,13 @@
 		         WHERE OCD.DEL_YN = 'N'
 		           AND O.DISP_YN = 'Y'
 		<choose>
-			<when test="custNo != null and custNo != ''">
+			<when test="custNo > 0">
 		           AND O.CUST_NO = #{custNo}
 			</when>
 			<otherwise>
 		           AND O.ORD_NO = #{ordNo}
-		           AND O.ORD_NM = #{orderNm}
+		           AND O.ORD_NM = #{ordNm}
+		           AND O.ORD_PHNNO = #{ordPhnno}
 			</otherwise>
 		</choose>
 		<if test="ordChgSq != null and ordChgSq != ''">
@@ -1100,12 +1120,13 @@
 		           AND P.PAY_STAT = 'G016_30'
 		         WHERE O.DISP_YN = 'Y'
 		<choose>
-			<when test="custNo != null and custNo != ''">
+			<when test="custNo > 0">
 			       AND O.CUST_NO = #{custNo}
 			</when>
 			<otherwise>
 			       AND O.ORD_NO = #{ordNo}
-			       AND O.ORD_NM = #{orderNm}
+			       AND O.ORD_NM = #{ordNm}
+		           AND O.ORD_PHNNO = #{ordPhnno}
 			</otherwise>
 		</choose>
 		<if test="ordChgSq != null and ordChgSq != ''">
@@ -1282,12 +1303,13 @@
 		           AND P.PAY_STAT = 'G016_30'
 		         WHERE O.DISP_YN = 'Y'
 		<choose>
-			<when test="custNo != null and custNo != ''">
+			<when test="custNo > 0">
 			       AND O.CUST_NO = #{custNo}
 			</when>
 			<otherwise>
 			       AND O.ORD_NO = #{ordNo}
-			       AND O.ORD_NM = #{orderNm}
+			       AND O.ORD_NM = #{ordNm}
+		           AND O.ORD_PHNNO = #{ordPhnno}
 			</otherwise>
 		</choose>
 		<if test="ordChgSq != null and ordChgSq != ''">

+ 2 - 2
src/main/webapp/WEB-INF/views/mob/mypage/MypageCreExchangeDetailFormMob.html

@@ -104,11 +104,11 @@
 							<div><button type="button" class="btn btn_default" onclick="cfnGoToPage(_PAGE_ONETOONE_QNA_REG);"><span>1:1 문의</span></button></div>
 						</div>
 						<div class="goods_txt">
-							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_21' or (returnDtl.chgGb == 'G680_40' and returnDtl.chgStat == 'G685_32')}" th:text="|${returnDtl.addPayCost}원 결제 후 반품 가능합니다.|"></p>
+							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_21' or (returnDtl.chgGb == 'G680_40' and returnDtl.chgStat == 'G685_32')}" th:text="|${returnDtl.addPayCost}원 결제 후 교환 가능합니다.|"></p>
 							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_20'}">교환 신청이 접수 되었습니다.<br> 신속하게 처리하여 드리겠습니다.</p>
 							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_30'}">고객님이 요청하신 회수지로 상품을 회수 중에 있습니다.</p>
 							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_31' and returnDtl.chgGb == 'G680_40'}">고객님이 교환하신 상품을 검수 중에 있습니다.</p>
-							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_40'} and (returnDtl.chgOrdDtlStat == 'G013_60' or returnDtl.chgOrdDtlStat == 'G013_70')}">교환이 완료되었습니다.</p>
+							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_40' and (returnDtl.chgOrdDtlStat == 'G013_60' or returnDtl.chgOrdDtlStat == 'G013_70')}">교환이 완료되었습니다.</p>
 							<p class="cf_txt cf_desc" th:if="${returnDtl.chgStat == 'G685_49'}">요청하신 교환을 취소하였습니다.</p>
 						</div>
 					</div>

+ 4 - 0
src/main/webapp/WEB-INF/views/web/common/layout/NoMemberLayoutWeb.html

@@ -61,6 +61,10 @@
 			<input type="hidden" name="ordDtlNo"/>
 			<input type="hidden" name="delvFeeCd"/>
 		</form>
+		<form id="addPaymentForm" name="addPaymentForm" th:action="@{'/order/addPaymentForm'}" th:method="post">
+			<input type="hidden" name="ordNo"/>
+			<input type="hidden" name="ordChgSq"/>
+		</form>
 	</div>
 </div>
 

+ 1 - 1
src/main/webapp/WEB-INF/views/web/mypage/MypageCreListFormWeb.html

@@ -444,7 +444,7 @@
 					tag += '										</div>\n';
 					tag += '										<div class="button_box">\n';
 					if (cre.chgStat == 'G685_20' || cre.chgStat == 'G685_21' || cre.chgStat == 'G685_50' || cre.chgStat == 'G685_51') {
-						//tag += '											<p><button type="button" class="btn btn_default btn_sm" ordNo="' + cre.ordNo + '" ordChgSq="' + cre.ordChgSq + '" cancelGb="' + cre.chgGb + '" onclick="fnCreCancel(this);"><span>신청취소</span></button></p>\n';
+						tag += '											<p><button type="button" class="btn btn_default btn_sm" ordNo="' + cre.ordNo + '" ordChgSq="' + cre.ordChgSq + '" cancelGb="' + cre.chgGb + '" onclick="fnCreCancel(this);"><span>신청취소</span></button></p>\n';
 					}
 					if (cre.chgStat == 'G685_21' || cre.chgStat == 'G685_51' || cre.chgStat == 'G685_32') {
 						tag += '											<p><button type="button" class="btn btn_default btn_sm" ordNo="' + cre.ordNo + '" ordChgSq="' + cre.ordChgSq + '" onclick="fnCrePayAddCost(this);"><span>결제하기</span></button></p>\n';

+ 577 - 0
src/main/webapp/WEB-INF/views/web/mypage/NoMemberCreListFormWeb.html

@@ -0,0 +1,577 @@
+<!DOCTYPE html>
+<html lang="ko"
+	xmlns:th="http://www.thymeleaf.org"
+	xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
+	layout:decorator="web/common/layout/MypageLayoutWeb">
+<!--
+ *******************************************************************************
+ * @source  : NoMemberCreListFormWeb.html
+ * @desc    : 비회원 > 취소/반품/교환내역 Page
+ *============================================================================
+ * STYLE24
+ * Copyright(C) 2021 TSIT, All rights reserved.
+ *============================================================================
+ * VER  DATE         AUTHOR      DESCRIPTION
+ * ===  ===========  ==========  =============================================
+ * 1.0  2021.05.02   card007     최초 작성
+ *******************************************************************************
+ -->
+<body>
+
+<th:block layout:fragment="content">
+	<div class="content myOrderList"> <!-- 페이지특정 클래스 = myOrderList -->
+		<div class="cont_body">
+			<!-- CONT-BODY -->
+			<div class="lnb">
+				<div class="lnb_tit">
+					<h2>마이페이지</h2>
+				</div>
+				<div class="lnb_list">
+					<ul id="mypageLnbList"></ul>
+				</div>
+			</div>
+			<div class="cont">
+				<div class="sec_head">
+					<!-- 주문 현황 -->
+					<div class="my_order_progress">
+						<div class="progress">
+							<ul>
+								<li>
+									<div>
+										<p class="txt">주문접수</p>
+										<p class="count"><span id="orderReceiptCount" th:text="${orderCount.depositWaitingCount}">0</span></p>
+									</div>
+								</li>
+								<li>
+									<div>
+										<p class="txt">결제완료</p>
+										<p class="count"><span id="paymentCompleteCount" th:text="${orderCount.paymentCompleteCount}">0</span></p>
+									</div>
+								</li>
+								<li>
+									<div>
+										<p class="txt">상품 준비 중</p>
+										<p class="count"><span id="goodsPrepareCount" th:text="${orderCount.goodsPrepareCount}">0</span></p>
+									</div>
+								</li>
+								<li>
+									<div>
+										<p class="txt">배송 준비 중</p>
+										<p class="count"><span id="shipPrepareCount" th:text="${orderCount.shipPrepareCount}">0</span></p>
+									</div>
+								</li>
+								<li>
+									<div>
+										<p class="txt">배송 중</p>
+										<p class="count"><span id="shippingCount" th:text="${orderCount.shippingCount}">0</span></p>
+									</div>
+								</li>
+								<li>
+									<div>
+										<p class="txt">배송 완료</p>
+										<p class="count"><span id="shipCompleteCount" th:text="${orderCount.shipCompleteCount}">0</span></p>
+									</div>
+								</li>
+							</ul>
+						</div>
+						<div class="invalid">
+							<p class="txt">취소/교환/반품</p>
+							<p class="count"><span id="orderCreCount" th:text="${orderCount.cancelCount + orderCount.returnCount + orderCount.exchangeCount + orderCount.confirmCount}">0</span></p>
+						</div>
+					</div>
+					<!-- //주문 현황 -->
+				</div>
+				<div class="sec_body">
+					<h3 class="subH2">취소/반품/교환 내역</h3>
+					<!-- 주문조회 검색 -->
+					<div class="area_filter">
+						<div class="select_month_box">
+							<div class="form_field">
+								<div>
+									<input type="radio" name="rdi-month" id="rdi-month1" onclick="fnSetSearchPeriod(1);">
+									<label for="rdi-month1"><span>최근 1개월</span></label>
+								</div>
+								<div>
+									<input type="radio" name="rdi-month" id="rdi-month2" onclick="fnSetSearchPeriod(3);">
+									<label for="rdi-month2"><span>최근 3개월</span></label>
+								</div>
+								<div>
+									<input type="radio" name="rdi-month" id="rdi-month3" onclick="fnSetSearchPeriod(6);">
+									<label for="rdi-month3"><span>최근 6개월</span></label>
+								</div>
+							</div>
+						</div>
+						<div class="select_period_box">
+							<form class="form_wrap">
+								<div class="form_field">
+									<label class="input_label sr-only">선택기간 시작</label>
+									<div class="input_wrap">
+										<input type="text" class="form_control period_datepicker" value="" id="stDate" onchange="fnCheckPeriod(this);">
+									</div>
+								</div>
+								<div class="form_field">
+									<label class="input_label sr-only">선택기간 끝</label>
+									<div class="input_wrap">
+										<input type="text" class="form_control n_input period_datepicker" value="" id="edDate" onchange="fnCheckPeriod(this);">
+									</div>
+								</div>
+								<button type="button" class="btn btn_dark btn_sm" onclick="fnSearchCreList();"><span>조회</span></button>
+							</form>
+						</div>
+						<div class="select_status_box">
+							<form class="form_wrap">
+								<div class="form_field">
+									<div class="select_custom demand_status">
+										<div class="combo">
+											<div class="select">전체상태</div>
+											<ul class="list">
+												<!-- 선택처리 class="selected" / 선택불가 aria-disabled="true" 추가  -->
+												<li class="selected" code="">전체상태</li>
+												<li code="G685_91">결제대기</li>
+												<li code="G685_20">교환접수</li>
+												<li code="G685_50">반품접수</li>
+												<li code="G685_30">회수요청</li>
+												<li code="G685_31">상품 검수중</li>
+												<li code="G685_34">교환 진행중</li>
+												<li code="G685_33">환불 진행중</li>
+												<li code="G685_40">교환완료</li>
+												<li code="G685_60">반품완료</li>
+												<li code="G685_92">접수취소</li>
+												<li code="G685_93">주문취소</li>
+												<li code="G685_94">품절취소</li>
+<!--												<li th:if="${chgStatList}" th:each="oneData, status : ${chgStatList}" th:attr="code=${oneData.cd}" th:text="${oneData.cdNm}"></li>-->
+											</ul>
+										</div>
+									</div>
+								</div>
+							</form>
+						</div>
+					</div>
+					<!-- //주문조회 검색 -->
+					<div class="area_list" id="creList"></div>
+				</div>
+				<div class="sec_foot">
+					<div class="ui_row">
+						<ul class="pageNav" id="paging"></ul>
+					</div>
+				</div>
+				<form id="searchForm" name="searchForm" th:action="@{'/noMember/cre/list'}" th:method="post">
+					<input type="hidden" name="pageNo" value=1 />
+					<input type="hidden" name="pageSize" value=5 />
+					<input type="hidden" name="pageUnit" value=10 />
+					<input type="hidden" name="chgStat" value="" />
+					<input type="hidden" name="stDate" value="" />
+					<input type="hidden" name="edDate" value="" />
+					<input type="hidden" name="ordNo" th:value="${ordNo}" />
+					<input type="hidden" name="ordNm" th:value="${ordNm}" />
+					<input type="hidden" name="ordPhnno" th:value="${ordPhnno}" />
+				</form>
+				<form id="exchangeForm" name="exchangeForm" action="#" th:action="@{'/noMember/cre/exchange/detail/form'}" th:method="post">
+					<input type="hidden" name="ordChgSq"/>
+					<input type="hidden" name="ordNo"/>
+				</form>
+				<form id="returnForm" name="returnForm" action="#" th:action="@{'/noMember/cre/return/detail/form'}" th:method="post">
+					<input type="hidden" name="ordChgSq"/>
+					<input type="hidden" name="ordNo"/>
+				</form>
+				<form id="cancelForm" name="cancelForm" th:action="@{'/noMember/cre/cancel/detail/form'}" th:method="post">
+					<input type="hidden" name="ordChgSq"/>
+					<input type="hidden" name="ordNo"/>
+				</form>
+			</div>
+			<!-- // CONT-BODY -->
+		</div>
+	</div>
+<script src="/ux/plugins/gaga/gaga.paging.js"></script>
+<script th:inline="javascript">
+	/*<![CDATA[*/
+	let totalCount = 0;
+	let pageSize = 0;
+
+	$(document).ready(function() {
+		// 마이페이지 LNB 설정
+		fnSetNoMemberLnbList(2);
+		
+		// 마이페이지 location 설정
+		fnSetNoMemberLocation('취소/반품/교환내역');
+		
+		// datepicker 설정
+		$('.period_datepicker').datepicker();
+
+		// 셀렉트박스 활성화
+		$('.select_custom.demand_status').each(function(index) {
+			new sCombo($(this));
+		});
+
+		// 주문 검색 기간 설정
+		$('#rdi-month2').click();
+
+		// Initialize a pagination
+		gagaPaging.init('searchForm', fnSearchCallback, 'paging', 5, 10);
+		
+		// Load data
+		gagaPaging.load(1);
+	});
+	
+	// 검색기간 버튼 클릭 이벤트 처리
+	var fnSetSearchPeriod = function(period) {
+		let date = new Date();
+		let edDate = date.getFullYear() + '-' + ('0' + (date.getMonth() + 1)).slice(-2) + '-' + ('0' + (date.getDate())).slice(-2);
+		date.setMonth(date.getMonth() - period);
+		let stDate = date.getFullYear() + '-' + ('0' + (date.getMonth() + 1)).slice(-2) + '-' + ('0' + (date.getDate())).slice(-2);
+
+		$('#edDate').val(edDate);
+		$('#searchForm input[name=edDate]').val(edDate);
+		$('#stDate').val(stDate);
+		$('#searchForm input[name=stDate]').val(stDate);
+	}
+
+	// 주문 목록 조회
+	var fnSearchCreList = function() {
+		gagaPaging.load(1);
+	}
+
+	// 주문 목록 조회 콜백
+	var fnSearchCallback = function(result) {
+		$('#creList').html(fnCreateCreList(result));
+
+		// Create pagination
+		gagaPaging.createPagination(result.creInfo.pageable);
+	}
+
+	// 검색기간 설정 체크
+	var fnCheckPeriod = function(param) {
+		let id = $(param).attr('id');
+		let stDate = $('#stDate').val();
+		let edDate = $('#edDate').val();
+		let chgDate;
+
+		$('#searchForm input[name=stDate]').val(stDate);
+		$('#searchForm input[name=edDate]').val(edDate);
+
+		let sdt = new Date(stDate);
+		let edt = new Date(edDate);
+		let today = new Date();
+
+		// 검색기간 버튼 처리
+		$.each($('.select_month_box input:radio'), function(idx, item) {
+			if ($(item).is(':checked')) {
+				$(item).prop('checked', false);
+			}
+		});
+
+		// 오늘 이후 날짜 선택 처리
+		chgDate = today.getFullYear() + '-' + ('0' + (today.getMonth() + 1)).slice(-2) + '-' + ('0' + (today.getDate())).slice(-2);
+		if (id == 'stDate' && Math.ceil((sdt.getTime() - today.getTime()) / (1000 * 3600 * 24))) {
+			mcxDialog.alert('조회기간을 확인해주세요.');
+			$('#stDate').val(chgDate);
+			$('#searchForm input[name=stDate]').val(chgDate);
+
+			return false;
+		} else if (id == 'edDate' && Math.ceil((edt.getTime() - today.getTime()) / (1000 * 3600 * 24))) {
+			mcxDialog.alert('조회기간을 확인해주세요.');
+			$('#edDate').val(chgDate);
+			$('#searchForm input[name=edDate]').val(chgDate);
+
+			return false;
+		}
+
+		// 시작 종료일자 확인
+		if (sdt > edt) {
+			mcxDialog.alert('조회기간을 확인해주세요.');
+
+			if (id == 'stDate') {
+				chgDate = sdt.getFullYear() + '-' + ('0' + (sdt.getMonth() + 1)).slice(-2) + '-' + ('0' + (sdt.getDate())).slice(-2);
+			} else {
+				chgDate = edt.getFullYear() + '-' + ('0' + (edt.getMonth() + 1)).slice(-2) + '-' + ('0' + (edt.getDate())).slice(-2);
+			}
+
+			$('#stDate').val(chgDate);
+			$('#edDate').val(chgDate);
+			$('#searchForm input[name=stDate]').val(chgDate);
+			$('#searchForm input[name=edDate]').val(chgDate);
+
+			return false;
+		}
+
+		// 기간 1년 확인
+		let dateDiff = Math.ceil((edt.getTime() - sdt.getTime()) / (1000 * 3600 * 24));
+
+		if (dateDiff > 366) {
+			mcxDialog.alert('조회기간은 최대 1년을 넘을 수 없습니다.');
+			if (id == 'stDate') {
+				sdt.setFullYear(sdt.getFullYear() + 1);
+				let chgEdDate = sdt.getFullYear() + '-' + ('0' + (sdt.getMonth() + 1)).slice(-2) + '-' + ('0' + (sdt.getDate())).slice(-2);
+
+				$('#edDate').val(chgEdDate);
+				$('#searchForm input[name=edDate]').val(chgEdDate);
+			} else {
+				edt.setFullYear(edt.getFullYear() - 1);
+				let chgStDate = edt.getFullYear() + '-' + ('0' + (edt.getMonth() + 1)).slice(-2) + '-' + ('0' + (edt.getDate())).slice(-2);
+
+				$('#stDate').val(chgStDate);
+				$('#searchForm input[name=stDate]').val(chgStDate);
+			}
+
+			return false;
+		}
+	}
+
+	// 상태값 별 수량 업데이트 처리
+	var fnReloadStatusCount = function() {
+		let url = '/noMember/status/count';
+		
+		let data = {};
+
+		let jsonData = JSON.stringify(data);
+		
+		gagajf.ajaxJsonSubmit(url, jsonData, function(result) {
+			$('#orderReceiptCount').text(result.orderCount.orderReceiptCount);
+			$('#paymentCompleteCount').text(result.orderCount.paymentCompleteCount);
+			$('#goodsPrepareCount').text(result.orderCount.goodsPrepareCount);
+			$('#shipPrepareCount').text(result.orderCount.shipPrepareCount);
+			$('#shippingCount').text(result.orderCount.shippingCount);
+			$('#shipCompleteCount').text(result.orderCount.shipCompleteCount);
+			$('#orderCreCount').text(result.orderCount.cancelCount + result.orderCount.returnCount + result.orderCount.exchangeCount);
+		});
+	}
+
+	// 주문상세상태코드 셀렉트박스 변경 이벤트
+	$('.select_custom.demand_status').find('li').on('click', function() {
+		$('#searchForm input[name=chgStat]').val($(this).attr('code'));
+	});
+
+	// 주문내역 리스트 처리
+	var fnCreateCreList = function(param) {
+		let tag = '';
+		let imageUrl = [[${@environment.getProperty('upload.goods.view')}]];
+
+		if (param.creList != null && param.creList.length > 0) {
+			$.each(param.creList, function (idx, creList) {
+				tag += '						<div class="part_goods">\n';
+				tag += '							<div class="goods_head">\n';
+				tag += '								<p>주문일 <span>' + creList.ordDt + '</span></p>\n';
+				tag += '								<a href="javascript:void(0)" ordChgSq="' + creList.ordChgSq + '" chgGb="' + creList.oneData.chgGb + '" ordNo ="' + creList.oneData.ordNo + '" onclick="fnGoToCreDetail(this)">상세보기</a>\n';
+				tag += '							</div>\n';
+				tag += '							<div class="goods_cont">\n';
+				$.each(creList.creList, function (index, cre) {
+					tag += '								<!-- 주문상품1 -->\n';
+					tag += '								<div class="goods_info">\n';
+					tag += '									<div class="order_desc">\n';
+					tag += '										<div class="goods_box">\n';
+					tag += '											<div class="gd_item">\n';
+					tag += '												<a href="javascript:void(0)" goodsCd="' + cre.goodsCd + '" onclick="fnGoToGoodsDetail(this)">\n';
+					tag += '													<span class="thumb">\n';
+					tag += '														<img src="' + imageUrl + '/' + cre.sysImgNm + '" width="100%" alt="">\n';
+					tag += '													</span>\n';
+					tag += '													<p>\n';
+					tag += '														<span class="brand">' + cre.brandNm + '</span>\n';
+					// 배송 아이콘 처리
+					if (cre.shotDelvYn == 'Y') {
+						tag += '														<span class="tag primary">총알배송</span>\n';
+					} else if (cre.selfGoodsYn == 'Y') {
+						tag += '														<span class="tag">STYLE24 일반배송</span>\n';
+					} else {
+						tag += '														<span class="tag">업체직배송</span>\n';
+					}
+					tag += '													</p>\n';
+					tag += '													<p>\n';
+					tag += '														<span class="name">' + cre.goodsNm + '</span>\n';
+					tag += '													</p>\n';
+					tag += '												</a>\n';
+					tag += '											</div>\n';
+					tag += '											<div class="gd_opt">\n';
+					tag += '												<div class="option_wrap">\n';
+					tag += '													<span class="title sr-only">주문 옵션</span>\n';
+					// 세트아이템 옵션 처리
+					if (cre.goodsType == 'G056_S') {
+						$.each(cre.colorNmArr, function (index2, option) {
+							tag += '													<span class="option">' + cre.itemNmArr[index2] + ' / ' + option + ' / ' + cre.optCd2Arr[index2] + '</span>\n';
+						});
+					} else {
+						tag += '													<span class="option">' + cre.colorNm + ' / ' + cre.optCd2 + '</span>\n';
+					}
+					tag += '												</div>\n';
+					tag += '											</div>\n';
+					tag += '											<div class="gd_opt">\n';
+					tag += '												<div class="option_wrap">\n';
+					// 교환옵션
+					if (cre.chgGb == 'G680_40') {
+						$.each(creList.exchangeOptionList, function(index, exchange) {
+							if (cre.chgOrdDtlNo == exchange.ordDtlNo) {
+								tag += '													<span class="title">교환 옵션</span>';
+								if (cre.goodsType == 'G056_S') {
+									$.each(exchange.colorNmArr, function (index2, option) {
+										tag += '													<span class="option">' + exchange.itemNmArr[index2] + ' / ' + option + ' / ' + exchange.optCd2Arr[index2] + '</span>\n';
+									});
+								} else {
+									tag += '													<span class="option">' + exchange.colorNm + ' / ' + exchange.optCd2 + '</span>\n';
+								}
+							}
+						});
+					}
+					tag += '												</div>\n';
+					tag += '											</div>\n';
+					tag += '											<div class="gd_calc">\n';
+					tag += '												<p>\n';
+					tag += '													<span class="count"><em>' + cre.chgQty + '</em>개</span>\n';
+					tag += '												</p>\n';
+					tag += '											</div>\n';
+					tag += '										</div>\n';
+					tag += '										<div class="status_box">\n';
+					tag += '											<p>\n';
+					if (cre.chgStat == 'G685_17' || cre.chgStat == 'G685_18') {
+						tag += '												주문취소\n';
+					} else if (cre.chgStat == 'G685_40') {
+						$.each(creList.exchangeOptionList, function(index, exchange) {
+							if (cre.chgOrdDtlNo == exchange.ordDtlNo && (exchange.ordDtlStat == 'G013_20' || exchange.ordDtlStat == 'G013_30' || exchange.ordDtlStat == 'G013_35' || exchange.ordDtlStat == 'G013_40' || exchange.ordDtlStat == 'G013_50')) {
+								tag += '												교환진행중\n';
+							} else if (cre.chgOrdDtlNo == exchange.ordDtlNo && (exchange.ordDtlStat == 'G013_60' || exchange.ordDtlStat == 'G013_70')) {
+								tag += '												교환완료\n';
+							}
+						});
+					} else if (cre.chgStat == 'G685_33') {
+						tag += '												환불진행중\n';
+					} else if (cre.chgStat == 'G685_49' || cre.chgStat == 'G685_69') {
+						tag += '												접수취소\n';
+					} else {
+						tag += '												' + cre.chgStatNm + '\n';
+					}
+					tag += '												<span class="date">' + cre.chgDate + '</span>\n';
+					tag += '												<span class="time">' + cre.chgTime + '</span>\n';
+					tag += '											</p>\n';
+					tag += '										</div>\n';
+					tag += '										<div class="button_box">\n';
+					if (cre.chgStat == 'G685_20' || cre.chgStat == 'G685_21' || cre.chgStat == 'G685_50' || cre.chgStat == 'G685_51') {
+						tag += '											<p><button type="button" class="btn btn_default btn_sm" ordNo="' + cre.ordNo + '" ordChgSq="' + cre.ordChgSq + '" cancelGb="' + cre.chgGb + '" onclick="fnCreCancel(this);"><span>신청취소</span></button></p>\n';
+					}
+					if (cre.chgStat == 'G685_21' || cre.chgStat == 'G685_51' || cre.chgStat == 'G685_32') {
+						tag += '											<p><button type="button" class="btn btn_default btn_sm" ordNo="' + cre.ordNo + '" ordChgSq="' + cre.ordChgSq + '" onclick="fnCrePayAddCost(this);"><span>결제하기</span></button></p>\n';
+					}
+					if (cre.chgStat == 'G685_40') {
+						$.each(creList.exchangeOptionList, function(index, exchange) {
+							if (cre.chgOrdDtlNo == exchange.ordDtlNo && (exchange.ordDtlStat == 'G013_20' || exchange.ordDtlStat == 'G013_30' || exchange.ordDtlStat == 'G013_35' || exchange.ordDtlStat == 'G013_40' || exchange.ordDtlStat == 'G013_50')) {
+								tag += '											<p><button type="button" class="btn btn_default btn_sm" ordDtlNo="' + cre.ordDtlNo + '" onclick="fnGoToDeliveryTrack(this);"><span>배송조회</span></button></p>\n';
+							}
+						});
+					}
+					tag += '										</div>\n';
+					tag += '									</div>\n';
+					//if (cre.chgStat == 'G685_10') {
+					//	tag += '									<div class="order_text"><p>' + cre.addPayCost + '원 결제 후 취소 가능합니다.</p></div>\n';
+					//}
+					// cre.chgGb == 'G680_30' : 반품
+					// cre.chgGb == 'G680_40' : 교환
+					// 교환접수
+					if (cre.chgStat == 'G685_20') {
+						tag += '									<div class="order_text"><p>교환 신청이 접수 되었습니다. 신속하게 처리하여 드리겠습니다.</p></div>\n';
+					}
+					// 교환대기
+					if (cre.chgStat == 'G685_21') {
+						tag += '									<div class="order_text"><p>' + cre.addPayCost.addComma() + '원 결제 후 교환 가능합니다.</p></div>\n';
+					}
+					// 회수요청
+					if (cre.chgStat == 'G685_30') {
+						tag += '									<div class="order_text"><p>고객님이 요청하신 회수지로 상품을 회수 중에 있습니다.</p></div>\n';
+					}
+					// 상품 검수중(교환)
+					if (cre.chgStat == 'G685_31' && cre.chgGb == 'G680_40') {
+						tag += '									<div class="order_text"><p>고객님이 교환하신 상품을 검수 중에 있습니다.</p></div>\n';
+					}
+					// 결제대기(교환)
+					if (cre.chgStat == 'G685_32' && cre.chgGb == 'G680_40') {
+						tag += '									<div class="order_text"><p>' + cre.addPayCost.addComma() + '원 결제 후 교환 가능합니다.</p></div>\n';
+					}
+					// 교환완료
+					if (cre.chgStat == 'G685_40') {
+						$.each(creList.exchangeOptionList, function(index, exchange) {
+							if (cre.chgOrdDtlNo == exchange.ordDtlNo && (exchange.ordDtlStat == 'G013_60' || exchange.ordDtlStat == 'G013_70')) {
+								tag += '									<div class="order_text"><p>교환이 완료되었습니다.</p></div>\n';
+							}
+						});
+					}
+					// 교환철회
+					if (cre.chgStat == 'G685_49') {
+						tag += '									<div class="order_text"><p>요청하신 교환을 취소하였습니다.</p></div>\n';
+					}
+					// 반품접수
+					if (cre.chgStat == 'G685_50') {
+						tag += '									<div class="order_text"><p>반품 신청이 접수 되었습니다. 신속하게 처리하여 드리겠습니다.</p></div>\n';
+					}
+					// 반품대기
+					if (cre.chgStat == 'G685_51') {
+						tag += '									<div class="order_text"><p>' + cre.addPayCost.addComma() + '원 결제 후 반품 가능합니다.</p></div>\n';
+					}
+					// 상품 검수중(반품)
+					if (cre.chgStat == 'G685_31' && cre.chgGb == 'G680_30') {
+						tag += '									<div class="order_text"><p>고객님이 반품하신 상품을 검수 중에 있습니다.</p></div>\n';
+					}
+					// 결제대기(반품)
+					if (cre.chgStat == 'G685_32' && cre.chgGb == 'G680_30') {
+						tag += '									<div class="order_text"><p>' + cre.addPayCost.addComma() + '원 결제 후 반품 가능합니다.</p></div>\n';
+					}
+					// 환불진행중
+					if (cre.chgStat == 'G685_33') {
+						tag += '									<div class="order_text"><p>환불을 진행하고 있습니다.(영업일 최대 3일 내 환불 예정)</p></div>\n';
+					}
+					// 반품완료
+					if (cre.chgStat == 'G685_60') {
+						tag += '									<div class="order_text"><p>반품이 완료되었습니다.</p></div>\n';
+					}
+					// 반품철회
+					if (cre.chgStat == 'G685_69') {
+						tag += '									<div class="order_text"><p>요청하신 반품을 취소하였습니다.</p></div>\n';
+					}
+					tag += '								</div>\n';
+				});
+				tag += '							</div>\n';
+				tag += '						</div>\n';
+			});
+		} else {
+			// 데이터 없음 표시
+			tag += '						<div class="nodata">';
+			tag += '							<div class="txt_box">';
+			tag += '								<p>';
+			tag += '									취소/반품/교환내역이 없습니다.<br>';
+			tag += '								</p>';
+			tag += '							</div>';
+			tag += '						</div>';
+		}
+
+		return tag;
+	}
+	
+	// 취반교 상세 페이지 이동
+	var fnGoToCreDetail = function(param) {
+		let ordChgSq = $(param).attr('ordChgSq');
+		let chgGb = $(param).attr('chgGb');
+		let ordNo = $(param).attr('ordNo');
+		
+		if (chgGb == 'G680_20') {
+			$('#cancelForm input[name=ordChgSq]').val(ordChgSq);
+			$('#cancelForm input[name=ordNo]').val(ordNo);
+			document.cancelForm.submit();
+		} else if (chgGb == 'G680_30') {
+			$('#returnForm input[name=ordChgSq]').val(ordChgSq);
+			$('#returnForm input[name=ordNo]').val(ordNo);
+			document.returnForm.submit();
+		} else if (chgGb == 'G680_40') {
+			$('#exchangeForm input[name=ordChgSq]').val(ordChgSq);
+			$('#exchangeForm input[name=ordNo]').val(ordNo);
+			document.exchangeForm.submit();
+		}
+	}
+	
+	// 취반교 배송조회 버튼 클릭 이벤트
+	var fnGoToDeliveryTrack = function(param) {
+		let ordDtlNo = $(param).attr('ordDtlNo');
+		// TODO
+		// 최반교 배송조회 페이지 이동 처리
+	}
+/*]]>*/
+</script>
+
+</th:block>
+
+</body>
+</html>

+ 647 - 0
src/main/webapp/WEB-INF/views/web/mypage/NoMemberExchangeFormWeb.html

@@ -0,0 +1,647 @@
+<!DOCTYPE html>
+<html lang="ko"
+	xmlns:th="http://www.thymeleaf.org"
+	xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
+	layout:decorator="web/common/layout/NoMemberLayoutWeb">
+<!--
+ *******************************************************************************
+ * @source  : NoMemberExchangeFormWeb.html
+ * @desc    : 비회원 > 교환신청 Page
+ *============================================================================
+ * STYLE24
+ * Copyright(C) 2021 TSIT, All rights reserved.
+ *============================================================================
+ * VER  DATE         AUTHOR      DESCRIPTION
+ * ===  ===========  ==========  =============================================
+ * 1.0  2021.05.02   card007     최초 작성
+ *******************************************************************************
+ -->
+<body>
+
+<th:block layout:fragment="content">
+	<div class="content myOrderView"> <!-- 페이지특정 클래스 = myOrderView -->
+		<div class="cont_body">
+			<!-- CONT-BODY -->
+			<div class="lnb">
+				<div class="lnb_tit">
+					<h2>마이페이지</h2>
+				</div>
+				<div class="lnb_list">
+					<ul id="mypageLnbList"></ul>
+				</div>
+			</div>
+			<div class="cont">
+				<form id="exchangeForm">
+					<div class="sec_head">
+						<h3 class="subH1">교환 신청</h3>
+						<span class="order_number">주문번호&nbsp;:&nbsp;<em th:text="${oneData.ordNo}"></em></span>
+					</div>
+					<div class="sec_body">
+						<div class="part_goods">
+							<div class="goods_head">
+								<p>주문일 <span th:text="${oneData.ordDt}"></span></p>
+							</div>
+							<div class="goods_cont">
+								<th:block th:if="${exchangeList.returnList}" th:each="exchange, status : ${exchangeList.returnList}" th:with="imageUrl=${@environment.getProperty('upload.goods.view')}">
+								<!-- 주문상품 -->
+								<div class="goods_info">
+									<div class="order_desc">
+										<div class="goods_box">
+											<div class="gd_item">
+												<a href="javascript:void(0)" th:attr="goodsCd=${exchange.goodsCd}" onclick="fnGoToGoodsDetail(this)">
+													<span class="thumb">
+														<img th:src="${imageUrl + '/' + exchange.sysImgNm}" width="100%" alt="">
+													</span>
+													<p>
+														<span class="brand" th:text="${exchange.brandNm}"></span>
+														<span class="tag primary" th:if="${exchange.shotDelvYn == 'Y'}">총알배송</span>
+														<span class="tag" th:if="${exchange.shotDelvYn == 'N' and exchange.selfGoodsYn == 'Y'}">STYLE24 일반배송</span>
+														<span class="tag" th:if="${exchange.selfGoodsYn == 'N'}">업체직배송</span>
+													</p>
+													<p>
+														<span class="name" th:text="${exchange.goodsNm}"></span>
+													</p>
+												</a>
+											</div>
+											<div class="gd_opt">
+												<div class="option_wrap">
+													<span class="title sr-only">주문 옵션</span>
+													<span class="option" th:if="${exchange.goodsType == 'G056_S'}" th:each="option, status : ${exchange.colorNmArr}" th:text="|${exchange.itemNmArr[status.index]} / ${option} / ${exchange.optCd2Arr[status.index]}|"></span>
+													<span class="option" th:unless="${exchange.goodsType == 'G056_S'}" th:text="|${exchange.colorNm} / ${exchange.optCd2}|"></span>
+												</div>
+											</div>
+											<div class="gd_calc">
+												<p>
+													<span class="count"><em th:text="${exchange.ordQty - exchange.cnclRtnQty}"></em>개</span>
+												</p>
+												<p>
+													<span class="price_org" th:if="${(exchange.ordAmt - exchange.cnclRtnAmt - exchange.cpn1DcAmt) > (exchange.realOrdAmt + exchange.pntDcAmt + exchange.gfcdUseAmt)}"><em th:text="${#numbers.formatInteger(exchange.ordAmt - exchange.cnclRtnAmt - exchange.cpn1DcAmt, 1, 'COMMA')}"></em>원</span>
+													<span class="price_sale"><em th:text="${#numbers.formatInteger(exchange.realOrdAmt + exchange.pntDcAmt + exchange.gfcdUseAmt, 1, 'COMMA')}"></em>원</span>
+												</p>
+											</div>
+											<div class="gd_opt exchangeOption" style="display:none" th:attr="ordDtlNo=${exchange.ordDtlNo}">
+												<div class="option_wrap"></div>
+											</div>
+										</div>
+										<div class="button_box">
+											<div class="count_modify">
+												<span class="txt">수량</span>
+												<form class="form_wrap">
+													<div class="form_field">
+														<div class="select_custom select_count">
+															<div class="combo">
+																<input type="hidden" name="chgQty" value="0" th:attr="ordDtlNo=${exchange.ordDtlNo}, ordCanChgQty=${exchange.ordCanChgQty}"/>
+																<input type="hidden" name="chgOptionList" th:attr="ordDtlNo=${exchange.ordDtlNo}"/>
+																<div class="select">선택</div>
+																<ul class="list">
+																	<!-- 선택처리 class="selected" / 선택불가 aria-disabled="true" 추가  -->
+																	<li class="selected" qty="0" th:attr="ordDtlNo=${exchange.ordDtlNo}" onclick="fnChangeExchangeQty(this);">선택</li>
+																	<li th:if="${exchange.ordCanChgQty > 0}" th:each="num : ${#numbers.sequence(1,exchange.ordCanChgQty)}" th:attr="qty=${num}, ordDtlNo=${exchange.ordDtlNo}" th:text="${num}" onclick="fnChangeExchangeQty(this);"></li>
+																</ul>
+															</div>
+														</div>
+													</div>
+												</form>
+												<button type="button" id="btn_exchange_pop" class="btn btn_dark btn_sm" th:attr="ordNo=${exchange.ordNo}, ordDtlNo=${exchange.ordDtlNo}" onclick="fnChangeOption(this)"><span>교환 옵션 변경</span></button>
+											</div>
+										</div>
+									</div>
+									<div class="order_text">
+										<p>교환하실 상품의 수량 및 옵션을 선택하신 후 교환 신청을 하실 수 있습니다.</p>
+									</div>
+								</div>
+								<!-- //주문상품 -->
+								</th:block>
+							</div>
+						</div>
+						<h4 class="subH3">교환 사유</h4>
+						<div class="tbl type1">
+							<table>
+								<tbody>
+									<tr>
+										<td>
+											<div class="form_field">
+												<div class="select_custom select_reason">
+													<div class="combo">
+														<input type="hidden" name="chgReason"/>
+														<div class="select">교환 사유를 선택하세요.</div>
+														<ul class="list">
+															<li class="selected">교환 사유를 선택하세요.</li>
+															<li th:if="${exchangeReason}" th:each="oneData, status : ${exchangeReason}" th:attr="chgReason=${oneData.cd}" th:text="${oneData.cdNm}" onclick="fnChangeExchangeReason(this);"></li>
+														</ul>
+													</div>
+												</div>
+											</div>
+										</td>
+									</tr>
+									<tr>
+										<td>
+											<div class="form_field">
+												<div class="input_wrap">
+													<textarea class="doc_reason" name="chgMemo" id="chgMemo" cols="30" rows="10" maxlength="200" placeholder="자세한 사유를 입력해주세요." onkeyup="fnGetTextLength(this, 200);" style="resize: none;"></textarea>
+													<p class="txt_cnt"><span id="reason_cnt" class="c_primary">0</span>/200</p>
+												</div>
+											</div>
+										</td>
+									</tr>
+								</tbody>
+							</table>
+						</div>
+						<h4 class="subH3 wdGb">반품 방식 선택</h4>
+						<div class="tbl type1 wdGb">
+							<table>
+								<tbody>
+								<tr>
+									<td>
+										<div class="retrieve_method">
+											<div class="form_field">
+												<div>
+													<input type="radio" name="wdGb" id="withdraw" value="W" checked>
+													<label for="withdraw"><span>방문회수<em>택배사에서 고객에게 방문하여 회수</em></span></label>
+												</div>
+												<div>
+													<input type="radio" name="wdGb" id="direct" value="D">
+													<label for="direct"><span>직접배송<em>고객이 반품지로 직접 반송</em></span></label>
+												</div>
+											</div>
+										</div>
+									</td>
+								</tr>
+								</tbody>
+							</table>
+						</div>
+						<div class="retrieve_box visit" style="display:block;" id="chgerLocation">
+							<h4 class="subH3">교환 회수지 주소 <span class="tit_info">택배사에서 교환 상품을 직접 회수할 장소 선택</span></h4>
+							<div class="tbl type1">
+								<table>
+									<colgroup>
+										<col width="210">
+										<col width="*">
+									</colgroup>
+									<tbody>
+										<tr>
+											<th>성명</th>
+											<td id="chgerNm" th:text="${deliveryAddrInfo.recipNm}"></td>
+											<input type="hidden" name="chgerNm" th:value="${deliveryAddrInfo.recipNm}">
+										</tr>
+										<tr>
+											<th>연락처</th>
+											<td id="chgerPhnno" th:text="${deliveryAddrInfo.recipPhnno}"></td>
+											<input type="hidden" name="chgerPhnno" th:value="${deliveryAddrInfo.recipPhnno}">
+										</tr>
+										<tr>
+											<th>주소</th>
+											<td id="chgerAddr">
+												<th:block th:text="|${deliveryAddrInfo.recipBaseAddr} ${deliveryAddrInfo.recipDtlAddr}|"></th:block>
+												<button type="button" class="btn btn_default btn_sm" onclick="fnChangeAddr('chger');"><span>회수지 변경</span></button>
+											</td>
+											<input type="hidden" name="chgerZipcode" th:value="${deliveryAddrInfo.recipZipcode}">
+											<input type="hidden" name="chgerBaseAddr" th:value="${deliveryAddrInfo.recipBaseAddr}">
+											<input type="hidden" name="chgerDtlAddr" th:value="${deliveryAddrInfo.recipDtlAddr}">
+											<input type="hidden" name="chgerRtnMemo" th:value="${deliveryAddrInfo.delvMemo}">
+										</tr>
+									</tbody>
+								</table>
+							</div>
+						</div>
+						<div class="retrieve_box direct" style="display:none;" id="returnLocation">
+							<h4 class="subH3">반송 정보</h4>
+							<div class="tbl type1">
+								<table>
+									<colgroup>
+										<col width="210">
+										<col width="*">
+									</colgroup>
+									<tbody>
+									<tr>
+										<th>
+											반송주소
+										</th>
+										<td th:text="|${deliveryAddrInfo.rtnLocBaseAddr} ${deliveryAddrInfo.rtnLocDtlAddr}|"></td>
+									</tr>
+									<tr>
+										<th>
+											반송 송장번호
+										</th>
+										<td>
+											<form class="form_wrap">
+												<div class="form_field">
+													<div class="input_wrap">
+														<input type="text" class="form_control" name="wdInvoiceNo" data-valid-type="numeric" placeholder="송장번호를 입력해주세요.">
+													</div>
+												</div>
+											</form>
+										</td>
+									</tr>
+									</tbody>
+								</table>
+							</div>
+						</div>
+						<h4 class="subH3">교환 상품 배송지</h4>
+						<div class="tbl type1">
+							<table>
+								<colgroup>
+									<col width="210">
+									<col width="*">
+								</colgroup>
+								<tbody>
+									<tr>
+										<th>
+											배송지 정보
+										</th>
+										<td>
+											<div class="block_line">
+												<ul>
+													<li>
+														<span id="recipNm" th:text="${deliveryAddrInfo.recipNm}"></span>
+													</li>
+													<li>
+														<span id="recipPhnno" th:text="${deliveryAddrInfo.recipPhnno}"></span>
+													</li>
+													<li>
+														<span id="recipAddr" th:text="|${deliveryAddrInfo.recipBaseAddr} ${deliveryAddrInfo.recipDtlAddr}|"></span>
+														<button type="button" class="btn btn_default btn_sm" onclick="fnChangeAddr('recip')"><span>배송지 변경</span></button>
+													</li>
+													<li>
+														배송요청 사항&nbsp;:&nbsp;<span id="delvMemo" th:text="${deliveryAddrInfo.delvMemo}"></span>
+														<button type="button" class="btn_underline" onclick="fnChangeDeliveryMemo(this)"><span>변경하기</span></button>
+													</li>
+												</ul>
+											</div>
+										</td>
+										<input type="hidden" name="recipNm" th:value="${deliveryAddrInfo.recipNm}">
+										<input type="hidden" name="recipPhnno" th:value="${deliveryAddrInfo.recipPhnno}">
+										<input type="hidden" name="recipZipcode" th:value="${deliveryAddrInfo.recipZipcode}">
+										<input type="hidden" name="recipBaseAddr" th:value="${deliveryAddrInfo.recipBaseAddr}">
+										<input type="hidden" name="recipDtlAddr" th:value="${deliveryAddrInfo.recipDtlAddr}">
+										<input type="hidden" name="delvMemo" th:value="${deliveryAddrInfo.delvMemo}">
+									</tr>
+								</tbody>
+							</table>
+						</div>
+						<div class="info_footer_area" id="addDeliveryFee" style="display:none">
+							<p>
+								<span id="addPayCost">2,500원</span> 배송비 추가 결제가 필요합니다.
+								<input type="hidden" name="addPayCost"/>
+							</p>
+						</div>
+						<div class="btn_footer_area">
+							<button type="button" class="btn btn_default btn_md" onclick="fnGoToNoMemberCreList()"><span>취소</span></button>
+							<button type="button" id="btn_confirm_exchange" class="btn btn_dark btn_md" onclick="fnExchange()"><span>교환 신청</span></button>
+						</div>
+					</div>
+				</form>
+			</div>
+			<!-- // CONT-BODY -->
+		</div>
+	</div>
+<script src="/ux/plugins/gaga/gaga.paging.js"></script>
+<script th:inline="javascript">
+	var isLogin = [[${isLogin}]];
+	let oneData = [[${oneData}]];
+	let isCustomer = false;
+	let addrGb = '';
+	let jsonObj = {};
+
+	$(document).ready(function() {
+		// 비회원 LNB 설정
+		fnSetNoMemberLnbList(2);
+		
+		// 비회원 location 설정
+		fnSetNoMemberLocation('취소/반품/교환 내역', '교환 신청');
+		
+		// 셀렉트박스 활성화
+		$('.select_custom').each(function() {
+			new sCombo($(this));
+		});
+
+		// 입점업체의 경우 회수방식 방문회수 처리
+		if (oneData.selfGoodsYn != 'Y') {
+			$('#withdraw').click();
+			$('.wdGb').css('display','none');
+		}
+	});
+
+	// 교환 옵션 변경 팝업
+	var fnChangeOption = function(param) {
+		let ordNo = $(param).attr('ordNo');
+		let ordDtlNo = $(param).attr('ordDtlNo');
+
+		// 옵션변경 수량 체크
+		let chgQtyArr = [];
+		let chgOrdDtlNoArr = [];
+
+		$.each($('#exchangeForm input[name=chgQty]'), function(idx, item) {
+			chgQtyArr.push($(item).val());
+			chgOrdDtlNoArr.push($(item).attr('ordDtlNo'));
+		});
+
+		let index = chgOrdDtlNoArr.indexOf(ordDtlNo);
+		let chgQty = chgQtyArr[index];
+		
+		if (chgQty == null || chgQty <= 0) {
+			mcxDialog.alert('교환 옵션 변경 수량을 선택해주세요.');
+			return false;
+		}
+
+		var jsonObj = {};
+		jsonObj.ordNo = ordNo;
+		jsonObj.ordDtlNo = ordDtlNo;
+		jsonObj.chgQty = chgQty;
+
+		$.ajax({
+			type		: "POST",
+			url 		: "/noMember/change/option/popup/form",
+			data		: jsonObj,
+			dataType 	: "html",
+			success 	: function(result) {
+				if (result != null) {
+					$("#exchangePop .modal-content").html(result);
+					$("#exchangePop").modal("show");
+				}
+			}
+		});
+	}
+
+	// 교환 옵션 변경 팝업 콜백 처리
+	var fnChangeOptionCallback = function(param) {
+		let ordDtlNo;
+
+		// 교환옵션 HTML 처리
+		let html = '												<span class="title">교환 옵션</span>\n';
+		$.each(param, function(idx, item) {
+			ordDtlNo = item.ordDtlNo;
+			let colorNm = item.colorNm;
+			let itemNm = item.itemNm;
+			let goodsType = item.goodsType;
+			let optCd2 = item.chgOptCd2;
+
+			if (goodsType == 'G056_S') {
+				html += '												<span class="option">' + itemNm + ' / ' + colorNm + ' / ' + optCd2 + '</span>\n';
+			} else {
+				html += '												<span class="option">' + colorNm + ' / ' + optCd2 + '</span>\n';
+			}
+		});
+
+		$.each($('.exchangeOption'), function(idx, item) {
+			if (ordDtlNo == $(item).attr('ordDtlNo')) {
+				$(item).css('display', '');
+				$(item).find('.option_wrap').html(html);
+			}
+		});
+
+		// 교환옵션 값 JSON 형태로 설정
+		$.each($('#exchangeForm input[name=chgOptionList]'), function(idx, item) {
+			if (ordDtlNo == $(item).attr('ordDtlNo')) {
+				$(item).val(JSON.stringify(param));
+			}
+		});
+	}
+
+	// 교환 처리
+	var fnExchange = function() {
+		let url = '/noMember/exchange';
+		let delvFeeCd = oneData.delvFeeCd;
+		let ordDtlNo = oneData.ordDtlNo;
+		let supplyCompCd = oneData.supplyCompCd;
+		let excDelvFee = oneData.excDelvFee;
+		let rtnDelvFee = oneData.rtnDelvFee;
+		let chgReason = $('#exchangeForm input[name=chgReason]').val();
+		let addPayCost = $('#exchangeForm input[name=addPayCost]').val();
+		
+		// 교환 사유 체크
+		if (gagajf.isNull(chgReason)) {
+			mcxDialog.alert('교환 사유를 선택해주세요.');
+			return false;
+		}
+
+		// 교환 상품 설정
+		let chgOrdDtlNoArr = [];
+		$.each($('#exchangeForm input[name=chgQty]'), function(idx, item) {
+			if (Number($(item).val()) > 0) {
+				chgOrdDtlNoArr.push($(item).attr('ordDtlNo'));
+			}
+		});
+
+		// 교환옵션 설정
+		let cancelReqList = [];
+		$.each($('#exchangeForm input[name=chgOptionList]'), function(idx, item) {
+			if (chgOrdDtlNoArr.includes($(item).attr('ordDtlNo')) && !gagajf.isNull($(item).val())) {
+				let json = $(item).val();
+				let jsonData = JSON.parse(json);
+				let cancelReq = {};
+				$.each(jsonData, function (index, chgOpt) {
+					cancelReq.ordDtlNo = chgOpt.ordDtlNo;
+					cancelReq.ordDtlItemSq = chgOpt.ordDtlItemSq;
+					cancelReq.delvFeeCd = delvFeeCd;
+					cancelReq.supplyCompCd = supplyCompCd;
+					cancelReq.excDelvFee = excDelvFee;
+					cancelReq.rtnDelvFee = rtnDelvFee;
+					cancelReq.ordChgOpt = chgOpt.chgOptCd2;
+					cancelReq.chgQty = chgOpt.chgQty;
+					cancelReqList.push(cancelReq);
+				});
+			}
+		});
+
+		// 교환 수량 및 변경 옵션 체크
+		if (chgOrdDtlNoArr.length > cancelReqList.length) {
+			mcxDialog.alert('교환하실 상품의 변경 옵션을 선택해주세요.');
+			return false;
+		} else if (chgOrdDtlNoArr.length < cancelReqList.length || chgOrdDtlNoArr.length == 0) {
+			mcxDialog.alert('교환하실 상품의 수량을 선택해주세요.');
+			return false;
+		}
+
+		// 교환 필요 데이터 설정
+		let data = {};
+		data.ordNo = oneData.ordNo;
+		data.ordNm = oneData.ordNm;
+		data.ordPhnno = oneData.ordPhnno;
+		data.isCustomer = isCustomer;
+		data.wdGb = $('#exchangeForm input[name=wdGb]:radio:checked').val();
+		data.wdInvoiceNo = $('#exchangeForm input[name=wdInvoiceNo]').val();
+		data.recipNm = $('#exchangeForm input[name=recipNm]').val();
+		data.recipPhnno = $('#exchangeForm input[name=recipPhnno]').val();
+		data.recipTelno = $('#exchangeForm input[name=recipTelno]').val();
+		data.recipZipcode = $('#exchangeForm input[name=recipZipcode]').val();
+		data.recipBaseAddr = $('#exchangeForm input[name=recipBaseAddr]').val();
+		data.recipDtlAddr = $('#exchangeForm input[name=recipDtlAddr]').val();
+		data.delvMemo = $('#exchangeForm input[name=delvMemo]').val();
+		data.chgReason = $('#exchangeForm input[name=chgReason]').val();
+		data.chgMemo = $('#exchangeForm textarea[name=chgMemo]').val();
+		data.chgerNm = $('#exchangeForm input[name=chgerNm]').val();
+		data.chgerPhnno = $('#exchangeForm input[name=chgerPhnno]').val();
+		data.chgerTelno = $('#exchangeForm input[name=chgerTelno]').val();
+		data.chgerEmail = $('#exchangeForm input[name=chgerEmail]').val();
+		data.chgerZipcode = $('#exchangeForm input[name=chgerZipcode]').val();
+		data.chgerBaseAddr = $('#exchangeForm input[name=chgerBaseAddr]').val();
+		data.chgerDtlAddr = $('#exchangeForm input[name=chgerDtlAddr]').val();
+		data.chgerRtnMemo = $('#exchangeForm input[name=chgerRtnMemo]').val();
+		data.addPayCost = addPayCost;
+		data.addPayAmt = 0;
+		data.cancelReqList = cancelReqList;
+
+		let jsonData = JSON.stringify(data);
+
+		// 교환 처리
+		gagajf.ajaxJsonSubmit(url, jsonData, function(result) {
+			if (addPayCost > 0) {
+				let ordChgSq = result.ordChgSq;
+				let ordNo = result.ordNo;
+
+				$('#addPaymentForm input[name=ordChgSq]').val(ordChgSq);
+				$('#addPaymentForm input[name=ordNo]').val(ordNo);
+
+				document.addPaymentForm.submit();
+			} else {
+				fnGoToNoMemberCreList();
+			}
+		}, true);
+	}
+
+	// 반품 방식 변경 이벤트
+	$('#exchangeForm input[name=wdGb]').on('change', function() {
+		let wdGb = $('#exchangeForm input[name=wdGb]:radio:checked').val();
+
+		if (wdGb == 'W') {
+			$('#chgerLocation').css('display', '');
+			$('#returnLocation').css('display', 'none');
+		} else {
+			$('#chgerLocation').css('display', 'none');
+			$('#returnLocation').css('display', '');
+		}
+
+		// 추가 배송비 계산
+		fnAddCost();
+	});
+
+	// 교환 수량 변경 이벤트
+	var fnChangeExchangeQty = function(param) {
+		let ordDtlNo = $(param).attr('ordDtlNo');
+
+		if (param != null) {
+			$(param).parent().parent().find('input[name=chgQty]').val($(param).attr('qty'));
+		}
+
+		// 교환옵션 표기 초기화
+		$.each($('.exchangeOption'), function(idx, item) {
+			if (ordDtlNo == $(item).attr('ordDtlNo')) {
+				$(item).css('display', 'none');
+				$(item).find('.option_wrap').html('');
+			}
+		});
+
+		// 교환옵션 값 초기화
+		$.each($('#exchangeForm input[name=chgOptionList]'), function(idx, item) {
+			if (ordDtlNo == $(item).attr('ordDtlNo')) {
+				$(item).val('');
+			}
+		});
+		
+		// 추가 배송비 계산
+		fnAddCost();
+	}
+
+	// 교환 사유 변경 이벤트
+	var fnChangeExchangeReason = function(param) {
+		var customerReasonArr = ['G689_10', 'G689_30'];
+		let chgReason = $(param).attr('chgReason');
+
+		// 귀책사유체크(취소,반품,교환)
+		isCustomer = customerReasonArr.includes(chgReason);
+
+		// 교환 사유 설정
+		$(param).parent().parent().find('input[name=chgReason]').val(chgReason);
+
+		// 추가 배송비 계산
+		fnAddCost();
+	}
+
+	// 추가 배송비 계산
+	var fnAddCost = function() {
+		let addPayCost = 0;
+		let delvFee = oneData.delvFee;
+		let rtnDelvFee = oneData.rtnDelvFee;
+
+		// 교환 수량 체크
+		let qty = 0;
+		$.each($('#exchangeForm input[name=chgQty]'), function (idx, item) {
+			qty += Number($(item).val());
+		});
+
+		// 교환 수량이 있고 고객 귀책 사유 시 추가 배송비 계산
+		if (isCustomer && qty > 0) {
+			addPayCost = delvFee;
+
+			// 회수 요청 시 반품배송비 추가
+			if ($('#exchangeForm input[name=wdGb]:radio:checked').val() == 'W') {
+				addPayCost += rtnDelvFee;
+			}
+
+			// 추가배송비 영역 설정
+			$('#addDeliveryFee').css('display', '');
+			$('#addPayCost').text(addPayCost.addComma() + '원');
+			$('#exchangeForm input[name=addPayCost]').val(addPayCost);
+		} else {
+			$('#addDeliveryFee').css('display', 'none');
+			$('#exchangeForm input[name=addPayCost]').val(0);
+		}
+	}
+
+	// 배송지 정보 설정
+	var delvAddrSet = function(delvObj) {
+		let recipNm = delvObj.recipNm;
+		let recipPhnno = delvObj.recipPhnno;
+		let recipZipcode = delvObj.recipZipcode;
+		let recipBaseAddr = delvObj.recipBaseAddr;
+		let recipDtlAddr = delvObj.recipDtlAddr;
+		let delvMemo = delvObj.delvMemo;
+
+		if (addrGb == 'recip') {
+			$('#recipNm').text(recipNm);
+			$('#recipPhnno').text(recipPhnno);
+			$('#recipAddr').text(recipBaseAddr + ' ' + recipDtlAddr);
+			$('#delvMemo').text(delvMemo);
+
+			$('#exchangeForm input[name=recipNm]').val(recipNm);
+			$('#exchangeForm input[name=recipPhnno]').val(recipPhnno);
+			$('#exchangeForm input[name=recipZipcode]').val(recipZipcode);
+			$('#exchangeForm input[name=recipBaseAddr]').val(recipBaseAddr);
+			$('#exchangeForm input[name=recipDtlAddr]').val(recipDtlAddr);
+			$('#exchangeForm input[name=delvMemo]').val(delvMemo);
+		} else if (addrGb == 'chger') {
+			let chgerAddr = recipBaseAddr + ' ' + recipDtlAddr + '\n';
+			chgerAddr += '<button type="button" class="btn btn_default btn_sm" onclick="fnChangeAddr(\'chger\');"><span>회수지 변경</span></button>';
+
+			$('#exchangeForm input[name=chgerNm]').val(recipNm);
+			$('#exchangeForm input[name=chgerPhnno]').val(recipPhnno);
+			$('#exchangeForm input[name=chgerZipcode]').val(recipZipcode);
+			$('#exchangeForm input[name=chgerBaseAddr]').val(recipBaseAddr);
+			$('#exchangeForm input[name=chgerDtlAddr]').val(recipDtlAddr);
+			$('#exchangeForm input[name=chgerRtnMemo]').val(delvMemo);
+
+			$('#chgerNm').text(recipNm);
+			$('#chgerPhnno').text(recipPhnno);
+			$('#chgerAddr').html(chgerAddr);
+		}
+	}
+
+	// 배송메모 설정
+	var delvMemoSet = function(delvMemoObj) {
+		let delvMemo = delvMemoObj.delvMemo;
+		$('input[name=delvMemo]').val(delvMemo);
+		$("#delvMemo").text(delvMemo);
+	}
+
+	// 배송지 및 교환지 변경 처리
+	var fnChangeAddr = function(param) {
+		addrGb = param;
+		fnChangeDeliveryAddr();
+	}
+</script>
+
+</th:block>
+
+</body>
+</html>

+ 1 - 1
src/main/webapp/WEB-INF/views/web/mypage/NoMemberOrderListFormWeb.html

@@ -298,7 +298,7 @@
 
 	// 상태값 별 수량 업데이트 처리
 	var fnReloadStatusCount = function() {
-		let url = '/mypage/status/count';
+		let url = '/noMember/status/count';
 		
 		let data = {};
 		

+ 6 - 3
src/main/webapp/WEB-INF/views/web/mypage/NoMemberReturnFormWeb.html

@@ -432,6 +432,8 @@
 
 		let data = {};
 		data.ordNo = oneData.ordNo;
+		data.ordNm = oneData.ordNm;
+		data.ordPhnno = oneData.ordPhnno;
 		data.ordChgSq = 0;
 		data.chgReason = chgReason;
 		data.chgMemo = $('#returnForm textarea[name=chgMemo]').val();
@@ -511,7 +513,8 @@
 				let spanTmtbDcAmt = Number(result.spanTmtbDcAmt);						// 다다익선 할인 차감 금액
 				let spanPrePntDcAmt = Number(result.spanPrePntDcAmt);					// 선포인트 할인 차감 금액
 				let sumDeliveryFee = Number(result.sumDeliveryFee);						// 원주문배송비 (반품에서는 안돌려줘서 항상 0일듯)
-				let spanTotDeliveryFee = Number(result.spanTotDeliveryFee);				// 추가배송비 (무료배송비 허들 깨져서 발생한 배송비)
+				//let spanTotDeliveryFee = Number(result.spanTotDeliveryFee);				// 추가배송비 (무료배송비 허들 깨져서 발생한 배송비) - 추가배송비는 환불컨펌에서 처리
+				let spanTotDeliveryFee = 0;
 				let spanTotRtnDelvFee = Number(result.spanTotRtnDelvFee);				// 반품배송비 (회수요청으로 인한 반품 배송비)
 				let spanRealCnclRtnAmt = Number(result.spanRealCnclRtnAmt);				// 환불 상품 실결제 금액 (환불상품금액 - 할인차감금액)
 				let spanRefundAmt = spanRealCnclRtnAmt + sumDeliveryFee;				// 환불예정금액 (환불상품실결제금액 - 원주문배송비)
@@ -522,7 +525,7 @@
 					// 회사사유 : 추가배송비 0, 반품배송비 0
 					if (!isCustomer) {
 						spanTotRtnDelvFee = 0;
-						spanTotDeliveryFee = 0;
+						//spanTotDeliveryFee = 0;											// 추가배송비는 환불컨펌에서 처리
 					}
 					// 고객사유(직접발송) : 반품배송비 0
 					else if (wdGb == 'D') {
@@ -530,7 +533,7 @@
 					}
 				} else {
 					spanTotRtnDelvFee = 0;
-					spanTotDeliveryFee = 0;
+					//spanTotDeliveryFee = 0;												// 추가배송비는 환불컨펌에서 처리
 				}
 
 				let goodsCancelAmt = spanCnclRtnAmt;										// 상품취소금액