Authored by ccbikai(👎🏻🍜)

Merge branch 'release/5.2' into gray

... ... @@ -15,7 +15,7 @@
<div class="field">
<label for="identityCardNo">身份证号:</label>
<input id="identityCardNo" name="identityCardNo" type="text" placeholder="请填写身份证号" maxlength="18"/>
<input id="identityCardNo" name="identityCardNo" type="tel" placeholder="请填写身份证号" maxlength="18"/>
<div class="clearfix"></div>
</div>
... ...
... ... @@ -184,7 +184,7 @@ const search = (req, res, next) => {
params.isApp = req.yoho.isApp;
searchModel.getSearchData(params).then((result) => {
if (result.list.length > 0) {
if (result.list && result.list.length > 0) {
res.render('search/page', {
layout: false,
new: result.list,
... ...
{{#if singleOne}}
{{#data}}
<div class="banner-list">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</div>
{{/data}}
{{else}}
<div class="banner-center banner-center-swiper">
{{#if singleOne}}
<ul class="banner-list swiper-wrapper clearfix">
{{#data}}
<div class="banner-list">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</div>
<li class="swiper-slide">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</li>
{{/data}}
{{else}}
<ul class="banner-list swiper-wrapper clearfix">
{{#data}}
<li class="swiper-slide">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</li>
{{/data}}
</ul>
{{/if}}
</ul>
<div class="swiper-pagination" {{#unless singleOne}}style="display:block"{{/unless}}>
<div class="pagination-inner">
</div>
</div>
</div>
{{/if}}
... ...
{{#if banner_image.[1]}}
<div class="banner-center banner-center-swiper" style="border: 0;">
{{#if banner_image.[1]}}
<ul class="banner-list swiper-wrapper clearfix">
{{#banner_image}}
<li class="swiper-slide">
... ... @@ -9,17 +9,17 @@
</li>
{{/banner_image}}
</ul>
{{else}}
{{#banner_image}}
<div class="banner-list">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</div>
{{/banner_image}}
{{/if}}
<div class="swiper-pagination" {{#if banner_image.[1]}}style="display:block"{{/if}}>
<div class="pagination-inner">
</div>
</div>
</div>
\ No newline at end of file
</div>
{{else}}
{{#banner_image}}
<div class="banner-list single-one">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</div>
{{/banner_image}}
{{/if}}
\ No newline at end of file
... ...
... ... @@ -112,16 +112,22 @@ if ($('.banner-swiper').find('li').size() > 1) {
}
// single_image的轮播
if ($('.banner-center-swiper').find('li').size() > 1) {
new Swiper('.banner-center-swiper', {
loop: true,
autoplay: 3000,
autoplayDisableOnInteraction: false,
paginationClickable: true,
slideElement: 'li',
pagination: '.banner-center .pagination-inner'
});
}
$('.banner-center-swiper').each(function() {
if ($(this).find('li').size() > 1) {
new Swiper('.banner-center-swiper', {
loop: true,
autoplay: 3000,
autoplayDisableOnInteraction: false,
paginationClickable: true,
slideElement: 'li',
pagination: '.banner-center .pagination-inner',
});
} else {
$(this).unbind();
}
});
// 热门品牌滑动
new Swiper('.brands-swiper', {
... ... @@ -245,6 +251,7 @@ var checkShop = function() {
$('.recom-shop').each(function() {
shopIds.push($(this).attr('shopId'));
});
shopIds.length &&
$.ajax({
type: 'POST',
url: '/channel/shopRecom',
... ...
... ... @@ -2,6 +2,8 @@
position: relative;
height: 200px;
overflow: hidden;
margin-bottom: -2PX;
z-index: 2;
img {
display: block;
... ... @@ -75,3 +77,8 @@
}
}
}
.single-one {
margin-bottom: -2PX;
z-index: 2;
}
... ...
.banner-top {
position: relative;
margin-bottom: -2PX;
.swiper-pagination {
position: absolute;
... ...