Authored by zhangxiaoru

search

... ... @@ -140,7 +140,7 @@ const index = (req, res, next) => {
render(result);
}).catch(next);
}
})((result) => {
res.render('search/index', {
module: 'product',
... ... @@ -156,8 +156,8 @@ const index = (req, res, next) => {
}
});
})
});
};
/**
... ...
... ... @@ -412,12 +412,12 @@ function search(opt) {
lazyLoad($container.find('.lazy'));
RES_QTY = $container.find('.total').data('id');
FILTER_VALUE = JSON.stringify(setting).replace(/\{|\}|\"/g,"");
FILTER_VALUE = JSON.stringify(setting).replace(/\{|\}|\"/g, '');
$container.find('.good-info').each(function() {
var goodid = $(this).data('good-id');
if(goodid) {
if (goodid) {
goodIds.push(goodid);
}
});
... ... @@ -440,17 +440,17 @@ function search(opt) {
num = $container.find('.good-info').length;
$container.append(data);
if($container.find('.total')) {
if ($container.find('.total')) {
$container.find('.total')[1].remove();
}
$container.find('.good-info:gt(' + (num - 1) + ')').each(function() {
var goodid = $(this).data('good-id');
if(goodid) {
if (goodid) {
goodIds.push(goodid);
}
})
});
if (window._yas && window._yas.sendCustomInfo) {
window._yas.sendCustomInfo({
... ... @@ -746,7 +746,7 @@ $listNav.on('touchstart', 'li', function() {
$('#goods-container').on('click', '.good-info', function(event) {
var PRD_ID = $(this).data('good-id'),
PRD_NUM = $(this).index() + 1,
FILTER_VALUE = JSON.stringify(qwert).replace(/\{|\}|\"/g,"");
FILTER_VALUE = JSON.stringify(qwert).replace(/\{|\}|\"/g, '');
event.preventDefault();
if (window._yas && window._yas.sendCustomInfo) {
... ... @@ -765,4 +765,4 @@ $('#goods-container').on('click', '.good-info', function(event) {
}
return false;
})
});
... ...