Authored by 梁志锋

update

@@ -85,6 +85,7 @@ $('.sub-nav').on('mouseenter', 'li', function () { @@ -85,6 +85,7 @@ $('.sub-nav').on('mouseenter', 'li', function () {
85 if ($('.banner-swiper').find('li').size() > 1) { 85 if ($('.banner-swiper').find('li').size() > 1) {
86 bannerSwiper = new Swiper('.banner-swiper', { 86 bannerSwiper = new Swiper('.banner-swiper', {
87 lazyLoading: true, 87 lazyLoading: true,
  88 + lazyLoadingInPrevNext: true,
88 loop: true, 89 loop: true,
89 autoplay: 3000, 90 autoplay: 3000,
90 autoplayDisableOnInteraction: false, 91 autoplayDisableOnInteraction: false,
@@ -53,7 +53,7 @@ var $listNav = $('#list-nav'), @@ -53,7 +53,7 @@ var $listNav = $('#list-nav'),
53 end: false 53 end: false
54 } 54 }
55 }, 55 },
56 - $pre, //纪录进入筛选前的active 56 + $pre = $listNav.find('.active'), //纪录进入筛选前的active项,初始为选中
57 searching; 57 searching;
58 58
59 if ($('.swiper-container .swiper-slide').length > 1) { 59 if ($('.swiper-container .swiper-slide').length > 1) {
@@ -29,7 +29,7 @@ @@ -29,7 +29,7 @@
29 29
30 <div id="goods-container" class="goods-container"> 30 <div id="goods-container" class="goods-container">
31 {{# goodsContainer}} 31 {{# goodsContainer}}
32 - <div class="new-goods container"> 32 + <div class="new-goods container clearfix">
33 {{#if goods}} 33 {{#if goods}}
34 {{# goods}} 34 {{# goods}}
35 {{> good}} 35 {{> good}}
@@ -39,7 +39,7 @@ @@ -39,7 +39,7 @@
39 39
40 <div id="goods-container" class="goods-container"> 40 <div id="goods-container" class="goods-container">
41 {{# goodsContainer}} 41 {{# goodsContainer}}
42 - <div class="new-goods container"> 42 + <div class="new-goods container clearfix">
43 {{#if goods}} 43 {{#if goods}}
44 {{# goods}} 44 {{# goods}}
45 {{> good}} 45 {{> good}}
@@ -48,8 +48,8 @@ @@ -48,8 +48,8 @@
48 <p class="no-result">未找到相关搜索结果</p> 48 <p class="no-result">未找到相关搜索结果</p>
49 {{/if}} 49 {{/if}}
50 </div> 50 </div>
51 - <div class="price-goods container hide"></div>  
52 - <div class="discount-goods container hide"></div> 51 + <div class="price-goods container hide clearfix"></div>
  52 + <div class="discount-goods container hide clearfix"></div>
53 {{/ goodsContainer}} 53 {{/ goodsContainer}}
54 54
55 {{> filter}} 55 {{> filter}}
1 <div class="banner-top"> 1 <div class="banner-top">
2 <div class="banner-swiper swiper-container"> 2 <div class="banner-swiper swiper-container">
3 <ul class="swiper-wrapper"> 3 <ul class="swiper-wrapper">
4 - {{# list}}  
5 - <li class="swiper-slide">  
6 - <a href="{{url}}">  
7 - <img class="swiper-lazy" data-src="{{img}}">  
8 - </a>  
9 - <div class="swiper-lazy-preloader"></div>  
10 - </li>  
11 - {{/ list}} 4 + {{#each list}}
  5 + {{#if @first}}
  6 + <li class="swiper-slide">
  7 + <a href="{{url}}">
  8 + <img src="{{img}}">
  9 + </a>
  10 + </li>
  11 + {{^}}
  12 + <li class="swiper-slide">
  13 + <a href="{{url}}">
  14 + <img class="swiper-lazy" data-src="{{img}}">
  15 + </a>
  16 + <div class="swiper-lazy-preloader"></div>
  17 + </li>
  18 + {{/if}}
  19 + {{/each}}
12 </ul> 20 </ul>
13 </div> 21 </div>
14 <div class="swiper-pagination"> 22 <div class="swiper-pagination">
1 <div class="icons-wrapper"> 1 <div class="icons-wrapper">
2 <ul class="icons-list clearfix"> 2 <ul class="icons-list clearfix">
3 {{#list}} 3 {{#list}}
4 - <li class="icons-item"><a href="{{url}}" class="imagebar"><img class="lazy" data-original="{{img}}" alt=""></a><a href="{{url}}" class="linkbar">{{title}}</a></li> 4 + <li class="icons-item"><a href="{{url}}" class="imagebar"><img src="{{img}}" alt=""></a><a href="{{url}}" class="linkbar">{{title}}</a></li>
5 {{/list}} 5 {{/list}}
6 </ul> 6 </ul>
7 -</div>  
  7 +</div>