...
|
...
|
@@ -1135,6 +1135,7 @@ const _detailDataPkg = (origin, uid, vipLevel, cookies) => { |
|
|
result.productId = propOrigin('product_id');
|
|
|
result.shopId = propOrigin('shop_id', 0);
|
|
|
result.brandId = propOrigin('brand_info.brand_id', '');
|
|
|
result.brandName = propOrigin('brand_info.brand_name', '');
|
|
|
|
|
|
result.maxSortId = propOrigin('maxSortId', '');
|
|
|
result.smallSortId = propOrigin('smallSortId', '');
|
...
|
...
|
@@ -1445,7 +1446,7 @@ const _detailDataPkg = (origin, uid, vipLevel, cookies) => { |
|
|
// 分享相关,产品的链接
|
|
|
result.weixinUrl = propOrigin('product_url');
|
|
|
result.shareTitle = result.name;
|
|
|
result.shareImg = 'http:' + result.img; // 分享图片必须使用http
|
|
|
result.shareImg = helpers.getForceSourceUrl(result.img);
|
|
|
result.shareDesc = result.phrase;
|
|
|
|
|
|
// 统计需要的商品信息
|
...
|
...
|
@@ -1458,7 +1459,7 @@ const _detailDataPkg = (origin, uid, vipLevel, cookies) => { |
|
|
statGoodsInfo.brandName = (result.brandName || '').replace('\'', '’');
|
|
|
statGoodsInfo.marketPrice = (result.marketPrice ? result.marketPrice : result.presalePrice).replace('¥', ''); // 数字
|
|
|
statGoodsInfo.salePrice = (result.salePrice ? result.salePrice : (result.marketPrice || result.presalePrice)).replace('¥', ''); // 数字
|
|
|
statGoodsInfo.imageUrl = 'http:' + result.img.split('?')[0];
|
|
|
statGoodsInfo.imageUrl = helpers.getForceSourceUrl(result.img);
|
|
|
statGoodsInfo.productUrl = 'http:' +
|
|
|
helpers.urlFormat(url.parse(propOrigin('product_url')).pathname, null, 'item');
|
|
|
statGoodsInfo.smallSortId = result.smallSortId;
|
...
|
...
|
@@ -1607,6 +1608,12 @@ const showMainAsync = (data) => { |
|
|
[{name: _.get(productInfo, 'goodsInfo.name')}]
|
|
|
);
|
|
|
|
|
|
// 统计代码中需要新的path
|
|
|
result.statGoodsInfo.category = _.concat(
|
|
|
homeService.getHomeChannelNav(data.channel),
|
|
|
smallSortNavigator
|
|
|
).map(n => n.name).join('>');
|
|
|
|
|
|
// 头部数据
|
|
|
result.headerData = navigatorHeader.headerData;
|
|
|
|
...
|
...
|
|