Authored by zhangxiaoru

sale

... ... @@ -182,7 +182,7 @@ let discountDetail = (req, res, next) => {
params.renderData.pageHeader.navTitle = result.title;
// 唤起 APP 的路径
res.locals.appPath = `yohobuy://yohobuy.com/goapp?openby:yohobuy={"action":"go.discountmarketpro","params":{"id":"${id}","cover_url":"${result.activity.cover_url.split('?')[0]}","title":"${result.title}"}}`;
res.locals.appPath = result.activity && result.activity.cover_url ? `yohobuy://yohobuy.com/goapp?openby:yohobuy={"action":"go.discountmarketpro","params":{"id":"${id}","cover_url":"${result.activity.cover_url.split('?')[0]}","title":"${result.title}"}}` : '';
res.render('sale/discount-detail', Object.assign(params.renderData, result, {
localCss: true
... ...
... ... @@ -356,6 +356,10 @@ function filterInit() {
url: '/product/sale/filter',
data: defaultOpt,
success: function(data) {
if (data === '') {
return false;
}
$goodsContainer.append(data);
// 初始化filter&注册filter回调
... ...