From 6605bf35a845b8965981d72276734201e53c3826 Mon Sep 17 00:00:00 2001 From: RuoYi Date: Sat, 26 Mar 2022 17:28:58 +0800 Subject: [PATCH] reset pr 452 --- .../main/java/com/ruoyi/generator/controller/GenController.java | 1 + 1 file changed, 1 insertion(+) diff --git a/ruoyi-generator/src/main/java/com/ruoyi/generator/controller/GenController.java b/ruoyi-generator/src/main/java/com/ruoyi/generator/controller/GenController.java index 97ff95c18..2e9e760a9 100644 --- a/ruoyi-generator/src/main/java/com/ruoyi/generator/controller/GenController.java +++ b/ruoyi-generator/src/main/java/com/ruoyi/generator/controller/GenController.java @@ -204,6 +204,7 @@ public class GenController extends BaseController private void genCode(HttpServletResponse response, byte[] data) throws IOException { response.reset(); + response.addHeader("Access-Control-Allow-Origin", "*"); response.addHeader("Access-Control-Expose-Headers", "Content-Disposition"); response.setHeader("Content-Disposition", "attachment; filename=\"ruoyi.zip\""); response.addHeader("Content-Length", "" + data.length);