diff --git a/api-admin/src/main/java/com/glxp/sale/admin/idc/controller/IdcController.java b/api-admin/src/main/java/com/glxp/sale/admin/idc/controller/IdcController.java index 5a41b38..514426e 100644 --- a/api-admin/src/main/java/com/glxp/sale/admin/idc/controller/IdcController.java +++ b/api-admin/src/main/java/com/glxp/sale/admin/idc/controller/IdcController.java @@ -90,8 +90,10 @@ public class IdcController { public void downloadFile(HttpServletResponse response,@RequestParam String fileName) throws UnsupportedEncodingException { if (fileName != null) { response.setHeader("Content-disposition", "attachment; filename=" + URLEncoder.encode(fileName, "UTF-8")); + response.setContentType("application/octet-stream"); + idcService.downloadFile(fileName, response); } - idcService.downloadFile(fileName, response); + }