Merge branch 'hotfix/add-cache' into feature/detail-op
# Conflicts: # apps/product/models/detail-product-api.js # apps/product/models/detail-service.js
Showing
2 changed files
with
2 additions
and
4 deletions
@@ -253,9 +253,7 @@ module.exports = class extends global.yoho.BaseModel { | @@ -253,9 +253,7 @@ module.exports = class extends global.yoho.BaseModel { | ||
253 | // 根据small_sort从redis获取分类下的关键词 | 253 | // 根据small_sort从redis获取分类下的关键词 |
254 | _getRecommendKeywords(smallSort) { | 254 | _getRecommendKeywords(smallSort) { |
255 | return redis.all([['get', `global:yoho:seo:keywords:sortId:${smallSort}:page:1`]]).then(res => { | 255 | return redis.all([['get', `global:yoho:seo:keywords:sortId:${smallSort}:page:1`]]).then(res => { |
256 | - return res[0]; | ||
257 | - }).then(result => { | ||
258 | - return this._getKeywordsInfo(JSON.parse(result || '[]')); | 256 | + return this._getKeywordsInfo(JSON.parse(res[0] || '[]')); |
259 | }); | 257 | }); |
260 | } | 258 | } |
261 | 259 |
@@ -1083,7 +1083,7 @@ function _detailDataPkg(origin, uid, vipLevel, cookies) { | @@ -1083,7 +1083,7 @@ function _detailDataPkg(origin, uid, vipLevel, cookies) { | ||
1083 | } | 1083 | } |
1084 | 1084 | ||
1085 | // 相关推荐词 | 1085 | // 相关推荐词 |
1086 | - requestApi.recommendKeywords = this.productAPI.getRecommendKeywords(result.smallSortId); | 1086 | + requestApi.recommendKeywords = this.productAPI.getRecommendKeywords(result.smallSortId, result.skn); |
1087 | 1087 | ||
1088 | // 店铺推荐直出(seo需要) | 1088 | // 店铺推荐直出(seo需要) |
1089 | requestApi.shopRecommend = this.productAPI.getShopRecommendAsync(result.skn); | 1089 | requestApi.shopRecommend = this.productAPI.getShopRecommendAsync(result.skn); |
-
Please register or login to post a comment