Authored by ccbikai

Merge branch 'feature/sale' into release/4.8

... ... @@ -182,6 +182,14 @@ let search = (req, res, next) => {
let params = Object.assign({}, req.query);
let uid = req.user.uid || 0;
// 断码区域必须传尺码
if (params.saleType === '1' && (!params.breakSort || !params.breakSize)) {
return res.render('sale/product', {
layout: false,
params: params
});
}
saleModel.getSearchData(params, uid).then((result) => {
let vipLevel = result[1].curLevel;
let vipObj = {};
... ...
... ... @@ -523,6 +523,7 @@ $(window).scroll(function() {
$(function() {
var type = window.queryString.type;
var selector;
var $selectNav;
// type 1: 上装, 3:下装, 6: 鞋装
if (type && type !== '1') {
... ... @@ -530,13 +531,14 @@ $(function() {
} else {
selector = '.coat';
}
$('#list-nav').find(selector).addClass('active').siblings().removeClass('active');
$selectNav = $('#list-nav').find(selector);
$selectNav.addClass('active').siblings().removeClass('active');
search([{
type: 'breakSort',
id: $(selector).data('id')
id: $selectNav.data('id')
}, {
type: 'breakSize',
id: $(selector).data('allsub')
id: $selectNav.data('allsub')
}]);
});
... ...