|
|
@@ -97,8 +97,8 @@
|
|
|
<span class="sale_percent" th:if="${goodsInfo.dcRate > 0}" th:text="|${#numbers.formatDecimal(goodsInfo.dcRate,0,0)}%|">30%</span>
|
|
|
</p>
|
|
|
<p class="save_point" th:if="${goodsInfo.pntAmt > 0}">스타일포인트 <th:block th:text="${#numbers.formatInteger(goodsInfo.pntAmt, 0,'COMMA')}"></th:block>P 적립예정</p>
|
|
|
- <div class="btn_group_flex">
|
|
|
- <div><button type="button" class="btn btn_default" id="btn_saleCoupon_pop" th:if="${goodsCouponList != null and !goodsCouponList.empty}" th:onclick="cfGoodsCouponInfo([[${goodsInfo.goodsCd}]],[[${goodsInfo.goodsType}]])">쿠폰받기</button></div>
|
|
|
+ <div class="btn_group_flex" th:if="${goodsCouponList != null and !goodsCouponList.empty}">
|
|
|
+ <div><button type="button" class="btn btn_default" id="btn_saleCoupon_pop" th:onclick="cfGoodsCouponInfo([[${goodsInfo.goodsCd}]],[[${goodsInfo.goodsType}]])">쿠폰받기</button></div>
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
@@ -635,7 +635,12 @@
|
|
|
<th:block th:if="${bestReview.reviewAttachList != null and !bestReview.reviewAttachList.empty}">
|
|
|
<div class="pic" >
|
|
|
<th:block th:each="reviewAttach, attachStatus : ${bestReview.reviewAttachList}" th:if="${attachStatus.first}">
|
|
|
- <span class="thumb " th:classAppend="${(reviewAttach.fileGb == 'M') ? 'mov' :''}" th:style="${'background-image:url('+imgUrl+ reviewAttach.sysFileNm+');'}"></span><!-- 동영상의 썸네일일 경우 mov 클래스 추가 -->
|
|
|
+ <th:block th:if="${reviewAttach.fileGb == 'M'}" >
|
|
|
+ <span class="thumb mov" th:style="${'background-image:url('+kollusMediaUrl+'/poster/'+reviewAttach.kmcKey+');'}"></span><!-- 동영상의 썸네일일 경우 mov 클래스 추가 -->
|
|
|
+ </th:block>
|
|
|
+ <th:block th:unless="${reviewAttach.fileGb == 'M'}" >
|
|
|
+ <span class="thumb" th:style="${'background-image:url('+imgUrl+ reviewAttach.sysFileNm+');'}"></span>
|
|
|
+ </th:block>
|
|
|
</th:block>
|
|
|
</div>
|
|
|
</th:block>
|
|
|
@@ -824,15 +829,20 @@
|
|
|
</span>
|
|
|
</div>
|
|
|
<div class="form_field">
|
|
|
- <th:block th:each="goodsOption2, status : ${goodsOption2List}"> <!-- 품절사이즈 미노출 -->
|
|
|
- <th:block th:if="${goodsOption2.soldoutYn == 'N' and goodsOption2.stockQty > 0}">
|
|
|
+ <th:block th:each="goodsOption2, status : ${goodsOption2List}">
|
|
|
<div>
|
|
|
- <input type="radio" name="opt" th:id="${goodsOption2.optCd}"
|
|
|
+ <th:block th:if="${goodsOption2.soldoutYn == 'Y' or goodsOption2.stockQty <= 0}" >
|
|
|
+ <input type="radio" name="opt" th:id="${goodsOption2.optCd}" th:disabled="${goodsOption2.soldoutYn == 'Y' or goodsOption2.stockQty <= 0}"
|
|
|
+ th:attr="addPrice=${goodsOption2.addPrice}, optCd1=${goodsOption2.optCd1}, optCd2=${goodsOption2.optCd2}, optCd=${goodsOption2.optCd}"/>
|
|
|
+ <label th:for="${goodsOption2.optCd}" ><span th:text="${goodsOption2.optCd2}">90</span></label>
|
|
|
+ </th:block>
|
|
|
+ <th:block th:unless="${goodsOption2.soldoutYn == 'Y' or goodsOption2.stockQty <= 0}" >
|
|
|
+ <input type="radio" name="opt" th:id="${goodsOption2.optCd}" th:disabled="${goodsOption2.soldoutYn == 'Y' or goodsOption2.stockQty <= 0}"
|
|
|
th:attr="addPrice=${goodsOption2.addPrice}, optCd1=${goodsOption2.optCd1}, optCd2=${goodsOption2.optCd2}, optCd=${goodsOption2.optCd}"/>
|
|
|
<label th:for="${goodsOption2.optCd}" th:onclick="fnViewStock(this, [[${goodsInfo.goodsCd}]],[[${goodsOption2.optCd}]],[[${goodsOption2.optCd1}]],[[${goodsOption2.optCd2}]],[[${goodsInfo.minOrdQty}]], [[${goodsInfo.maxOrdQty}]] )" ><span th:text="${goodsOption2.optCd2}">90</span></label>
|
|
|
+ </th:block>
|
|
|
</div>
|
|
|
</th:block>
|
|
|
- </th:block>
|
|
|
</div>
|
|
|
</div>
|
|
|
<!-- 해당상품 품절시 노출 -->
|
|
|
@@ -844,8 +854,7 @@
|
|
|
</div>
|
|
|
<div class="number_count">
|
|
|
<span class="minus min_val" onclick="fnAdjustOrderEa(this);" adjust="-"><em class="sr-only">감소</em></a></span>
|
|
|
- <input type="text" name="cea" maxlength="3" style="ime-mode:disabled" th:value="${goodsInfo.minOrdQty}" onblur="fnChangeOrderEa(this)"
|
|
|
- th:attr="minOrdQty=${goodsInfo.minOrdQty}, maxOrdQty=${goodsInfo.maxOrdQty}" data-valid-type="numeric">
|
|
|
+ <input type="text" name="cea" maxlength="3" style="ime-mode:disabled" th:value="${goodsInfo.minOrdQty}" readonly>
|
|
|
<input type="hidden" name="coption" value="" th:attr="price=${goodsInfo.currPrice}">
|
|
|
<span class="plus" onclick="fnAdjustOrderEa(this);" adjust="+"><em class="sr-only">추가</em></span>
|
|
|
</div>
|
|
|
@@ -1090,6 +1099,72 @@
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ //사이즈 클릭시 - 단품
|
|
|
+ var fnViewStock = function(obj, goodsCd, optCd, optCd1, optCd2, minOrdQty, maxOrdQty) {
|
|
|
+ let $obj = $(obj);
|
|
|
+ let selfGoodsYn = $("#cartForm input[name=selfGoodsYn]").val();
|
|
|
+ let $target = null;
|
|
|
+ if (selfGoodsYn == "Y"){
|
|
|
+ //$target = $obj;
|
|
|
+ $target = $obj.parent().find('input[name=opt]');
|
|
|
+ $target.prop("checked",true);
|
|
|
+ $(".selectOptCd1").html(optCd2);
|
|
|
+ }else{
|
|
|
+ $target = $obj.find('input[name="opt2"]');
|
|
|
+ }
|
|
|
+
|
|
|
+ let addPrice = $target.attr("addPrice");
|
|
|
+ $(".selectOptCd1addPrice").html('');
|
|
|
+ if (Number(addPrice) > 0) $(".selectOptCd1addPrice").html("(+" + addPrice.addComma() + ")");
|
|
|
+
|
|
|
+ $("#cartForm input[name=optCd]").val(optCd);
|
|
|
+ $("#cartForm input[name=optCd1]").val(optCd1);
|
|
|
+ $("#cartForm input[name=optCd2]").val(optCd2);
|
|
|
+ $("#cartForm input[name=addPrice]").val(addPrice);
|
|
|
+ $("#cartForm input[name=ordQty]").val("");
|
|
|
+
|
|
|
+ let maxCnt = maxOrdQty;
|
|
|
+ let params = new Object();
|
|
|
+ params.goodsCd = goodsCd;
|
|
|
+ params.optCd = optCd;
|
|
|
+ params.optCd1 = optCd1;
|
|
|
+ params.optCd2 = optCd2;
|
|
|
+ params.selfGoodsYn = selfGoodsYn;
|
|
|
+
|
|
|
+ $.get("/goods/detail/ajaxGoodsStockQty", $.param(params), function(result) {
|
|
|
+ let itemCnt = eval(result); //해당 아이템에 선택되어진 사이즈의 수량
|
|
|
+
|
|
|
+ if (maxCnt > itemCnt) {
|
|
|
+ maxCnt = itemCnt;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (minOrdQty > itemCnt) {
|
|
|
+ $target.prop("disabled", true);
|
|
|
+ }else{
|
|
|
+ $("#cartForm input[name=ordQty]").val(minOrdQty);
|
|
|
+ $("#cartForm input[name=maxOrdQty]").val(maxCnt);
|
|
|
+ $("#cartForm input[name=minOrdQty]").val(minOrdQty);
|
|
|
+ $("#cartForm input[name=cea]").val(minOrdQty);
|
|
|
+ $("#cartForm input[name=cea]").attr("readonly",false);
|
|
|
+ $("#cartForm input[name=stock]").val(itemCnt);
|
|
|
+
|
|
|
+ $('.price_box').show();
|
|
|
+ fnSetTotalPrice();
|
|
|
+
|
|
|
+ // 모바일에서 작업해야함
|
|
|
+ if ('P' != _frontGb) {
|
|
|
+ $("#cartForm input[name=opt]").parent().find('label').removeClass('on');
|
|
|
+ $("#cartForm input[name=opt]").each(function(){
|
|
|
+ if ($(this).attr('optCd') == optCd){
|
|
|
+ $(this).parent().find('label').addClass('on');
|
|
|
+ }
|
|
|
+ });
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ }, "text");
|
|
|
+ }
|
|
|
+
|
|
|
//사이즈 클릭시 - 입점단품
|
|
|
var fnViewStockSelfNo = function(obj) {
|
|
|
|
|
|
@@ -1671,13 +1746,23 @@
|
|
|
$('input[name="cea"]').each(function() {
|
|
|
let ea = parseInt($(this).val());
|
|
|
let addPrice = 0;
|
|
|
- let target=$('.select_custom.item_opt2');
|
|
|
- target.each(function() {
|
|
|
- if (typeof ($(this).find('input[name=opt2]').val()) != 'undefined' && !gagajf.isNull($(this).find('input[name=opt2]').val())){
|
|
|
- addPrice += Number($(this).find('input[name=opt2]').attr('addPrice'));
|
|
|
- }
|
|
|
- });
|
|
|
|
|
|
+ if("G056_N" == $("#cartForm input[name=goodsType]").val() && "Y" == $("#cartForm input[name=selfGoodsYn]").val()){
|
|
|
+ let target=$('.opt_size').find('input[name=opt]');
|
|
|
+ target.each(function() {
|
|
|
+ if ($(this).is(":checked")){
|
|
|
+ addPrice += Number($(this).attr('addPrice'));
|
|
|
+ }
|
|
|
+ });
|
|
|
+ }else{
|
|
|
+
|
|
|
+ let target=$('.select_custom.item_opt2');
|
|
|
+ target.each(function() {
|
|
|
+ if (typeof ($(this).find('input[name=opt2]').val()) != 'undefined' && !gagajf.isNull($(this).find('input[name=opt2]').val())){
|
|
|
+ addPrice += Number($(this).find('input[name=opt2]').attr('addPrice'));
|
|
|
+ }
|
|
|
+ });
|
|
|
+ }
|
|
|
let goodsPrice = parseInt($(this).parent().find('input[name="coption"]').attr('price'));
|
|
|
|
|
|
totalEa += ea;
|
|
|
@@ -1963,13 +2048,12 @@
|
|
|
$(document).on('click','.pd_descrp .btn_more_box button',function(e){
|
|
|
$('.pd_descrp .cont_body').toggleClass('on');
|
|
|
$(this).toggleClass('active');
|
|
|
- $(this).parent('.btn_more_box').toggleClass('covered');
|
|
|
+ $(this).parents('.btn_more_box').toggleClass('covered');
|
|
|
var descrpToggle = $(this).find('span');
|
|
|
$(descrpToggle).text($(descrpToggle).text() == '상세정보 더보기' ? '상세정보 접기' : '상세정보 더보기');
|
|
|
return false;
|
|
|
});
|
|
|
|
|
|
-
|
|
|
|
|
|
//슬라이드 - 함께하면 할인되는 다다익선 상품
|
|
|
var togetherItemSwiper = new Swiper('.pd .pd_together .area_slider .swiper-container', {
|