he2802 1 жил өмнө
parent
commit
1c693561e7

+ 2 - 1
zhongzheng-admin/src/main/java/com/zhongzheng/controller/CommonController.java

@@ -186,6 +186,7 @@ public class CommonController extends BaseController {
     public void resourceDownload(String resource, HttpServletRequest request, HttpServletResponse response)
             throws Exception {
         try {
+            
             if (!FileUtils.checkAllowDownload(resource)) {
                 throw new Exception(StrUtil.format("资源文件({})非法,不允许下载。 ", resource));
             }
@@ -198,7 +199,7 @@ public class CommonController extends BaseController {
             response.setContentType(MediaType.APPLICATION_OCTET_STREAM_VALUE);
             FileUtils.setAttachmentResponseHeader(response, downloadName);
             FileUtils.writeBytes(downloadPath, response.getOutputStream());
-            
+
         } catch (Exception e) {
             log.error("下载文件失败", e);
         }