Authored by 郭成尧

shop-union

... ... @@ -226,8 +226,9 @@ const shop = {
}
/* 基础店铺返回程序内的跳转信号,跳转到基础店铺 */
if (shopInfoResult && shopInfoResult.shop_template_type &&
parseInt(shopInfoResult.shop_template_type, 10) === 1) {
if (shopInfoResult && shopInfoResult.shop_template_type) {
if (parseInt(shopInfoResult.shop_template_type, 10) === 1) {
return Promise.all([
listModel.getBaseShopData(req.query, shopInfo),
searchModel.getSearchData(searchParam)
... ... @@ -238,7 +239,8 @@ const shop = {
baseShop.newGoods = newGoods.list;
if (baseShop && baseShop.baseShopHome && baseShop.baseShopHome.banner) {
if (baseShop.baseShopHome.banner.indexOf('?') < 0) {
baseShop.baseShopHome.banner += '?imageMogr2/auto-orient/strip/thumbnail/x150/crop/640x150';
baseShop.baseShopHome.banner +=
'?imageMogr2/auto-orient/strip/thumbnail/x150/crop/640x150';
}
}
... ... @@ -271,7 +273,8 @@ const shop = {
localCss: true
});
});
} else {
} else if (parseInt(shopInfoResult.shop_template_type, 10) === 2) {
// 经典装修店铺
return Promise.all([
listModel.getShopDecorator(shopId).then(),
... ... @@ -301,7 +304,8 @@ const shop = {
channel: req.query.channel,
title: result.seoTitle + '|' + result.seoTitle + '潮流服装服饰-Yoho!Buy有货',
keywords: result.seoTitle + ',' + result.seoTitle + '服装服饰,' + result.seoTitle + '潮流服装服饰',
description: result.seoTitle + '|Yoho!Buy有货' + result.seoTitle + '潮流服饰官方授权店!100%品牌正品保证,支持货到付款。',
description: result.seoTitle + '|Yoho!Buy有货' + result.seoTitle +
'潮流服饰官方授权店!100%品牌正品保证,支持货到付款。',
shopId: shopId,
shopPage: true,
appPath: 'yohobuy://yohobuy.com/goapp?openby:yohobuy={"action":"go.shop","params":{"shop_template_type":"2","shop_id":"' +
... ... @@ -310,6 +314,11 @@ const shop = {
});
});
} else {
shop.redShop(req, res, next);
}
} else {
shop.redShop(req, res, next);
}
}).catch(next);
},
... ...