|
@@ -204,12 +204,12 @@ public class SearchIndexServiceImpl implements SearchIndexService {
|
|
|
return ResponseJson.error("商品Id不能为空", null);
|
|
|
}
|
|
|
ProductDO product = searchMapper.searchProductById(productId);
|
|
|
- List<Integer> promotionIds = searchMapper.findPromotionId(product.getP_id());
|
|
|
- if (promotionIds != null && promotionIds.size() > 0) {
|
|
|
- product.setP_promotions_id(promotionIds.get(0));
|
|
|
- }
|
|
|
// product p_promotions_id
|
|
|
if (null != product) {
|
|
|
+ List<Integer> promotionIds = searchMapper.findPromotionId(product.getP_id());
|
|
|
+ if (promotionIds != null && promotionIds.size() > 0) {
|
|
|
+ product.setP_promotions_id(promotionIds.get(0));
|
|
|
+ }
|
|
|
// 定义星范商品数据
|
|
|
List<DocumentDTO<MallProductDO>> mallProductList = new ArrayList<>();
|
|
|
// // 星范商品设值,【必须先于商品文档设值】
|