修复流的方法错误 ,修复跨域脚本缺少BASE64 (#423)
* 修复office下载方法中 错误 * 更新OFD解析效果,修复禁止trace请求无效问题,其他压缩包修复 * 修复压缩包 缓存BUG * 限制某些特殊文件上传 * 修复OFFICE文件密码检查关闭流 上传文件关闭流 检查PDF文件是否存在 * 特殊符号的支持 Co-authored-by: gaoxiongzaq <admin@cxcp.com>
This commit is contained in:
@ -50,6 +50,11 @@ public class DownloadUtils {
|
||||
response.setMsg("下载失败:文件名不合法!" + urlStr);
|
||||
return response;
|
||||
}
|
||||
if(realPath.equals("cunzhai")){
|
||||
response.setContent(fileDir + fileName);
|
||||
response.setMsg(fileName);
|
||||
return response;
|
||||
}
|
||||
try {
|
||||
URL url = WebUtils.normalizedURL(urlStr);
|
||||
if (!fileAttribute.getSkipDownLoad()) {
|
||||
@ -110,6 +115,7 @@ public class DownloadUtils {
|
||||
File realFile = new File(realPath);
|
||||
if (realFile.exists()) {
|
||||
fileAttribute.setSkipDownLoad(true);
|
||||
return "cunzhai";
|
||||
}
|
||||
return realPath;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user