|
@@ -90,6 +90,7 @@ public class FodderServiceImpl extends IBaseServiceImpl<FodderEntity, Long> impl
|
|
|
String dpi = "0";
|
|
|
String ossPath = configConstant.ossBasePath+dirType+newName;
|
|
|
String savePath = configConstant.serverBasePath;
|
|
|
+ String ossPreviewIcon = null;
|
|
|
|
|
|
FodderEntity entity = new FodderEntity();
|
|
|
if (type.equals("pano")) {
|
|
@@ -105,6 +106,10 @@ public class FodderServiceImpl extends IBaseServiceImpl<FodderEntity, Long> impl
|
|
|
// 压缩图片并上传oss
|
|
|
iconPath = fileUtils.compressImgAndUploadOss2(savePath, configConstant.ossBasePath + sceneCode , configConstant.ossDomain);
|
|
|
|
|
|
+ // 全景图的预览图
|
|
|
+ ossPreviewIcon = fileUtils.compressImgAndUploadOss2(
|
|
|
+ savePath, configConstant.ossBasePath + sceneCode , configConstant.ossDomain, 1920, 960, "preview.jpg");
|
|
|
+
|
|
|
|
|
|
ossUrl = configConstant.ossDomain+configConstant.ossBasePath + sceneCode;
|
|
|
|
|
@@ -153,6 +158,7 @@ public class FodderServiceImpl extends IBaseServiceImpl<FodderEntity, Long> impl
|
|
|
entity.setUserId(getUserNameForToken());
|
|
|
entity.setFileSize(size+"");
|
|
|
entity.setDpi(dpi);
|
|
|
+ entity.setPreviewIcon(ossPreviewIcon);
|
|
|
|
|
|
save(entity);
|
|
|
|
|
@@ -195,7 +201,6 @@ public class FodderServiceImpl extends IBaseServiceImpl<FodderEntity, Long> impl
|
|
|
@Override
|
|
|
public Result selectFodderPano(PageDto param, Long workId) {
|
|
|
startPage(param);
|
|
|
-// List<FodderEntity> list = entityMapper.findByStatusAndTypeAndUserId(3, "pano", getUserNameForToken());
|
|
|
|
|
|
List<FodderEntity> list = entityMapper.searchPano(param, getUserNameForToken());
|
|
|
|