From 2701dca44e1972afe9956ced2f949d2998c1bb4b Mon Sep 17 00:00:00 2001
From: zxl <763096477@qq.com>
Date: 星期四, 19 六月 2025 20:00:45 +0800
Subject: [PATCH] 客户管理详情
---
framework/src/main/java/cn/lili/modules/lmk/service/impl/VideoServiceImpl.java | 14 +++++++++++---
1 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/framework/src/main/java/cn/lili/modules/lmk/service/impl/VideoServiceImpl.java b/framework/src/main/java/cn/lili/modules/lmk/service/impl/VideoServiceImpl.java
index 0468ed1..74b939e 100644
--- a/framework/src/main/java/cn/lili/modules/lmk/service/impl/VideoServiceImpl.java
+++ b/framework/src/main/java/cn/lili/modules/lmk/service/impl/VideoServiceImpl.java
@@ -130,7 +130,11 @@
Assert.notNull(vo, "璁板綍涓嶅瓨鍦�");
List<SimpleVideoTagVO> tags = videoTagRefService.getTagsByVideoIds(Arrays.asList(id));
vo.setTagList(tags);
- vo.setVideoUrl(cosUtil.getPreviewUrl(vo.getVideoFileKey()));
+ if (VideoContentTypeEnum.VIDEO.getValue().equals(vo.getVideoContentType())) {
+ vo.setVideoUrl(cosUtil.getPreviewUrl(vo.getVideoFileKey()));
+ } else if (VideoContentTypeEnum.IMG.getValue().equals(vo.getVideoContentType()) && StringUtils.isNotBlank(vo.getVideoImgs())) {
+ vo.setImgs(JSON.parseArray(vo.getVideoImgs(), String.class).stream().map(fileKey -> cosUtil.getPreviewUrl(fileKey)).collect(Collectors.toList()));
+ }
return Result.ok().data(vo);
}
@@ -299,8 +303,12 @@
v.setGoods(new VideoGoodsVO());
v.setTagList(tagMap.get(v.getId()));
v.setCollected(CollectionUtils.isNotEmpty(collectMap.get(v.getId())));
-// v.setVideoUrl(cosUtil.getPreviewUrl(v.getVideoFileKey()));
- v.setVideoUrl("https://videos.pexels.com/video-files/13602965/13602965-hd_1920_1080_30fps.mp4");
+ if (VideoContentTypeEnum.VIDEO.getValue().equals(v.getVideoContentType())) {
+ // v.setVideoUrl(cosUtil.getPreviewUrl(v.getVideoFileKey()));
+ v.setVideoUrl("https://videos.pexels.com/video-files/13602965/13602965-hd_1920_1080_30fps.mp4");
+ } else if (VideoContentTypeEnum.IMG.getValue().equals(v.getVideoContentType()) && StringUtils.isNotBlank(v.getVideoImgs())) {
+ v.setImgs(JSON.parseArray(v.getVideoImgs(), String.class).stream().map(fileKey -> cosUtil.getPreviewUrl(fileKey)).collect(Collectors.toList()));
+ }
v.setCoverUrl(cosUtil.getPreviewUrl(v.getCoverFileKey()));
v.setSubscribeThisAuthor(subscribes.contains(v.getAuthorId()));
});
--
Gitblit v1.8.0