MypageExchangeFormWeb.html 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291
  1. <!DOCTYPE html>
  2. <html lang="ko"
  3. xmlns:th="http://www.thymeleaf.org"
  4. xmlns:layout="http://www.ultraq.net.nz/thymeleaf/layout"
  5. layout:decorator="web/common/layout/MypageLayoutWeb">
  6. <!--
  7. *******************************************************************************
  8. * @source : MypageExchangeFormWeb.html
  9. * @desc : 마이페이지 > 교환신청 Page
  10. *============================================================================
  11. * STYLE24
  12. * Copyright(C) 2021 TSIT, All rights reserved.
  13. *============================================================================
  14. * VER DATE AUTHOR DESCRIPTION
  15. * === =========== ========== =============================================
  16. * 1.0 2021.02.22 card007 최초 작성
  17. *******************************************************************************
  18. -->
  19. <body>
  20. <th:block layout:fragment="content">
  21. <div class="my_cont">
  22. <div class="sec_head">
  23. <h3>교환 신청</h3>
  24. <div class="od_detail">
  25. (주문번호 : <span class="num" th:text="${ordNo}"></span>)
  26. </div>
  27. </div>
  28. <div class="sec_body mypage_body">
  29. <div class="order_list return_list">
  30. <section class="order_row">
  31. <th:block th:if="${orderList}" th:each="oneData, status : ${orderList}">
  32. <div class="part_deliver">
  33. <div class="tbl_tit">
  34. <!-- 주문일/선물일 설정 -->
  35. <span class="start_t" th:unless="${oneData.giftPackYn == 'Y'}">주문일</span>
  36. <span class="gift_t" th:if="${oneData.giftPackYn == 'Y'}">선물일</span>
  37. <!-- //주문일/선물일 설정 -->
  38. <span class="order_date" th:text="${oneData.ordDt}"></span>
  39. <!-- 배송구분 설정 -->
  40. <span class="order_label02" th:if="${oneData.shotDelv}">총알배송</span>
  41. <span class="order_label01" th:if="${oneData.selfMall}">STYLE24 일반배송</span>
  42. <span class="order_label01" th:if="${oneData.supplyMall}">업체직배송</span>
  43. <!-- //배송구분 설정 -->
  44. <a href="javascript:void(0)" class="detail_btn" th:attr="ordNo=${oneData.ordNo}" onclick="fnGoToOrderDetail(this)">주문상세보기</a>
  45. </div>
  46. <th:block th:if="${oneData.orderList}" th:each="order, status : ${oneData.orderList}">
  47. <div class="tbl type2">
  48. <table id="exchangeList">
  49. <colgroup>
  50. <col width="1020">
  51. <col width="180">
  52. </colgroup>
  53. <tbody>
  54. <th:block th:if="${order.ordDtlList}" th:each="ordDtl, status : ${order.ordDtlList}" th:with="imageUrl=${@environment.getProperty('upload.goods.view')}">
  55. <input type="hidden" name="ordDtlNo" th:value="${ordDtl.ordDtlNo}"/>
  56. <input type="hidden" name="ordDtlStat" th:value="${ordDtl.ordDtlStat}"/>
  57. <input type="hidden" name="reviewSq" th:value="${ordDtl.reviewSq}"/>
  58. <tr>
  59. <td>
  60. <div class="info_item">
  61. <div class="thumb_box">
  62. <a href="">
  63. <img th:src="${imageUrl + '/' + ordDtl.sysImgNm}" width="100%" alt="">
  64. </a>
  65. </div>
  66. <div class="info_box">
  67. <p class="od_name">
  68. <a href="">
  69. <span class="brand" th:text="${ordDtl.brandNm}"></span>
  70. <span class="name" th:text="${ordDtl.goodsNm}"></span>
  71. </a>
  72. </p>
  73. <p class="od_opt">
  74. <span class="option"><em th:text="${ordDtl.optCd1}"></em><em th:text="${ordDtl.optCd2}"></em></span>
  75. <span class="count">수량 <em th:text="${ordDtl.ordQty}"></em>개</span>
  76. </p>
  77. </div>
  78. <div class="info_calc">
  79. <p class="price">
  80. <span class="selling_price" th:text="|${#numbers.formatInteger(ordDtl.ordAmt, 1, 'COMMA')}원|"></span>
  81. </p>
  82. <p class="point"><span th:text="${#numbers.formatInteger(ordDtl.savePntAmt, 1, 'COMMA')}"></span>p</p>
  83. </div>
  84. </div>
  85. </td>
  86. <td class="cnt_sel">
  87. <span class="cnt_t">수량</span>
  88. <select class="select_dress" name="chgQty">
  89. <option value="">선택</option>
  90. <option th:if="${ordDtl.ordQty > 0}" th:each="num : ${#numbers.sequence(1,ordDtl.ordQty)}" th:value="${num}" th:text="${num}"></option>
  91. </select>
  92. <button class="btn btn_dark btn_sm" th:attr="ordDtlNo=${ordDtl.ordDtlNo}" onclick="fnChangeOption(this);">옵션 변경</button>
  93. </td>
  94. </tr>
  95. </th:block>
  96. </tbody>
  97. </table>
  98. </div>
  99. </th:block>
  100. <div class="order_confirm">
  101. <p class="cf_txt cf_desc c_primary">교환하실 상품의 수량 및 옵션을 선택하신 후 교환 신청을 하실 수 있습니다.</p>
  102. </div>
  103. </div>
  104. </th:block>
  105. </section>
  106. <section class="order_row">
  107. <div class="tbl_tit">
  108. <h3 class="subH3">교환 사유</h3>
  109. </div>
  110. <div class="tbl type1">
  111. <table>
  112. <colgroup>
  113. <col width="*">
  114. </colgroup>
  115. <tbody>
  116. <tr>
  117. <td>
  118. <select id="mounth" name="chgReason" onchange="fnChangeReason(this);">
  119. <option value="">교환 사유를 선택하세요</option>
  120. <option th:if="${exchangeReason}" th:each="oneData, status : ${exchangeReason}" th:value="${oneData.cd}" th:text="${oneData.cdNm}"></option>
  121. </select>
  122. </td>
  123. </tr>
  124. <tr>
  125. <td>
  126. <textarea class="doc_exchange" name="chgMemo" id="chgMemo" placeholder="자세한 사유를 입력해주세요." onkeyup="cfnGetTextLength(this, 500, $('#exchange_cnt'));"></textarea>
  127. <p class="txt_cnt"><span id="exchange_cnt" class="c_primary">0</span>/500</p>
  128. </td>
  129. </tr>
  130. </tbody>
  131. </table>
  132. </div>
  133. </section>
  134. <section class="order_row" id="chgerLocation">
  135. <div class="order_tit">
  136. <h3 class="subH3">상품 회수지</h3>
  137. <span class="del_t">교환받을 상품을 수령할 장소 선택</span>
  138. <button type="button" class="btn_popup" onclick="fnChangeDeliveryAddr('chger');"><span>회수지 선택</span></button>
  139. </div>
  140. <div class="tbl type1">
  141. <table>
  142. <colgroup>
  143. <col width="200">
  144. <col width="*">
  145. </colgroup>
  146. <tbody>
  147. <tr>
  148. <th>성명</th>
  149. <td id="chgerNm" th:text="${deliveryAddrInfo.recipNm}"></td>
  150. <input type="hidden" name="chgerNm" th:value="${deliveryAddrInfo.recipNm}">
  151. </tr>
  152. <tr>
  153. <th>연락처</th>
  154. <td id="chgerPhnno" th:text="${deliveryAddrInfo.recipPhnno}"></td>
  155. <input type="hidden" name="chgerPhnno" th:value="${deliveryAddrInfo.recipPhnno}">
  156. </tr>
  157. <tr>
  158. <th>주소</th>
  159. <td id="chgerAddr" th:text="|${deliveryAddrInfo.recipBaseAddr} ${deliveryAddrInfo.recipDtlAddr}|"></td>
  160. <input type="hidden" name="chgerBaseAddr" th:value="${deliveryAddrInfo.recipBaseAddr}">
  161. <input type="hidden" name="chgerDtlAddr" th:value="${deliveryAddrInfo.recipDtlAddr}">
  162. </tr>
  163. </tbody>
  164. </table>
  165. </div>
  166. </section>
  167. <section class="order_row" id="returnLocation">
  168. <div class="order_tit">
  169. <h3 class="subH3">반품하실 배송지</h3>
  170. </div>
  171. <div class="tbl type1">
  172. <table>
  173. <colgroup>
  174. <col width="200">
  175. <col width="*">
  176. </colgroup>
  177. <tbody>
  178. <tr>
  179. <th>성명</th>
  180. <td th:text="${deliveryAddrInfo.rtnLocNm}"></td>
  181. <input type="hidden" name="rtnLocNm" th:value="${deliveryAddrInfo.rtnLocNm}">
  182. </tr>
  183. <tr>
  184. <th>연락처</th>
  185. <td th:text="${deliveryAddrInfo.rtnLocTelno}"></td>
  186. <input type="hidden" name="rtnLocTelno" th:value="${deliveryAddrInfo.rtnLocTelno}">
  187. </tr>
  188. <tr>
  189. <th>주소</th>
  190. <td th:text="|${deliveryAddrInfo.rtnLocBaseAddr} ${deliveryAddrInfo.rtnLocDtlAddr}|"></td>
  191. <input type="hidden" name="rtnLocBaseAddr" th:value="${deliveryAddrInfo.rtnLocBaseAddr}">
  192. <input type="hidden" name="rtnLocDtlAddr" th:value="${deliveryAddrInfo.rtnLocDtlAddr}">
  193. </tr>
  194. </tbody>
  195. </table>
  196. </div>
  197. </section>
  198. <section class="order_row">
  199. <div class="order_tit">
  200. <h3 class="subH3">교환 상품 받으실 주소</h3>
  201. <span class="del_t">택배사에서 반품 상품을 직접 회수할 장소 선택</span>
  202. <button type="button" class="btn_popup" onclick="fnChangeDeliveryAddr('recip');"><span>회수지 선택</span></button>
  203. </div>
  204. <div class="tbl type1">
  205. <table>
  206. <colgroup>
  207. <col width="200">
  208. <col width="*">
  209. </colgroup>
  210. <tbody>
  211. <tr>
  212. <th>성명</th>
  213. <td id="recipNm" th:text="${deliveryAddrInfo.recipNm}"></td>
  214. <input type="hidden" name="recipNm" th:value="${deliveryAddrInfo.recipNm}">
  215. </tr>
  216. <tr>
  217. <th>연락처</th>
  218. <td id="recipPhnno" th:text="${deliveryAddrInfo.recipPhnno}"></td>
  219. <input type="hidden" name="recipPhnno" th:value="${deliveryAddrInfo.recipPhnno}">
  220. </tr>
  221. <tr>
  222. <th>주소</th>
  223. <td id="recipAddr" th:text="|${deliveryAddrInfo.recipBaseAddr} ${deliveryAddrInfo.recipDtlAddr}|"></td>
  224. <input type="hidden" name="recipBaseAddr" th:value="${deliveryAddrInfo.recipBaseAddr}">
  225. <input type="hidden" name="recipDtlAddr" th:value="${deliveryAddrInfo.recipDtlAddr}">
  226. </tr>
  227. </tbody>
  228. </table>
  229. </div>
  230. </section>
  231. <section class="order_row" id="addDeliveryFee" style="display:none">
  232. <div class="ship_fee">
  233. <p><span class="c_primary" id="addPayCost">2,500원</span> 배송비 추가 결제가 필요합니다.</p>
  234. <input type="hidden" name="addPayCost"/>
  235. </div>
  236. </section>
  237. <div class="btn_wrap">
  238. <button type="button" class="btn btn_default cancle_btn" onclick="cfnGoToPage(_PAGE_MYPAGE_CRS_LIST)"><span>교환 취소</span></button>
  239. <button tyep="submit" class="btn btn_primary submit_btn" onclick="fnExchange()"><span id="exchangeButton">교환 신청</span></button>
  240. </div>
  241. </div>
  242. </div>
  243. </div>
  244. <script src="/ux/plugins/gaga/gaga.paging.js"></script>
  245. <script th:inline="javascript">
  246. $(document).ready(function() {
  247. // 마이페이지 LNB 설정
  248. fnSetMypageLnbList(2);
  249. // 마이페이지 location 설정
  250. fnSetMypageLocation('취소/반품/환불내역', '_PAGE_MYPAGE_CRS_LIST', '교환 신청');
  251. });
  252. // 교환 옵션 변경 팝업
  253. var fnChangeOption = function(param) {
  254. // TODO
  255. // 옵션변경 처리
  256. }
  257. // 회수지, 교환지 설정 팝업
  258. var fnChangeDeliveryAddr = function(param) {
  259. // TODO
  260. // 회수지, 교환지 설정
  261. }
  262. // 교환 처리
  263. var fnExchange = function() {
  264. // TODO
  265. // 교환신청 처리
  266. }
  267. // 교환 사유 변경 이벤트
  268. var fnChangeReason = function(param) {
  269. let chgReason = $(param).val();
  270. // TODO
  271. // 사유 변경 처리
  272. alert('a');
  273. console.log($('#exchangeList tr'));
  274. $.each($('#exchangeList tr'), function(idx, item) {
  275. console.log(item);
  276. })
  277. }
  278. </script>
  279. </th:block>
  280. </body>
  281. </html>