修改文件上传默认路径

This commit is contained in:
zj
2021-12-15 19:54:18 +08:00
parent 14e2b3368c
commit c73f9b50d4
3 changed files with 7 additions and 7 deletions
@@ -293,7 +293,7 @@ public class AttFileEOController {
if (!newFile.exists()) {
Files.copy(oldFile.toPath(), newFile.toPath());
}
filePathResult = "uploadPath/phoneLoadFiles/" + timeStr + "/" + fileOldName;
filePathResult = "file/phoneLoadFiles/" + timeStr + "/" + fileOldName;
return Result.success(filePathResult);
} else {
return Result.error("获取文件信息失败");
@@ -69,9 +69,9 @@ public class UeditorController {
AttFileVo attFileVo= attFileEOService.saveFileInfo(uploadFile);
String picUrlPath ="";
if(StringUtils.isNotEmpty(referer)){
picUrlPath=referer+"uploadPath"+ attFileVo.getFilePath()+attFileVo.getFileName();
picUrlPath=referer+"file"+ attFileVo.getFilePath()+attFileVo.getFileName();
}else{
picUrlPath="uploadPath"+attFileVo.getFilePath()+attFileVo.getFileName();
picUrlPath="file"+attFileVo.getFilePath()+attFileVo.getFileName();
}
log.info("Ueditor 上传图片返回路径:"+picUrlPath);
image.setState("SUCCESS");