|
@@ -1105,6 +1105,21 @@ public class GoodsDonController {
|
|
|
value = redisService.get(categoryGoodsKey);
|
|
value = redisService.get(categoryGoodsKey);
|
|
|
}
|
|
}
|
|
|
List<YhShopGoodsFrontCategoryView> list = Jsons.parseList(value, YhShopGoodsFrontCategoryView.class);
|
|
List<YhShopGoodsFrontCategoryView> list = Jsons.parseList(value, YhShopGoodsFrontCategoryView.class);
|
|
|
|
|
+ list.forEach(data->{
|
|
|
|
|
+ Optional.ofNullable(yhShopGoodsSkuMapper.selectOne(Wrappers.lambdaQuery(YhShopGoodsSku.class)
|
|
|
|
|
+ .eq(YhShopGoodsSku::getYhsId, yhsId)
|
|
|
|
|
+ .eq(YhShopGoodsSku::getGoodsId, data.getId())
|
|
|
|
|
+ .eq(YhShopGoodsSku::getPrice, data.getPrice())
|
|
|
|
|
+ .eq(YhShopGoodsSku::getStatus, 1)
|
|
|
|
|
+ .eq(YhShopGoodsSku::getDeleted, 1)
|
|
|
|
|
+ .last("limit 1"))).ifPresent(yhSku -> {
|
|
|
|
|
+ GoodsDonSku sku = goodsDonSkuMapper.selectById(yhSku.getSkuId());
|
|
|
|
|
+ if (sku != null) {
|
|
|
|
|
+ data.setMonths(sku.getMonths());
|
|
|
|
|
+ data.setDays(sku.getDays());
|
|
|
|
|
+ }
|
|
|
|
|
+ });
|
|
|
|
|
+ });
|
|
|
return GatewayResponse.SUCCESS.newBuilder().toResult(list);
|
|
return GatewayResponse.SUCCESS.newBuilder().toResult(list);
|
|
|
}
|
|
}
|
|
|
|
|
|