From cdb8ec7e286a7b1d8bdfcc060d26522049beab15 Mon Sep 17 00:00:00 2001 From: sunyuchao Date: Mon, 28 Mar 2022 17:06:18 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E6=A0=B8=E9=85=B8=E3=80=91=E6=A0=B8?= =?UTF-8?q?=E9=85=B8=E6=A3=80=E6=B5=8B=E4=B8=8B=E8=BD=BD=E6=A8=A1=E6=9D=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/epmet/controller/IcNatController.java | 36 ++++++++++++++++-- .../src/main/resources/excel/ic_nat.xlsx | Bin 0 -> 9114 bytes 2 files changed, 32 insertions(+), 4 deletions(-) create mode 100644 epmet-user/epmet-user-server/src/main/resources/excel/ic_nat.xlsx diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java index 0f6f799dd4..35d3511196 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/controller/IcNatController.java @@ -11,12 +11,16 @@ import com.epmet.dto.form.MyNatListFormDTO; import com.epmet.dto.result.MyNatListResultDTO; import com.epmet.dto.result.NatListResultDTO; import com.epmet.service.IcNatService; +import org.apache.commons.io.IOUtils; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.web.bind.annotation.PostMapping; -import org.springframework.web.bind.annotation.RequestBody; -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RestController; +import org.springframework.http.HttpHeaders; +import org.springframework.web.bind.annotation.*; +import javax.servlet.ServletOutputStream; +import javax.servlet.http.HttpServletResponse; +import java.io.IOException; +import java.io.InputStream; +import java.net.URLEncoder; import java.util.List; @@ -120,5 +124,29 @@ public class IcNatController { return new Result(); } + /** + * @Author sun + * @Description 【核酸】核酸检测信息下载模板 + **/ + @RequestMapping(value = "import-template-download", method = {RequestMethod.GET, RequestMethod.POST}) + public void downloadTemplate(HttpServletResponse response) throws IOException { + response.setCharacterEncoding("UTF-8"); + response.addHeader(HttpHeaders.ACCESS_CONTROL_EXPOSE_HEADERS, "Content-Disposition"); + //response.setHeader(HttpHeaders.CONTENT_TYPE, "application/vnd.ms-excel"); + response.setHeader(HttpHeaders.CONTENT_TYPE, "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); + response.setHeader(HttpHeaders.CONTENT_DISPOSITION, "attachment;filename=" + URLEncoder.encode("社区自组织导入模板", "UTF-8") + ".xlsx"); + + InputStream is = this.getClass().getClassLoader().getResourceAsStream("excel/ic_nat.xlsx"); + try { + ServletOutputStream os = response.getOutputStream(); + IOUtils.copy(is, os); + } finally { + if (is != null) { + is.close(); + } + } + + } + } diff --git a/epmet-user/epmet-user-server/src/main/resources/excel/ic_nat.xlsx b/epmet-user/epmet-user-server/src/main/resources/excel/ic_nat.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..4d7df5944a91e416a31a21891975ba1778567252 GIT binary patch literal 9114 zcmaJ{1yo$ivc-ZE+}+(>g1fuB1s~jlyCpzyf(8jraCaxT6Wrb1J|zF$d&9r~^;&1n ztTRq;@`M=X#~RI+u)$ZgYzH&sERL3Wigj#PWtp?2rgriGH! z9Ob*Y!2VXrCc&_5khuZ&>&-Cc7O7R&OJidNQS{n$HFO{_Ui;d`ah!vOn(}7vpl;c8d2`k^!MCv-<|IpV+Gc)sjg9Qhy*XcfxH&nv zprc!%x!oyF=-8Iu17+L+RoDk_@asg3)M?M@#%gy{5&!57Bp1~BPN-dmBb*f|_lr>T z<7(}W8vEUi&B>cT(N)4w$OSY;I+yS<)8#{I}Y+!A^DF;ap&QmF+9}A**Te)VpL83`S5X}}L zzZHVK1F)Y!iwrT-sxO#Pj6mUNCQPewvVUer!?QMOb%&yZCOM#Bf5YVppy-am=Vwd+ z3x2!WTpo5~TZPIN(NYd=8=osx)XLn((}BytMvV9++V7+Inav&^0Y?xPirEo^1mxq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