|
@@ -76,6 +76,8 @@ public class TourismProjectToWebServiceImpl implements TourismProjectToWebServic
|
|
|
private RedissonClient redissonClient;
|
|
|
@Autowired
|
|
|
private DirectoryInfoService directoryInfoService;
|
|
|
+ @Autowired
|
|
|
+ private TourismFileService tourismFileService;
|
|
|
|
|
|
|
|
|
@Override
|
|
@@ -132,6 +134,19 @@ public class TourismProjectToWebServiceImpl implements TourismProjectToWebServic
|
|
|
List<TourismProjectVo> dataList = tourismProjectVoMyPageData.getDataList();
|
|
|
//先把imgUrl由jaon转换为List<FileUrlObject>
|
|
|
dataList.stream().forEach(item ->{
|
|
|
+ //遍历查询关联的tourismFile
|
|
|
+ TourismFile tourismFile = new TourismFile();
|
|
|
+ tourismFile.setAssociationTableId(item.getId());
|
|
|
+ List<TourismFile> tourismFileListWithRelation = tourismFileService.getTourismFileList(tourismFile, "");
|
|
|
+ //判断是否为空
|
|
|
+ if(tourismFileListWithRelation != null && tourismFileListWithRelation.size() > 0){
|
|
|
+ //不为空则进行转换,提取数据
|
|
|
+ TourismFile tourismFile1 = tourismFileListWithRelation.get(0);
|
|
|
+ String fileUrl = tourismFile1.getFileUrl();
|
|
|
+ //进行转换url
|
|
|
+ List<String> fileUrlList = UrlConvertUtils.urlConvert(applicationConfig.getHostIpPort(), fileUrl);
|
|
|
+ item.setFileUrlList(fileUrlList);
|
|
|
+ }
|
|
|
List<String> urlList = UrlConvertUtils.urlConvert(applicationConfig.getHostIpPort(), item.getHomeHotPicture());
|
|
|
item.setHomeHotPicturesAfterConvert(urlList);
|
|
|
List<String> arrayList = UrlConvertUtils.urlConvert(applicationConfig.getHostIpPort(), item.getTourismUrl());
|