Authored by 梁志锋

购物车提示框只显示一次

... ... @@ -69,8 +69,10 @@ require('./good');
lazyLoad($('img.lazy'));
if (typeof window.cookie === 'function' && 'y' === window.cookie('_hasShowCartPresellTip')) {
$('#presell-tip').addClass('hide');
$('#presell-tip').removeClass('show').addClass('hide');
hasShowCartPresellTip = true;
} else {
$('#presell-tip').removeClass('hide').addClass('show');
}
if ('advance' === cartType) {
... ... @@ -108,9 +110,9 @@ if ($('.cart-nav').length > 0) {
$(window).trigger('scroll');
});
if(!hasShowCartPresellTip) {
if (!hasShowCartPresellTip) {
setTimeout(function() {
$('#presell-tip').addClass('hide');
$('#presell-tip').removeClass('show').addClass('hide');
window.setCookie('_hasShowCartPresellTip', 'y');
}, 3000);
}
... ...
... ... @@ -32,13 +32,16 @@ function showFooter() {
}, 200);
}
if ($('#goodsDiscount h1').length < 1) {
$('.dropdown').remove();
}
showFooter();
require('./like');
lazyLoad($('img.lazy'));
if ($('#goodsDiscount h1').length < 1) {
$('.dropdown').remove();
}
//顶部swiper
goodsSwiper = new Swiper('.banner-swiper', {
lazyLoading: true,
... ... @@ -100,4 +103,4 @@ if ($('.good-detail-page').length > 0) {
$('#yoho-footer').css('border-top', '1px solid #e0e0e0');
}
require('./like');
... ...
... ... @@ -28,7 +28,7 @@
<span id="presell-cart-nav">
预售商品({{presellGoodsCount}})
</span>
<div id="presell-tip" class="presell-tip">
<div id="presell-tip" class="presell-tip hide">
<div class="triangle"></div>
<p class="pt-content">预售商品点这里结算哦~</p>
</div>
... ...