MallMainFormMob.html 51 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201
  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="mob/common/layout/DefaultLayoutMob">
  6. <!--
  7. *******************************************************************************
  8. * @source : MallMainFormMob.html
  9. * @desc : 몰메인 Page
  10. *============================================================================
  11. * STYLE24
  12. * Copyright(C) 2020 TSIT, All rights reserved.
  13. *============================================================================
  14. * VER DATE AUTHOR DESCRIPTION
  15. * === =========== ========== =============================================
  16. * 1.0 2021.03.10 gagamel 최초 작성
  17. *******************************************************************************
  18. -->
  19. <body>
  20. <th:block layout:fragment="content">
  21. <main role="" id="" class="container">
  22. <section class="main">
  23. <th:block th:if="${mainLayoutList}" th:each="mainData, mainStat : ${mainLayoutList}" th:with="contentsLoc=${#strings.replace(mainData.contentsLoc,'SMM','')},contentsTitle=${#strings.replace(mainData.contentsTitle,'<br>',' ')}">
  24. <!-- <th:block th:if="${mainData.ContentsList != null and !mainData.ContentsList.empty}">-->
  25. <th:block th:if="${contentsLoc=='001'}">
  26. <!-- 1. 비주얼 슬라이드 -->
  27. <div class="inner wide" th:if="${mainData.ContentsList != null and !mainData.ContentsList.empty}">
  28. <div class="main_visual">
  29. <div class="swiper-container post-visual">
  30. <div class="swiper-wrapper">
  31. <th:block th:each="ContentsData, ContentsStat : ${mainData.ContentsList}">
  32. <div class="swiper-slide">
  33. <a href="javascript:void(0)" th:onclick="cfnGoToPage([[${ContentsData.strVar1}]]);">
  34. <img th:src="${@environment.getProperty('domain.image')+ContentsData.imgPath2}" alt="">
  35. <div class="txtWrap">
  36. <dl th:class="${ContentsData.strVar7=='BLACK'?'':'w'}">
  37. <dt th:if="${ContentsData.strVar5=='P'}" th:text="${ContentsData.planBrandGroupNm}">NBA</dt>
  38. <dt th:if="${ContentsData.strVar5=='P' and ContentsData.planGb=='E'}">EVENT</dt>
  39. <dd class="mainTitle">
  40. <input type="hidden" name="mainTitlee" th:value="${ContentsData.strTitle1}"/>
  41. </dd>
  42. <!-- <dd>NEW ARRIVAL</dd>-->
  43. <dd class="txt_xs mainSubTitle" th:text="${ContentsData.subText1}">
  44. <!-- <input type="hidden" name="mainSubTitlee" th:value="${ContentsData.subText1}"/>-->
  45. </dd>
  46. </dl>
  47. </div>
  48. </a>
  49. </div>
  50. </th:block>
  51. </div>
  52. <!-- Add Pagination -->
  53. <div class="swiper-pagination"></div>
  54. </div>
  55. </div>
  56. </div>
  57. </th:block>
  58. <th:block th:if="${contentsLoc=='002'}">
  59. <!-- 2. 스타일리포트 -->
  60. <div class="inner bg_gray" th:if="${mainData.ContentsList != null and !mainData.ContentsList.empty}">
  61. <div class="main_stylereport">
  62. <th:block th:if="${mainData.contentsTitle != null and !mainData.contentsTitle.empty}">
  63. <div class="titWrap">
  64. <h2 th:text="${mainData.contentsTitle}"></h2>
  65. </div>
  66. </th:block>
  67. <div class="swiper-container post-stylereport">
  68. <div class="swiper-wrapper">
  69. <th:block th:each="ContentsData, ContentsStat : ${mainData.ContentsList}">
  70. <div class="swiper-slide styleArea" th:if="${ContentsStat.count<5}">
  71. <a href="javascript:void(0)" th:onclick="cfnGoToPage([[${ContentsData.strVar1}]]);">
  72. <img th:src="${@environment.getProperty('domain.image')+ContentsData.imgPath1}" alt="">
  73. <dl>
  74. <dt class="styleTitleC">
  75. <input type="hidden" name="styleTitle" th:value="${ContentsData.strTitle1}"/>
  76. </dt>
  77. <dd class="styleNoteC">
  78. <input type="hidden" name="styleNote" th:value="${ContentsData.subText1}"/>
  79. </dd>
  80. <!-- <dd>준비한 아우터 픽을 만나보자</dd>-->
  81. </dl>
  82. </a>
  83. </div>
  84. </th:block>
  85. </div>
  86. <!-- Add Pagination -->
  87. <div class="swiper-pagination"></div>
  88. </div>
  89. </div>
  90. </div>
  91. </th:block>
  92. <th:block th:if="${contentsLoc=='003'}">
  93. <!-- 3. 트렌디한 신상아이템 -->
  94. <div class="inner" th:if="${mainData.goodsList != null}">
  95. <div class="main_trendy">
  96. <th:block th:if="${mainData.contentsTitle != null and !mainData.contentsTitle.empty}">
  97. <div class="titWrap">
  98. <h2 th:text="${mainData.contentsTitle}"></h2>
  99. </div>
  100. </th:block>
  101. <div class="swiper-container post-trendy">
  102. <div class="swiper-wrapper">
  103. <th:block th:each="goodsData, goodsStat : ${mainData.goodsList}">
  104. <th:block th:if="${(goodsStat.index%4)==0 or goodsStat.first}">
  105. <div class="swiper-slide">
  106. </th:block>
  107. <div class="item_prod">
  108. <div class="item_state">
  109. <button type="button" class="itemLike" th:classappend="${goodsData.likeIt == 'likeit'}? 'likeit' : ''" onclick="cfnPutWishList(this);" th:attr="goodsCd=${goodsData.goodsCd}, goodsNm=${goodsData.goodsFullNm}, ithrCd='', contentsLoc='SMM003', planDtlSq=''">관심상품 추가</button>
  110. <a href="javascript:void(0)" class="itemLink" th:onclick="cfnGoToGoodsDetail([[${goodsData.goodsCd}]], '', '', 'SMM003');">
  111. <div class=" itemPic">
  112. <!-- <img alt="BLUE-a" class=" pd_img" src="/images/mo/thumb/main_trendy05.jpg"> onerror="img_check(this)"-->
  113. <th:block th:each="option,idx:${goodsData.videos}" th:with="videoArr=${#strings.arraySplit(idx.current,':')}">
  114. <iframe th:if="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${'https://www.youtube.com/embed/'+videoArr[1]+'?autoplay=1&mute=1'}"></iframe>
  115. <iframe th:unless="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${kollusMediaUrl+'/'+videoArr[1]+'?enable_initialize_focus=false&autoplay&mute&controls_activation=none'}" allow="fullscreen" allowFullScreen></iframe>
  116. </th:block>
  117. <img alt="BLUE-a" class=" pd_img" th:src="${@environment.getProperty('upload.goods.view') + '/' + goodsData.sysImgNm}" onerror="noneImg(this)" >
  118. </div>
  119. <p class="itemBrand" th:text="${goodsData.brandGroupNm}">BRAND NAME</p>
  120. <div class="itemComment" th:if="${not #strings.isEmpty(goodsData.goodsTnm)}" th:text="${goodsData.goodsTnm}">#주문 폭주 상품</div>
  121. <div class=" itemName" th:text="${goodsData.goodsFullNm}">가을 신상 남성 스탠다드핏 로고맨 블루 볼 캡 유니 경량다운 시보리넥 베스트</div>
  122. <!-- <p class="itemPrice" th:text="${#numbers.formatInteger(goodsData.currPrice,1,'COMMA')}">488,000</p>-->
  123. <p th:unless="${goodsData.goodsType=='G056_D'}" class="itemPrice">
  124. <span class="itemPrice_original" th:if="${goodsData.currPrice != goodsData.listPrice}" th:text="${#numbers.formatInteger(goodsData.listPrice,3,'COMMA')}">89,000</span>[[${#numbers.formatInteger(goodsData.currPrice,0,'COMMA')}]]
  125. <span class=" itemPercent" th:if="${goodsData.currPrice != goodsData.listPrice}" th:text="${(goodsData.listPrice == 0 ? 0 : #numbers.formatDecimal((goodsData.listPrice - goodsData.currPrice) / (goodsData.listPrice * 1.0) * 100, 1, 0)) + '%'}">10%</span>
  126. </p>
  127. <p th:if="${goodsData.goodsType=='G056_D'}" class="itemPrice">
  128. [[${#numbers.formatInteger(goodsData.currPrice,0,'COMMA')}]] ~
  129. </p>
  130. </a>
  131. </div>
  132. </div>
  133. <th:block th:if="${(goodsStat.index%4)== 3 or goodsStat.last}">
  134. <th:block th:utext="'</div>'"></th:block>
  135. </th:block>
  136. </th:block>
  137. </div>
  138. <!-- Add Pagination -->
  139. <div class="swiper-pagination"></div>
  140. </div>
  141. </div>
  142. </div>
  143. </th:block>
  144. <th:block th:if="${contentsLoc=='004' and !mainData.BestItemList.empty}">
  145. <!-- 4. 잇 아이템 -->
  146. <div class="inner">
  147. <div class="main_it">
  148. <div class="titWrap">
  149. <!-- 2021.08.30 card007 메인 잇 아이템 전체보기 주석처리 추후 주석 제거 필요 -->
  150. <a href="javascript:void(0)" onclick="cfnGoToPage(_PAGE_BEST_MAIN);">
  151. <h2 th:text="${mainData.contentsTitle.replace('<br>','')}"></h2>
  152. </a>
  153. <!-- //2021.08.30 card007 메인 잇 아이템 전체보기 주석처리 추후 주석 제거 필요 -->
  154. </div>
  155. <div class="inner_head">
  156. <ul class="it_nav">
  157. <th:block th:each="ContentsData, ContentsStat : ${mainData.BestItemList}">
  158. <li><button class="btn btn_link" th:attr="data-tab=${'it'+ContentsStat.count}"><span th:text="${ContentsData.cateNm}">여성</span></button></li>
  159. </th:block>
  160. </ul>
  161. </div>
  162. <div class="inner_body">
  163. <th:block th:each="ContentsData, ContentsStat : ${mainData.BestItemList}">
  164. <div class="swiper-container post-it it_item" th:id="${'it'+ContentsStat.count}">
  165. <div class="swiper-wrapper" >
  166. <th:block th:each="bestItemData, bestItemStat : ${ContentsData.goodsList}">
  167. <div class="swiper-slide">
  168. <div class="item_prod">
  169. <div class="item_state">
  170. <button type="button" class="itemLike" th:classappend="${bestItemData.likeIt == 'likeit'}? 'likeit' : ''" onclick="cfnPutWishList(this);" th:attr="goodsCd=${bestItemData.goodsCd}, goodsNm=${bestItemData.goodsFullNm}, ithrCd='', contentsLoc='SMM004', planDtlSq=''">관심상품 추가</button>
  171. <a href="javascript:void(0)" class="itemLink" th:onclick="cfnGoToGoodsDetail([[${bestItemData.goodsCd}]], '', '', 'SMM004', '', 'mo_main_m60');">
  172. <div class="shape" th:classappend="${bestItemStat.count==1}?'ranker'">
  173. <span><em class="number" th:text="${bestItemStat.count}">1</em></span>
  174. </div>
  175. <div class="itemPic">
  176. <th:block th:each="option,idx:${bestItemData.videos}" th:with="videoArr=${#strings.arraySplit(idx.current,':')}">
  177. <iframe th:if="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${'https://www.youtube.com/embed/'+videoArr[1]+'?autoplay=1&mute=1'}"></iframe>
  178. <iframe th:unless="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${kollusMediaUrl+'/'+videoArr[1]+'?enable_initialize_focus=false&autoplay&mute&controls_activation=none'}" allow="fullscreen" allowFullScreen></iframe>
  179. </th:block>
  180. <!-- 2021.08.30 검색엔진데이타 https: 붙여서 넘어옴 처리 -->
  181. <th:block th:if="${#strings.indexOf(bestItemData.sysImgNm, 'https:')} == -1">
  182. <img alt="" class=" pd_img" th:src="${@environment.getProperty('upload.goods.view') + '/' + bestItemData.sysImgNm.replace('//image.istyle24.com/Upload/ProductImage/','')}" onerror="noneImg(this)">
  183. </th:block>
  184. <th:block th:if="${#strings.indexOf(bestItemData.sysImgNm, 'https:')} == 0">
  185. <img alt="" class=" pd_img" th:src="${@environment.getProperty('upload.goods.view') + '/' + bestItemData.sysImgNm.replace('https://image.istyle24.com/Upload/ProductImage/','')}" onerror="noneImg(this)">
  186. </th:block>
  187. <!-- //2021.08.30 검색엔진데이타 https: 붙여서 넘어옴 처리 -->
  188. </div>
  189. <p class="itemBrand" th:text="${bestItemData.brandGroupNm}">TBJ</p>
  190. <div class="itemComment" th:if="${not #strings.isEmpty(bestItemData.goodsTnm)}" th:text="${bestItemData.goodsTnm}"># 가을 느낌 물씬!</div>
  191. <div class="itemName" th:text="${bestItemData.goodsFullNm}">11111 남성 로고 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건</div>
  192. <p th:unless="${bestItemData.goodsType=='G056_D'}" class="itemPrice">
  193. <span class="itemPrice_original" th:if="${bestItemData.currPrice != bestItemData.listPrice}" th:text="${#numbers.formatInteger(bestItemData.listPrice,3,'COMMA')}">89,000</span>[[${#numbers.formatInteger(bestItemData.currPrice,0,'COMMA')}]]
  194. <span class=" itemPercent" th:if="${bestItemData.currPrice != bestItemData.listPrice}" th:text="${(bestItemData.listPrice == 0 ? 0 : #numbers.formatDecimal((bestItemData.listPrice - bestItemData.currPrice) / (bestItemData.listPrice * 1.0) * 100, 1, 0)) + '%'}">10%</span>
  195. </p>
  196. <p th:if="${bestItemData.goodsType=='G056_D'}" class="itemPrice">
  197. [[${#numbers.formatInteger(bestItemData.currPrice,0,'COMMA')}]] ~
  198. </p>
  199. </a>
  200. </div>
  201. </div>
  202. </div>
  203. </th:block>
  204. </div>
  205. </div>
  206. </th:block>
  207. </div>
  208. </div>
  209. </div>
  210. </th:block>
  211. <th:block th:if="${contentsLoc=='005' and !mainData.ContentsList.empty}">
  212. <!-- 5. 프로모션배너 -->
  213. <div class="inner wide">
  214. <div class="main_2stage">
  215. <div class="swiper-container post-bnnEvent">
  216. <th:block th:each="ContentsData, ContentsStat : ${mainData.ContentsList}">
  217. <th:block th:if="${ContentsData.contentsType!=null && ContentsData.contentsType!=''}">
  218. <div class="swiper-wrapper" th:if="${ContentsData.contentsType=='1'}">
  219. <div class="swiper-slide">
  220. <a href="javascript:void(0)" th:onclick="cfnGoToPage([[${ContentsData.strVar1}]]);">
  221. <div class="bnnbox" style="background:#e3e7ea;">
  222. <img th:src="${@environment.getProperty('domain.image')+ContentsData.imgPath1}" alt="">
  223. </div>
  224. </a>
  225. </div>
  226. </div>
  227. <div class="swiper-wrapper" th:if="${ContentsData.contentsType=='2'}">
  228. <div class="swiper-slide">
  229. <a href="javascript:void(0)" th:onclick="cfnGoToPage([[${ContentsData.strVar1}]]);">
  230. <div class="bnnbox" style="background:#e3e7ea;">
  231. <img th:src="${@environment.getProperty('domain.image')+ContentsData.imgPath1}" alt="">
  232. </div>
  233. </a>
  234. </div>
  235. <div class="swiper-slide">
  236. <a href="javascript:void(0)" th:onclick="cfnGoToPage([[${ContentsData.strVar2}]]);">
  237. <div class="bnnbox" style="background:#eef1f3;">
  238. <img th:src="${@environment.getProperty('domain.image')+ContentsData.imgPath2}" alt="">
  239. </div>
  240. </a>
  241. </div>
  242. </div>
  243. </th:block>
  244. </th:block>
  245. <!-- Add Pagination -->
  246. <div class="swiper-pagination"></div>
  247. </div>
  248. </div>
  249. </div>
  250. </th:block>
  251. <th:block th:if="${contentsLoc=='006'}">
  252. <!-- 6. 타임딜 : 슬라이드 -->
  253. <th:block th:each="socialData, socialStat : ${mainData.socialInfo}">
  254. <div class="inner bg_dark" th:if="${socialData.socialGoodsList != null and !socialData.socialGoodsList.empty}">
  255. <div class="main_deal">
  256. <div class="titWrap">
  257. <a href="javascript:void(0)" onclick="cfnGoToPage(_PAGE_SOCIAL_MAIN);">
  258. <h2 th:text="${contentsTitle}"></h2>
  259. </a>
  260. <th:block th:each="socialData, socialStat : ${mainData.socialInfo}">
  261. <form name="socailForm" id="socailForm">
  262. <input type="hidden" name="targetTime" th:value="${socialData.socialEddt}">
  263. </form>
  264. </th:block>
  265. <div class="count">
  266. <span class="count_tit">남은 시간</span>
  267. <div class="hotdealcount" id="countdown">
  268. <div id="tiles"></div>
  269. </div>
  270. </div>
  271. </div>
  272. <div class="swiper-container post-deal">
  273. <div class="swiper-wrapper" >
  274. <!-- <th:block th:each="socialData, socialStat : ${mainData.socialInfo}">-->
  275. <th:block th:each="goodsData, goodsStat : ${socialData.socialGoodsList}">
  276. <div class="swiper-slide" th:if="${goodsStat.count<21}">
  277. <div class="item_prod" style="width:100%">
  278. <div class="item_state">
  279. <button type="button" class="itemLike" th:classappend="${goodsData.likeIt == 'likeit'}? 'likeit' : ''" onclick="cfnPutWishList(this);" th:attr="goodsCd=${goodsData.goodsCd}, goodsNm=${goodsData.goodsNm}, ithrCd='', contentsLoc='SMM006', planDtlSq=''">관심상품 추가</button>
  280. <a href="javascript:void(0)" class="itemLink" th:onclick="cfnGoToGoodsDetail([[${goodsData.goodsCd}]], '', '', 'SMM006');">
  281. <div class="itemPic">
  282. <img alt="" class=" pd_img" th:src="${@environment.getProperty('upload.goods.view') + '/' + goodsData.sysImgNm}" onerror="noneImg(this)">
  283. </div>
  284. <p class="itemBrand" th:text="${goodsData.brandGroupNm}">TBJ</p>
  285. <div class="itemComment" th:if="${not #strings.isEmpty(goodsData.goodsTnm)}" th:text="${goodsData.goodsTnm}"># 가을 느낌 물씬!</div>
  286. <div class="itemName" th:text="${goodsData.goodsNm}">11111 남성 로고 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건</div>
  287. <p class="itemPrice">
  288. <span class="itemPrice_original" th:if="${goodsData.currPrice != goodsData.listPrice}" th:text="${#numbers.formatInteger(goodsData.listPrice,0,'COMMA')}">89,000</span>[[${#numbers.formatInteger(goodsData.currPrice,0,'COMMA')}]]
  289. <span class=" itemPercent" th:if="${goodsData.currPrice != goodsData.listPrice}" th:text="${#numbers.formatDecimal(goodsData.dcRate,1,0)} + '%'">10%</span>
  290. </p>
  291. </a>
  292. </div>
  293. </div>
  294. </div>
  295. </th:block>
  296. <!-- </th:block>-->
  297. </div>
  298. </div>
  299. </div>
  300. </div>
  301. </th:block>
  302. </th:block>
  303. <th:block th:if="${contentsLoc=='007'}">
  304. <!-- 7. 브랜드픽 -->
  305. <div class="inner" th:if="${!mainData.brandPickList.empty}">
  306. <div class="main_pick">
  307. <div class="titWrap">
  308. <h2 th:text="${contentsTitle}"></h2>
  309. </div>
  310. <div class="inner_head">
  311. <div class="swiper-container pick-head"> <!--(pick-head)슬라이드 키클래스-->
  312. <ul class="swiper-wrapper">
  313. <th:block th:each="ContentsData, ContentsStat : ${mainData.ContentsList}">
  314. <li class="swiper-slide" th:classappend="${ContentsStat.count==1}?'on'"> <!-- li.on / li .btn.active : 메뉴 표시 -->
  315. <button class="btn btn_link" th:id="${'pickBtn'+ContentsStat.count}" th:attr="data-tab=${'pick'+ContentsStat.count}"><span th:text="${ContentsData.brandGroupNm}">BUKAROO</span></button>
  316. </li>
  317. </th:block>
  318. </ul>
  319. </div>
  320. </div>
  321. <div class="inner_body">
  322. <th:block th:each="brandPickData, brandPickStat : ${mainData.brandPickList}">
  323. <div class="pick-cont" th:classappend="${brandPickStat.count==1}?'active'" th:id="${'pick'+brandPickStat.count}"> <!-- .pick-cont.active : 컨텐츠 표시 -->
  324. <!-- 210329 : 브랜드 pick 슬라이드 추가 -->
  325. <div class="swiper-container">
  326. <div class="swiper-wrapper" id="id007">
  327. <th:block th:each="bannerData, bannerStat : ${brandPickData.BannerList}">
  328. <div class="swiper-slide" th:if="${bannerData.imgPath1 != ''}">
  329. <a href="javascript:void(0)" th:onclick="cfnGoToPage([[${bannerData.strVar1}]]);"><!-- 해당 배너 상세 이동 -->
  330. <div class="txtWrap">
  331. <p class="title">
  332. <input type="hidden" name="title" th:value="${bannerData.strTitle1}">
  333. </p>
  334. <span th:text="${bannerData.subText1}">2020 FALL/WINTER 신상살펴보기</span>
  335. </div>
  336. <img th:src="${@environment.getProperty('domain.image')+bannerData.imgPath1}" alt="">
  337. </a>
  338. </div>
  339. </th:block>
  340. </div>
  341. </div>
  342. <!-- //210329 : 브랜드 pick 슬라이드 추가 -->
  343. <!-- 210329 : 브랜드 pick 상품 swiper 제거 -->
  344. <div class="pick-post"><!-- (pick-post)슬라이드 키클래스(해당 배너 관련 상품) -->
  345. <th:block th:each="goodsData, goodsStat : ${brandPickData.goodsList}">
  346. <div class="item_prod" th:if="${goodsStat.count<4}">
  347. <div class="item_state">
  348. <a href="javascript:void(0)" class="itemLink" th:onclick="cfnGoToGoodsDetail([[${goodsData.goodsCd}]], '', '', 'SMM007');">
  349. <div class="itemPic">
  350. <th:block th:each="option,idx:${goodsData.videos}" th:with="videoArr=${#strings.arraySplit(idx.current,':')}">
  351. <iframe th:if="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${'https://www.youtube.com/embed/'+videoArr[1]+'?autoplay=1&mute=1'}"></iframe>
  352. <iframe th:unless="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${kollusMediaUrl+'/'+videoArr[1]+'?enable_initialize_focus=false&autoplay&mute&controls_activation=none'}" allow="fullscreen" allowFullScreen></iframe>
  353. </th:block>
  354. <img alt="" class=" pd_img" th:src="${@environment.getProperty('upload.goods.view') + '/' + goodsData.sysImgNm}" onerror="noneImg(this)">
  355. </div>
  356. <div class="itemName" th:text="${goodsData.goodsFullNm}">11111 남성 로고 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건</div>
  357. <p th:unless="${goodsData.goodsType=='G056_D'}" class="itemPrice" th:text="${#numbers.formatInteger(goodsData.currPrice,1,'COMMA')}">35,900</p>
  358. <p th:if="${goodsData.goodsType=='G056_D'}" class="itemPrice" th:text="${#numbers.formatInteger(goodsData.currPrice,1,'COMMA') + ' ~'}"></p>
  359. </a>
  360. </div>
  361. </div>
  362. </th:block>
  363. </div> <!--pick-post 종료 -->
  364. <!-- 210524 : pick-post 형제로 버튼그룹 이동 -->
  365. <div class="btn_group_flex">
  366. <div>
  367. <button class="btn btn_default" th:onclick="fnNextBrand([[${brandPickStat.size}]],[[${brandPickStat.count}]])">다음 브랜드 보기<span></span></button>
  368. </div>
  369. </div>
  370. <!-- //210329 : 브랜드 pick 상품 swiper 제거 -->
  371. <!-- 210329 : 브랜드 pick 상품 swiper 제거 -->
  372. </div>
  373. </th:block>
  374. </div>
  375. </div>
  376. </div>
  377. </th:block>
  378. <th:block th:if="${contentsLoc=='008' and !mainData.ContentsList.empty}">
  379. <!-- 8. 가로 긴 배너 슬라이드 -->
  380. <div class="inner wide">
  381. <div class="main_1stage">
  382. <div class="swiper-container post-bnnWide">
  383. <div class="swiper-wrapper">
  384. <th:block th:each="ContentsData, ContentsStat : ${mainData.ContentsList}">
  385. <div class="swiper-slide silderBannerArea">
  386. <th:block th:if="${ContentsData.imgPath1!=null && ContentsData.imgPath1!=''}">
  387. <a href="javascript:void(0)" th:onclick="cfnGoToPage([[${ContentsData.strVar1}]]);">
  388. <div class="bnnbox" style="background:#bdc3c7;">
  389. <div class="txtWrap bannerNote">
  390. <p class="noteArea">
  391. <input type="hidden" name="bannerNote" th:value="${ContentsData.strTitle1}"/>
  392. </p>
  393. <!-- <p>아우터 + 이너 단독세일</p>-->
  394. </div>
  395. <img alt="BLUE-a" class=" vLHTC pd_img" th:src="${@environment.getProperty('domain.image')+ContentsData.imgPath1}">
  396. </div>
  397. </a>
  398. </th:block>
  399. </div>
  400. </th:block>
  401. </div>
  402. <!-- Add Pagination -->
  403. <div class="swiper-pagination"></div>
  404. </div>
  405. </div>
  406. </div>
  407. </th:block>
  408. <th:block th:if="${contentsLoc=='009'}">
  409. <!-- 9. MD추천 스타일 -->
  410. <div class="inner">
  411. <div class="main_recomm">
  412. <div class="titWrap">
  413. <h2 th:text="${contentsTitle}">MD가 추천하는 스타일</h2>
  414. </div>
  415. <div class="inner_head">
  416. <div class="swiper-container recomm-head"> <!--(recomm-head)슬라이드 키클래스-->
  417. <ul class="swiper-wrapper">
  418. <th:block th:each="titleData, titleStat : ${mainData.mdPickList}" >
  419. <th:block th:if="${titleData.goodsList!=null and !titleData.goodsList.empty}" >
  420. <li class="swiper-slide"> <!-- li .btn.active : 메뉴 표시 --><!--data-filter 사용 안하시면 제거하셔도 좋습니다-->
  421. <button class="btn btn_link" th:classappend="${titleStat.count==1}?'active'" th:attr="data-tab=${'recomm'+titleStat.count}" data-filter="tag_warm"><span th:text="${titleData.mdTitle}">따뜻한 무드</span></button>
  422. </li>
  423. </th:block>
  424. </th:block>
  425. </ul>
  426. </div>
  427. </div>
  428. <th:block th:each="titleData, titleStat : ${mainData.mdPickList}">
  429. <div class="inner_body">
  430. <div class="swiper-container recomm-post recomm_item" th:classappend="${titleStat.count==1}?'active'" th:id="${'recomm'+titleStat.count}">
  431. <div class="swiper-wrapper" >
  432. <th:block th:if="${titleData.goodsList!=null and !titleData.goodsList.empty}">
  433. <th:block th:each="goodsData, goodsStat : ${titleData.goodsList}">
  434. <div class="swiper-slide">
  435. <div class="item_prod">
  436. <div class="item_state">
  437. <button type="button" class="itemLike" th:classappend="${goodsData.likeIt == 'likeit'}? 'likeit' : ''" onclick="cfnPutWishList(this);" th:attr="goodsCd=${goodsData.goodsCd}, goodsNm=${goodsData.goodsFullNm}, ithrCd='', contentsLoc='SMM009', planDtlSq=''">관심상품 추가</button>
  438. <a href="javascript:void(0)" class="itemLink" th:onclick="cfnGoToGoodsDetail([[${goodsData.goodsCd}]], '', '', 'SMM009','','mo_main_m74');">
  439. <div class="itemPic">
  440. <th:block th:each="option,idx:${goodsData.videos}" th:with="videoArr=${#strings.arraySplit(idx.current,':')}">
  441. <iframe th:if="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${'https://www.youtube.com/embed/'+videoArr[1]+'?autoplay=1&mute=1'}"></iframe>
  442. <iframe th:unless="${videoArr[0]=='Y'}" id="pdThumbVideo" class="pd_mov" th:src="${kollusMediaUrl+'/'+videoArr[1]+'?enable_initialize_focus=false&autoplay&mute&controls_activation=none'}" allow="fullscreen" allowFullScreen></iframe>
  443. </th:block>
  444. <img alt="" class=" pd_img" th:src="${@environment.getProperty('upload.goods.view') + '/' + goodsData.sysImgNm}" onerror="noneImg(this)">
  445. </div>
  446. <p class="itemBrand" th:text="${goodsData.brandGroupNm}">TBJ</p>
  447. <div class="itemComment" th:if="${not #strings.isEmpty(goodsData.goodsTnm)}" th:text="${goodsData.goodsTnm}"># 가을 느낌 물씬!</div>
  448. <div class="itemName" th:text="${goodsData.goodsFullNm}">11111 남성 로고 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건 자카드 방풍 패딩 스웨터 가디건</div>
  449. <p th:unless="${goodsData.goodsType=='G056_D'}" class="itemPrice">
  450. <span class="itemPrice_original" th:if="${goodsData.currPrice != goodsData.listPrice}" th:text="${#numbers.formatInteger(goodsData.listPrice,1,'COMMA')}">89,000</span>[[${#numbers.formatInteger(goodsData.currPrice,0,'COMMA')}]]
  451. <span class=" itemPercent" th:if="${goodsData.currPrice != goodsData.listPrice}" th:text="${(goodsData.listPrice == 0 ? 0 : #numbers.formatDecimal((goodsData.listPrice - goodsData.currPrice) / (goodsData.listPrice * 1.0) * 100, 1, 0)) + '%'}">10%</span>
  452. </p>
  453. <p th:if="${goodsData.goodsType=='G056_D'}" class="itemPrice">
  454. [[${#numbers.formatInteger(goodsData.currPrice,0,'COMMA')}]] ~
  455. </p>
  456. </a>
  457. </div>
  458. </div>
  459. </div>
  460. </th:block>
  461. </th:block>
  462. </div>
  463. <!-- <span class="swiper-notification" aria-live="assertive" aria-atomic="true"></span> -->
  464. </div>
  465. </div>
  466. </th:block>
  467. </div>
  468. </div>
  469. </th:block>
  470. <th:block th:if="${contentsLoc=='010'}">
  471. <!-- 10. 당신을 위한 제안 -->
  472. <div class="inner wide">
  473. <div class="main_foryou">
  474. <div class="titWrap">
  475. <h2 th:text="${mainData.contentsTitle}">당신을 위한 제안</h2>
  476. </div>
  477. <div class="swiper-container post-sug" id="recomItemArea">
  478. </div>
  479. </div>
  480. </div>
  481. </th:block>
  482. <th:block th:if="${contentsLoc=='011'}">
  483. <!-- 11. TV 슬라이드 -->
  484. <div class="inner wide bg_dark" th:if="${mainData.ContentsList != null}">
  485. <div class="titWrap">
  486. <h2 data-style="unusual" th:text="${mainData.contentsTitle}">STYLE24 TV</h2>
  487. </div>
  488. <div class="main_tv" >
  489. <div class="swiper-container post-tv">
  490. <div class="swiper-wrapper ">
  491. <div class="swiper-slide" th:each="item, stat : ${mainData.ContentsList}">
  492. <div class="movbox">
  493. <iframe th:if="${item.strVar1=='Y'}" width="100%" height="100%" th:src="${'https://www.youtube.com/embed/'+item.strVar2+'?rel=0'}" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
  494. <iframe th:if="${item.strVar1=='M'}" class="pd_mov" th:src="${kollusMediaUrl+'/'+item.strVar2+'?enable_initialize_focus=false'}" allowfullscreen></iframe>
  495. <!-- <iframe width="100%" height="100%" src="https://www.youtube.com/embed/hGjFwebN5ks" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>-->
  496. </div>
  497. </div>
  498. </div>
  499. <div class="swiper-pagination"></div>
  500. </div>
  501. </div>
  502. </div>
  503. <!-- </th:block>-->
  504. </th:block>
  505. </th:block>
  506. </section>
  507. </main>
  508. <script th:inline="javascript">
  509. /*<![CDATA[*/
  510. var targetTime = '';
  511. if(!gagajf.isNull($("#socailForm").find("input[name=targetTime]").val())){
  512. targetTime = $("#socailForm").find("input[name=targetTime]").val().toDate("YYYYMMDD");
  513. }
  514. if(targetTime != null && targetTime != ''){
  515. /* 핫딜 countDown */
  516. var endTime = new Date(targetTime); // 남은시간 지정
  517. endTime = (Date.parse(endTime) / 1000);
  518. var countdown = document.getElementById("tiles"); // get tag element
  519. getCountdown();
  520. setInterval(function () { getCountdown(); }, 1000);
  521. function getCountdown(){
  522. // find the amount of "seconds" between now and target
  523. var now = new Date();
  524. now = (Date.parse(now) / 1000);
  525. var timeLeft = endTime - now;
  526. var days = Math.floor(timeLeft / 86400);
  527. var hours = Math.floor((timeLeft - (days * 86400)) / 3600);
  528. var minutes = Math.floor((timeLeft - (days * 86400) - (hours * 3600 )) / 60);
  529. var seconds = Math.floor((timeLeft - (days * 86400) - (hours * 3600) - (minutes * 60)));
  530. if (hours < '10') { hours = '0' + hours; }
  531. if (minutes < '10') { minutes = '0' + minutes; }
  532. if (seconds < '10') { seconds = '0' + seconds; }
  533. // format countdown string + set tag value
  534. countdown.innerHTML = "<span>" + hours + "</span><span>" + minutes + "</span><span>" + seconds + "</span>";
  535. }
  536. function pad(n) {
  537. return (n < 10 ? '0' : '') + n;
  538. }
  539. }
  540. // 스크립트 제거
  541. function fnRemoveHTML(text){
  542. var reText = text.replace(/(<br>|<br\/>|<br \/>)/g, "\n");
  543. reText = reText.replace(/<(\/)?([a-zA-Z]*)(\s[a-zA-Z]*=[^>]*)?(\s)*(\/)?>/ig, "");
  544. reText = reText.replace(/(?:\r\n|\r|\n)/g, '<br/>');
  545. return reText;
  546. }
  547. // 컨텐츠 호출
  548. $(document).ready(function() {
  549. // 당신을 위한 제안 쿠키값 확인 (로그인시 확인됨)
  550. var pcId = gagajf.getCookie("RB_PCID");
  551. fnGetEigenApi(pcId);
  552. post_visual.slideTo(2, 0, false); // 접속 시, 슬라이드페이지 이동
  553. // 몰메인 띠배너 표출
  554. $("#divTopbanner").show();
  555. setHtop();
  556. let randomNum = Math.floor( ( Math.random() * 4 ) );
  557. $(".it_nav .btn").eq(randomNum).trigger('click');
  558. // 몰메인 <br> 태그
  559. $('.mainTitle').each(function (){
  560. var brText = $(this).find("input[name=mainTitlee]").val();
  561. let tag = fnRemoveHTML(brText);
  562. $(this).append(tag);
  563. });
  564. // 몰메인 <br> 태그
  565. // $('.mainSubTitle').each(function (){
  566. // var brText = $(this).find("input[name=mainSubTitlee]").val();
  567. // let tag = fnRemoveHTML(brText);
  568. // $(this).append(tag);
  569. // });
  570. // 브랜드픽 <br> 태그
  571. $('#id007 .title').each(function (){
  572. var brText = $(this).find("input[name=title]").val();
  573. let tag = fnRemoveHTML(brText);
  574. $(this).append(tag);
  575. });
  576. // 가로긴배너 슬라이드
  577. $('.silderBannerArea').each(function (){
  578. let tag = '';
  579. if(!gagajf.isNull($(this).find("input[name=bannerNote]").val())) {
  580. var noteText = $(this).find("input[name=bannerNote]").val();
  581. tag = fnRemoveHTML(noteText);
  582. $(this).find('.noteArea').append(tag);
  583. }
  584. });
  585. // 스타일리포트 <br> 태그
  586. $('.styleArea').each(function (){
  587. let tag = '';
  588. let tag2 = '';
  589. if(!gagajf.isNull($(this).find("input[name=styleTitle]").val())) {
  590. var titleText = $(this).find("input[name=styleTitle]").val();
  591. tag = fnRemoveHTML(titleText);
  592. $(this).find('.styleTitleC').append(tag);
  593. }
  594. if(!gagajf.isNull($(this).find("input[name=styleNote]").val())) {
  595. var noteText = $(this).find("input[name=styleNote]").val();
  596. tag2 = fnRemoveHTML(noteText);
  597. $(this).find('.styleNoteC').append(tag2);
  598. }
  599. });
  600. });
  601. function setHtop() {
  602. if($('header').hasClass('main')) {
  603. $('#htopMain').show();
  604. $('#htopSub').hide();
  605. } else {
  606. $('#htopMain').hide();
  607. $('#gnb').hide();
  608. $('#htopSub').show();
  609. }
  610. }
  611. var fnNextBrand = function (tot, idx){
  612. if(tot == idx){
  613. $("#pickBtn1").click();
  614. }else{
  615. $("#pickBtn"+(idx+1)).click();
  616. }
  617. }
  618. /**
  619. * EigenApi
  620. * size : 상품수
  621. * nh : 키워드수
  622. * */
  623. var fnGetEigenApi = function (id){
  624. $.getJSON('https://api.eigene.io/rec/p075?cuid=1252aed4-78dc-46e8-b784-94ac42e86dd4&size=10&nh=10&rccode=mo_main_p75&pcid='+id, function (result,status){
  625. var keywordTag = '';
  626. var itemTag = '';
  627. let dataJson = result.groupedResults;
  628. let key1 = Object.keys(dataJson);
  629. if (status === 'success') {
  630. if (!gagajf.isNull(result.products) && result.products.length > 0) {
  631. $("#recomItemArea").html('');
  632. itemTag += '<div class="swiper-wrapper" >';
  633. $.each(result.products, function (idx, item) {
  634. if (idx == 0 || idx == 5) {
  635. itemTag += '<div class="swiper-slide';
  636. if(idx==0){
  637. itemTag += ' type1';
  638. }else{
  639. itemTag += ' type2';
  640. }
  641. itemTag += ' ">\n';
  642. itemTag += ' <ol class="list_cate">\n';
  643. }
  644. itemTag += ' <li ';
  645. if (idx == 0 || idx == 5) {
  646. itemTag += ' class="first" ';
  647. }
  648. itemTag += ' id="key'+idx+'" data-idx="'+idx+'" onclick="fnClickRecommendKey(this,\''+idx+'\');">\n';
  649. itemTag += ' <dl>\n';
  650. itemTag += ' <dt>\n';
  651. itemTag += ' <button>\n';
  652. itemTag += ' <span class="fold_rank">'+(idx+1)+'</span>\n';
  653. itemTag += ' <span class="fold_txt">'+ item.sourceId + '</span>\n';
  654. itemTag += ' </button>\n';
  655. itemTag += ' </dt>\n';
  656. itemTag += ' <dd>\n';
  657. itemTag += ' <div class="swiper-container post-sug-items">\n';
  658. itemTag += ' <div class="swiper-wrapper">\n';
  659. for (var i=0; i<key1.length; i++) {
  660. var key = key1[i];
  661. if(item.sourceId == key){
  662. $.each(dataJson[key], function (keyIdx, keyItem){
  663. itemTag += ' <div class="swiper-slide">\n';
  664. itemTag += ' <div class="item_prod">\n';
  665. itemTag += ' <div class="item_state">\n';
  666. itemTag += ' <a href="'+keyItem.product.itemUrl+'&rccode=mo_main_p75" class="itemLink">\n';
  667. itemTag += ' <div class="itemPic">\n';
  668. itemTag += ' <img alt="" class=" pd_img" src="'+keyItem.product.itemImage+'">\n';
  669. itemTag += ' </div>\n';
  670. itemTag += ' <div class="itemName">'+keyItem.product.itemName+'</div>\n';
  671. itemTag += ' <p class="itemPrice">'+keyItem.product.salePrice.addComma()+'</p>\n';
  672. itemTag += ' </a>\n';
  673. itemTag += ' </div>\n';
  674. itemTag += ' </div>\n';
  675. itemTag += ' </div>\n';
  676. });
  677. //if(i == key1.length-1){
  678. itemTag += ' <div class="swiper-slide">\n';
  679. itemTag += ' <div class="item_prod">\n';
  680. itemTag += ' <div class="item_state">\n';
  681. itemTag += ' <a href="javascript:void(0)" class="itemLink" onclick="cfnGoToSearchGoodsListForm(\''+ item.sourceId + '\')">\n';
  682. itemTag += ' <div class="itemPic">\n';
  683. itemTag += ' <span class="more_txt">더보기</span>\n';
  684. itemTag += ' </div>\n';
  685. itemTag += ' </a>\n';
  686. itemTag += ' </div>\n';
  687. itemTag += ' </div>\n';
  688. itemTag += ' </div>\n';
  689. //}
  690. }
  691. }
  692. itemTag += ' </div>\n';
  693. itemTag += ' </div>\n';
  694. itemTag += ' </dd>\n';
  695. itemTag += ' </dl>\n';
  696. itemTag += ' </li>\n';
  697. if (idx == 4 || idx == 9) {
  698. itemTag += ' </ol>\n';
  699. itemTag += '</div>\n';
  700. }
  701. });
  702. itemTag += '</div>';
  703. itemTag += '<div class="swiper-pagination"></div>';
  704. if(itemTag.indexOf('swiper-slide') >-1 ){
  705. $("#recomItemArea").html(itemTag);
  706. fnSwiperScript();
  707. }
  708. }
  709. }
  710. });
  711. }
  712. /*]]>*/
  713. </script>
  714. <script type="text/javascript">
  715. var numCnt = 0;
  716. var foryouIndex = 0;
  717. var cntNum = 0;
  718. var fnSwiperScript = function (){
  719. // post_sug
  720. var post_sug = new Swiper('.swiper-container.post-sug', {
  721. a11y: {
  722. enabled: true,
  723. notificationClass: 'swiper-notification',
  724. prevSlideMessage: '이전 슬라이드',
  725. nextSlideMessage: '다음 슬라이드',
  726. firstSlideMessage: '첫번째 슬라이드 입니다',
  727. lastSlideMessage: '마지막 슬라이드 입니다',
  728. paginationBulletMessage: '슬라이드 {{index}}로 이동',
  729. },
  730. pagination: {
  731. el: '.swiper-pagination',
  732. },
  733. // autoplay: {
  734. // delay: 24700,
  735. // disableOnInteraction: false,
  736. // },
  737. on : {
  738. slideChange: function(){
  739. foryouIndex = 0;
  740. if(numCnt === 0){
  741. $(".swiper-slide.type1 .list_cate > li").removeClass('on');
  742. $(".swiper-slide.type2 .list_cate > li").removeClass('on');
  743. $(".swiper-slide.type2 .list_cate .first").addClass('on');
  744. numCnt = 1;
  745. } else {
  746. $(".swiper-slide.type1 .list_cate > li").removeClass('on');
  747. $(".swiper-slide.type2 .list_cate > li").removeClass('on');
  748. $(".swiper-slide.type1 .list_cate .first").addClass('on');
  749. numCnt = 0;
  750. }
  751. }
  752. },
  753. });
  754. function foryouInterval(_foryouIndex) {
  755. var foryouCateItems1 = $(".main_foryou .post-sug .swiper-slide.type1.swiper-slide-active .list_cate li");
  756. var foryouCateItems2 = $(".main_foryou .post-sug .swiper-slide.type2.swiper-slide-active .list_cate li");
  757. $(".main_foryou .post-sug .swiper-slide.type1 .list_cate li").removeClass("on");
  758. $(".main_foryou .post-sug .swiper-slide.type2 .list_cate li").removeClass("on");
  759. if($(".main_foryou .post-sug .swiper-slide.type1").hasClass("swiper-slide-active")){
  760. $(foryouCateItems1[(_foryouIndex) % 5]).addClass("on");
  761. if (_foryouIndex >= 5) foryouIndex = 0;
  762. foryouIndex++;
  763. // $(foryouCateItems1).click(function () {
  764. // foryouIndex = $(this).index();
  765. // clearInterval(stopInter);
  766. // stopInter = startTimeInterval();
  767. // });
  768. }
  769. if($(".main_foryou .post-sug .swiper-slide.type2").hasClass("swiper-slide-active")){
  770. $(foryouCateItems2[(_foryouIndex) % 5]).addClass("on");
  771. if (_foryouIndex >= 5) foryouIndex = 0;
  772. foryouIndex++;
  773. // $(foryouCateItems2).click(function () {
  774. // foryouIndex = $(this).index();
  775. // clearInterval(stopInter);
  776. // stopInter = startTimeInterval();
  777. // });
  778. }
  779. }
  780. function startTimeInterval(){
  781. return setInterval(function () {
  782. foryouInterval(foryouIndex);
  783. }, 5000);
  784. }
  785. var stopInter = startTimeInterval();
  786. var post_sug_items = new Swiper ('.swiper-container.post-sug-items', {
  787. autoHeight: true, //210720_ 추가
  788. slidesPerView: 3,
  789. spaceBetween: 10,
  790. speed : 1000,
  791. a11y: {
  792. enabled: true,
  793. notificationClass: 'swiper-notification',
  794. prevSlideMessage: '이전 슬라이드',
  795. nextSlideMessage: '다음 슬라이드',
  796. firstSlideMessage: '첫번째 슬라이드 입니다',
  797. lastSlideMessage: '마지막 슬라이드 입니다',
  798. paginationBulletMessage: '슬라이드 {{index}}로 이동',
  799. },
  800. });
  801. }
  802. var fnClickRecommendKey = function (obj, key){
  803. var onIdx = '';
  804. $(".main_foryou .post-sug .swiper-slide .list_cate li").each(function (){
  805. if($(this).hasClass("on")){
  806. onIdx = $(this).attr('data-idx');
  807. $(this).removeClass("on");
  808. }
  809. });
  810. if(onIdx == key){
  811. $("#key"+key).removeClass("on");
  812. }else{
  813. $("#key"+key).addClass("on");
  814. }
  815. $(".main_foryou .post-sug .swiper-slide .list_cate li").each(function (){
  816. if($(this).hasClass("on")){
  817. foryouIndex = $(this).attr('data-idx');
  818. }
  819. });
  820. }
  821. </script>
  822. <script type="text/javascript">
  823. //210624_ 추가 : 슬라이드 속성 추가.
  824. // post-visual
  825. // 비주얼 슬라이드 카운팅
  826. var pickvisualCont = $('.post-visual .swiper-slide');
  827. var pickvisualLength = pickvisualCont.length;
  828. if (pickvisualLength < 2) {
  829. // $(".main_visual .swiper-pagination").css({"display": "none"});
  830. var post_visual = new Swiper('.swiper-container.post-visual', {
  831. autoplay: false,
  832. loop:false,
  833. speed:1000,
  834. // pagination: false,
  835. a11y: {
  836. enabled: true,
  837. notificationClass: 'swiper-notification',
  838. prevSlideMessage: '이전 슬라이드',
  839. nextSlideMessage: '다음 슬라이드',
  840. firstSlideMessage: '첫번째 슬라이드 입니다',
  841. lastSlideMessage: '마지막 슬라이드 입니다',
  842. paginationBulletMessage: '슬라이드 {{index}}로 이동',
  843. },
  844. pagination: {
  845. el: '.swiper-pagination',
  846. type: 'fraction',
  847. },
  848. });
  849. } else {
  850. var post_visual = new Swiper('.swiper-container.post-visual', {
  851. slideTo: 2,
  852. speed:1000,
  853. autoplay: {
  854. delay: 3000,
  855. disableOnInteraction: false,
  856. },
  857. loop:true,
  858. pagination: {
  859. el: '.swiper-pagination',
  860. type: 'fraction',
  861. },
  862. });
  863. }
  864. // post-trendy
  865. var post_trendy = new Swiper('.swiper-container.post-trendy', {
  866. speed:1000,
  867. a11y: {
  868. enabled: true,
  869. notificationClass: 'swiper-notification',
  870. prevSlideMessage: '이전 슬라이드',
  871. nextSlideMessage: '다음 슬라이드',
  872. firstSlideMessage: '첫번째 슬라이드 입니다',
  873. lastSlideMessage: '마지막 슬라이드 입니다',
  874. paginationBulletMessage: '슬라이드 {{index}}로 이동',
  875. },
  876. pagination: {
  877. el: '.swiper-pagination',
  878. },
  879. });
  880. // post-it
  881. var post_it = new Swiper('.swiper-container.post-it', {
  882. slidesPerView: 2.22,
  883. spaceBetween: 8,
  884. observer: true,
  885. observeParents: true,
  886. speed : 1000,
  887. freeMode: true,
  888. autoplay: false,
  889. });
  890. $(".it_nav .btn").click(function(){
  891. var itActive = $(this).attr('data-tab');
  892. $(".it_nav .btn").removeClass('active');
  893. $(".it_item").removeClass('active');
  894. $(this).addClass('active');
  895. $('#'+itActive).addClass('active');
  896. });
  897. // post-stylereport
  898. var post_stylereport = new Swiper('.swiper-container.post-stylereport', {
  899. slidesPerView: 1,
  900. speed:1000,
  901. a11y: {
  902. enabled: true,
  903. notificationClass: 'swiper-notification',
  904. prevSlideMessage: '이전 슬라이드',
  905. nextSlideMessage: '다음 슬라이드',
  906. firstSlideMessage: '첫번째 슬라이드 입니다',
  907. lastSlideMessage: '마지막 슬라이드 입니다',
  908. paginationBulletMessage: '슬라이드 {{index}}로 이동',
  909. },
  910. pagination: {
  911. el: '.swiper-pagination',
  912. },
  913. spaceBetween: 8,
  914. });
  915. //post-deal
  916. var post_deal = new Swiper('.swiper-container.post-deal', {
  917. slidesPerView: 2.22,
  918. spaceBetween: 8,
  919. observer: true,
  920. observeParents: true,
  921. speed : 1000,
  922. freeMode: true,
  923. autoplay: false,
  924. });
  925. //post-pick
  926. //post-pick-head
  927. var Head_pick = new Swiper(".pick-head", {
  928. slidesPerView: "auto",
  929. spaceBetween: 0,
  930. autoHeight: true,
  931. preventClicks: true,
  932. preventClicksPropagation: false,
  933. observer: true,
  934. observeParents: true
  935. });
  936. var $pickHd = $('.pick-head .swiper-wrapper .swiper-slide .btn');
  937. $pickHd.click(function(){
  938. var target = $(this).parent();
  939. $pickHd.parent().removeClass('on')
  940. target.addClass('on');
  941. muCenter(target);
  942. })
  943. function muCenter(target){
  944. var snbwrap = $('.pick-head .swiper-wrapper');
  945. var targetPos = target.position();
  946. var box = $('.pick-head');
  947. var boxHarf = box.width()/2;
  948. var pos;
  949. var listWidth=0;
  950. snbwrap.find('.swiper-slide').each(function(){ listWidth += $(this).outerWidth(); })
  951. var selectTargetPos = targetPos.left + target.outerWidth()/2;
  952. if (selectTargetPos <= boxHarf) { // left
  953. pos = 0;
  954. }else if ((listWidth - selectTargetPos) <= boxHarf) { //right
  955. pos = listWidth-box.width();
  956. }else {
  957. pos = selectTargetPos - boxHarf;
  958. }
  959. setTimeout(function(){snbwrap.css({
  960. "transform": "translate3d("+ (pos*-1) +"px, 0, 0)",
  961. "transition-duration": "500ms"
  962. })}, 200);
  963. }
  964. $(".pick-head li .btn").click(function(){
  965. var itActive = $(this).attr('data-tab');
  966. $(".pick-head li .btn").removeClass('active');
  967. $(".pick-cont").removeClass('active');
  968. $(this).addClass('active');
  969. $('#'+itActive).addClass('active');
  970. });
  971. //post-pick-post
  972. var post_pick = new Swiper(".pick-cont .swiper-container", {
  973. //slidesPerView: 1,
  974. loop:true,
  975. // watchOverflow:true,
  976. //210520_ 추가 : 슬라이드 1개일 경우 롤링 제거.
  977. speed: 1000,
  978. //210520_ 추가 : 자동재생 시간 추가.
  979. autoplay: {
  980. delay: 3000,
  981. disableOnInteraction: false,
  982. },
  983. a11y: {
  984. enabled: true,
  985. notificationClass: 'swiper-notification',
  986. prevSlideMessage: '이전 슬라이드',
  987. nextSlideMessage: '다음 슬라이드',
  988. firstSlideMessage: '첫번째 슬라이드 입니다',
  989. lastSlideMessage: '마지막 슬라이드 입니다',
  990. paginationBulletMessage: '슬라이드 {{index}}로 이동',
  991. },
  992. observer: true,
  993. observeParents: true
  994. });
  995. // post-recomm
  996. // recomm-head
  997. var Head_recomm = new Swiper(".swiper-container.recomm-head", {
  998. slidesPerView: "auto",
  999. spaceBetween: 10,
  1000. autoHeight: true,
  1001. loop:false,
  1002. a11y: {
  1003. enabled: true,
  1004. notificationClass: 'swiper-notification',
  1005. prevSlideMessage: '이전 슬라이드',
  1006. nextSlideMessage: '다음 슬라이드',
  1007. firstSlideMessage: '첫번째 슬라이드 입니다',
  1008. lastSlideMessage: '마지막 슬라이드 입니다',
  1009. paginationBulletMessage: '슬라이드 {{index}}로 이동',
  1010. },
  1011. });
  1012. $(".recomm-head li .btn").click(function(){
  1013. var recommActive = $(this).attr('data-tab');
  1014. $(".recomm-head li .btn").removeClass('active');
  1015. $(".recomm-post").removeClass('active');
  1016. $(this).addClass('active');
  1017. $('#'+recommActive).addClass('active');
  1018. });
  1019. // recomm-post
  1020. var post_recomm = new Swiper(".recomm-post", {
  1021. slidesPerView: 2.22,
  1022. spaceBetween: 8,
  1023. observer: true,
  1024. observeParents: true,
  1025. speed : 1000,
  1026. freeMode: true,
  1027. autoplay: false,
  1028. });
  1029. //210705_수정 : 기획전 배너 2개이상 등록시 슬라이드 각각 실행.
  1030. // post-bnnWide
  1031. // 와이드배너 슬라이드 카운팅
  1032. $(".main_1stage .post-bnnWide").each(function(index){
  1033. var pickbnnWdCont = $(this).find('.swiper-slide');
  1034. var pickbnnWdLength = pickbnnWdCont.length;
  1035. if (pickbnnWdLength < 2) {
  1036. var post_bnnWide = new Swiper ($(this), {
  1037. loop: false,
  1038. watchOverflow: true,
  1039. autoplay: false,
  1040. pagination: false,
  1041. });
  1042. } else {
  1043. var post_bnnWide = new Swiper ($(this), {
  1044. loop: true,
  1045. slidesPerView: 1,
  1046. speed : 1000,
  1047. autoplay: {
  1048. delay: 3000,
  1049. disableOnInteraction: false,
  1050. },
  1051. pagination: {
  1052. el: '.swiper-pagination',
  1053. },
  1054. });
  1055. }
  1056. });
  1057. // post-bnnEvent
  1058. // 이벤트배너 슬라이드 카운팅
  1059. var pickbnnEvCont = $('.post-bnnEvent .swiper-slide');
  1060. var pickbnnEvLength = pickbnnEvCont.length;
  1061. if (pickbnnEvLength < 2) {
  1062. var post_bnnEvent = new Swiper ('.swiper-container.post-bnnEvent', {
  1063. loop: false,
  1064. speed : 1000,
  1065. autoplay: false,
  1066. pagination:false,
  1067. });
  1068. } else {
  1069. var post_bnnEvent = new Swiper ('.swiper-container.post-bnnEvent', {
  1070. loop: true,
  1071. slidesPerView: 1,
  1072. speed : 1000,
  1073. autoplay: {
  1074. delay: 3000,
  1075. disableOnInteraction: false,
  1076. },
  1077. pagination: {
  1078. el: '.swiper-pagination',
  1079. },
  1080. });
  1081. }
  1082. // post-tv
  1083. var post_tv = new Swiper ('.post-tv', {
  1084. loop: true,
  1085. centeredSlides: true,
  1086. speed : 1000,
  1087. autoplay: false,
  1088. pagination: {
  1089. el: '.main_tv .swiper-pagination',
  1090. clickable: true,
  1091. },
  1092. });
  1093. </script>
  1094. <!-- Criteo 홈페이지 태그 -->
  1095. <script type="text/javascript">
  1096. window.criteo_q = window.criteo_q || [];
  1097. var deviceType = /iPad/.test(navigator.userAgent) ? "t" : /Mobile|iP(hone|od)|Android|BlackBerry|IEMobile|Silk/.test(navigator.userAgent) ? "m" : "d";
  1098. window.criteo_q.push(
  1099. { event: "setAccount", account: 6762}, // 이 라인은 업데이트하면 안됩니다
  1100. { event: "setEmail", email: criteoEmail }, // 빈 문자일 수 있습니다
  1101. { event: "setSiteType", type: deviceType},
  1102. { event: "viewHome"});
  1103. </script>
  1104. <!--// Criteo 홈페이지 태그 -->
  1105. <!-- Enliple(모비온) Insite naver Quick start -->
  1106. <script type="text/javascript">
  1107. // 인사이트 마케팅
  1108. (function(m,b,r,i,s){m.mbris=m.mbris||function(){(m.mbris.q=m.mbris.q||[]).push(arguments)};i=b.createElement(r);i.async=!0;i.defer=!0;i.src="https://cdn.megadata.co.kr/dist/prod/enp_mbris.min.js";0<b.querySelectorAll("script[src*=enp_mbris]").length&&m.ENP_MBRIS_INVOKE?m.ENP_MBRIS_INVOKE():(s=b.getElementsByTagName(r)[0],s.parentNode.insertBefore(i,s))})(window,document,"script");mbris("202108222155731618_is24_1_01,202108222155731619_is24_1_02");
  1109. // 네이버 인사이트 지연
  1110. (function(m,b,r,i,s){m.mbris=m.mbris||function(){(m.mbris.q=m.mbris.q||[]).push(arguments)};i=b.createElement(r);i.async=!0;i.defer=!0;i.src="https://cdn.megadata.co.kr/dist/prod/enp_mbris.min.js";0<b.querySelectorAll("script[src*=enp_mbris]").length&&m.ENP_MBRIS_INVOKE?m.ENP_MBRIS_INVOKE():(s=b.getElementsByTagName(r)[0],s.parentNode.insertBefore(i,s))})(window,document,"script");mbris("202108222155731624_is24_6_01,202108222155731624_is24_6_02");
  1111. </script>
  1112. <!--// Enliple(모비온) Insite naver Quick end -->
  1113. </th:block>
  1114. </body>
  1115. </html>