...
|
...
|
@@ -866,7 +866,11 @@ const _getMaterialDataBySizeInfo = (sizeInfo) => { |
|
|
name: value.caption,
|
|
|
enName: value.encaption,
|
|
|
text: value.remark
|
|
|
}))
|
|
|
})),
|
|
|
washTips: {
|
|
|
tip: _.get(sizeInfo, 'washRemindTipsBo.remindTips', ''),
|
|
|
img: _.get(sizeInfo, 'washRemindTipsBo.img', '')
|
|
|
}
|
|
|
};
|
|
|
};
|
|
|
|
...
|
...
|
@@ -1425,33 +1429,32 @@ const _detailDataPkg = (origin, uid, vipLevel, cookies) => { |
|
|
|
|
|
result.productUrl = statGoodsInfo.productUrl;
|
|
|
|
|
|
// 商品的品牌信息
|
|
|
let bandInfo = {};
|
|
|
|
|
|
if (propOrigin('brand_info', '')) {
|
|
|
result.brandImg = helpers.image(propOrigin('brand_info.brand_ico', ''), 47, 47);
|
|
|
result.brandName = propOrigin('brand_info.brand_name', '');
|
|
|
bandInfo = _getBrandDataByProductBaseInfo(origin, additionalData);
|
|
|
bandInfo.isCollect = favoriteData.brand;
|
|
|
// 商品的店铺信息
|
|
|
let shopInfo = {
|
|
|
brandId: result.brandId,
|
|
|
bgColor: '#000000',
|
|
|
logo: '',
|
|
|
alt: '',
|
|
|
brandName: '',
|
|
|
brandDomain: '',
|
|
|
homeUrl: '',
|
|
|
bgImg: '',
|
|
|
isCollect: favoriteData.brand
|
|
|
};
|
|
|
|
|
|
if (result.shopId) {
|
|
|
let shopData = yield Promise.props({
|
|
|
bannerImg: shopService.getShopBannerAsync(result.shopId),
|
|
|
isShopOpen: shopService.queryShopByBrandIdAsync(result.brandId)
|
|
|
});
|
|
|
if (result.shopId) {
|
|
|
let shopData = yield Promise.props({
|
|
|
bannerImg: shopService.getShopBannerAsync(result.shopId),
|
|
|
shopInfo: shopService.queryShopByBrandIdAsync(result.shopId, result.brandId)
|
|
|
});
|
|
|
|
|
|
if (shopData.bannerImg) {
|
|
|
bandInfo.bgImg = shopData.bannerImg;
|
|
|
}
|
|
|
shopInfo.alt = shopInfo.brandName = shopData.shopInfo.brand_name;
|
|
|
shopInfo.brandDomain = shopData.shopInfo.brand_domain;
|
|
|
shopInfo.logo = helpers.image(shopData.shopInfo.brand_ico, 45, 45);
|
|
|
shopInfo.homeUrl = helpers.urlFormat('', {shopId: result.shopId}, shopInfo.brandDomain);
|
|
|
|
|
|
if (shopData.isShopOpen) {
|
|
|
bandInfo.homeUrl = helpers.urlFormat('',
|
|
|
{shopId: result.shopId},
|
|
|
propOrigin('brand_info.brand_domain')
|
|
|
);
|
|
|
} else {
|
|
|
result.shopId = '0';
|
|
|
}
|
|
|
if (shopData.bannerImg) {
|
|
|
shopInfo.bgImg = shopData.bannerImg;
|
|
|
}
|
|
|
}
|
|
|
|
...
|
...
|
@@ -1462,7 +1465,7 @@ const _detailDataPkg = (origin, uid, vipLevel, cookies) => { |
|
|
|
|
|
return {
|
|
|
goodsInfo: result,
|
|
|
banner: _.isEmpty(bandInfo) ? null : bandInfo,
|
|
|
banner: _.isEmpty(shopInfo) ? null : shopInfo,
|
|
|
statGoodsInfo: statGoodsInfo
|
|
|
|
|
|
};
|
...
|
...
|
|