fix: 优化生成es索引,只生成库存大于0的商品

This commit is contained in:
misworga831 2023-03-31 18:23:30 +08:00
parent 4ebe0d4f43
commit bc670d263d

View File

@ -167,7 +167,7 @@ public class EsGoodsIndexServiceImpl extends BaseElasticsearchService implements
skuQueryWrapper.eq("gs.auth_flag", GoodsAuthEnum.PASS.name());
skuQueryWrapper.eq("gs.market_enable", GoodsStatusEnum.UPPER.name());
skuQueryWrapper.eq("gs.delete_flag", false);
skuQueryWrapper.ge("gs.quantity", 0);
skuQueryWrapper.gt("gs.quantity", 0);
Map<String, Long> resultMap = (Map<String, Long>) cache.get(CachePrefix.INIT_INDEX_PROCESS.getPrefix());