From e2e015e02fb67ef7c348fbcb2152a34ccb34004d Mon Sep 17 00:00:00 2001 From: zxl <763096477@qq.com> Date: 星期一, 28 七月 2025 15:19:09 +0800 Subject: [PATCH] 活动定时任务优化 --- manager-api/src/main/java/cn/lili/controller/goods/GoodsManagerController.java | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/manager-api/src/main/java/cn/lili/controller/goods/GoodsManagerController.java b/manager-api/src/main/java/cn/lili/controller/goods/GoodsManagerController.java index b252dab..9271290 100644 --- a/manager-api/src/main/java/cn/lili/controller/goods/GoodsManagerController.java +++ b/manager-api/src/main/java/cn/lili/controller/goods/GoodsManagerController.java @@ -63,7 +63,14 @@ @ApiOperation(value = "鍒嗛〉鑾峰彇鍟嗗搧鍒楄〃") @GetMapping(value = "/sku/list") public ResultMessage<IPage<GoodsSku>> getSkuByPage(GoodsSearchParams goodsSearchParams) { - return ResultUtil.data(goodsSkuService.getGoodsSkuByPage(goodsSearchParams)); + IPage<GoodsSku> goodsSkuByPage = goodsSkuService.getGoodsSkuByPage(goodsSearchParams); + goodsSkuByPage.getRecords().forEach(goodsSku -> { + String thumbnail = goodsSku.getThumbnail(); + if (StringUtils.isNotBlank(thumbnail)&&!thumbnail.contains("http")) { + goodsSku.setThumbnail(cosUtil.getPreviewUrl(goodsSku.getThumbnail())); + } + }); + return ResultUtil.data(goodsSkuByPage); } @ApiOperation(value = "鍒嗛〉鑾峰彇寰呭鏍稿晢鍝�") -- Gitblit v1.8.0