修改上传文件大小为0的bug
This commit is contained in:
parent
ec75439749
commit
0c8835f2fa
|
|
@ -735,7 +735,7 @@ public class EdFileInfoServiceImpl extends ServiceImpl<EdFileInfoMapper, EdFileI
|
|||
String fileDestPath = commonService.getFileSysPath(newEdFileInfo.getFilePath());
|
||||
FileUtil.writeFromStream(file.getInputStream(), fileDestPath);
|
||||
EleCommonUtil.encryptFile(fileDestPath, SecureUtil.aes(FILE_SEC_PASSWD.getBytes()));
|
||||
fileSystemService.save(FileUtil.getInputStream(fileDestPath), fileDestPath);
|
||||
// fileSystemService.save(FileUtil.getInputStream(fileDestPath), fileDestPath); // 这里会导致文件大小为0,考虑到当前的系统为OS文件系统,暂不处理
|
||||
}
|
||||
} catch (Exception e) {
|
||||
newEdFileInfo.setParentId(parentId)
|
||||
|
|
|
|||
|
|
@ -234,7 +234,7 @@ public class EdFileRelationServiceImpl extends ServiceImpl<EdFileRelationMapper,
|
|||
String fileDestPath = commonService.getFileSysPath(newEdFileInfo.getFilePath());
|
||||
FileUtil.writeFromStream(file.getInputStream(), fileDestPath);
|
||||
EleCommonUtil.encryptFile(fileDestPath, SecureUtil.aes(FILE_SEC_PASSWD.getBytes()));
|
||||
fileSystemService.save(FileUtil.getInputStream(fileDestPath), fileDestPath);
|
||||
// fileSystemService.save(FileUtil.getInputStream(fileDestPath), fileDestPath); // 这里会导致文件大小为0,考虑到当前的系统为OS文件系统,暂不处理
|
||||
|
||||
// 创建文件关系
|
||||
EdFileRelation relation = new EdFileRelation();
|
||||
|
|
|
|||
Loading…
Reference in New Issue