|
@@ -42,6 +42,7 @@ import java.util.List;
|
|
|
import java.util.Map;
|
|
|
import java.util.Map.Entry;
|
|
|
import java.util.stream.Collectors;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
|
import org.springframework.stereotype.Service;
|
|
@@ -59,6 +60,7 @@ import org.springframework.web.multipart.MultipartFile;
|
|
|
* @author
|
|
|
* @since 2022-01-18
|
|
|
*/
|
|
|
+@Slf4j
|
|
|
@Service
|
|
|
public class SceneEditInfoServiceImpl extends ServiceImpl<ISceneEditInfoMapper, SceneEditInfo> implements ISceneEditInfoService {
|
|
|
|
|
@@ -184,6 +186,18 @@ public class SceneEditInfoServiceImpl extends ServiceImpl<ISceneEditInfoMapper,
|
|
|
String viewPath = String.format(UploadFilePath.VIEW_PATH, param.getNum());
|
|
|
uploadToOssUtil.copyFiles(editPath,viewPath);
|
|
|
|
|
|
+ //入库
|
|
|
+ if(sceneEditInfo.getId() == null){
|
|
|
+ this.save(sceneEditInfo);
|
|
|
+ }else{
|
|
|
+ this.updateById(sceneEditInfo);
|
|
|
+ }
|
|
|
+ if(sceneEditControls.getId() == null){
|
|
|
+ sceneEditControlsService.save(sceneEditControls);
|
|
|
+ }else{
|
|
|
+ sceneEditControlsService.updateById(sceneEditControls);
|
|
|
+ }
|
|
|
+
|
|
|
return ResultData.ok();
|
|
|
}
|
|
|
|
|
@@ -197,6 +211,7 @@ public class SceneEditInfoServiceImpl extends ServiceImpl<ISceneEditInfoMapper,
|
|
|
|
|
|
String target = path + "_images";
|
|
|
|
|
|
+ log.info("球幕视频路径:{}", target + File.separator + "extras/video");
|
|
|
File video = new File(target + File.separator + "extras/video");
|
|
|
//如果文件夹或者文件不存在,跳出
|
|
|
if(video.exists() || video.listFiles() == null && video.listFiles().length == 0){
|