|
@@ -0,0 +1,64 @@
|
|
|
+package com.citupro.module.menduner.flames.controller.admin;
|
|
|
+
|
|
|
+
|
|
|
+import cn.hutool.core.bean.BeanUtil;
|
|
|
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
+import com.citu.framework.common.pojo.CommonResult;
|
|
|
+import com.citu.framework.security.core.util.SecurityFrameworkUtils;
|
|
|
+import com.citupro.module.menduner.flames.controller.base.reqvo.school.SchoolIdReqVo;
|
|
|
+import com.citupro.module.menduner.flames.controller.base.reqvo.school.SchoolOrganizationReqVo;
|
|
|
+import com.citupro.module.menduner.flames.controller.base.reqvo.school.SchoolStudentDetailReqVo;
|
|
|
+import com.citupro.module.menduner.flames.controller.base.vo.school.SchoolInfoVo;
|
|
|
+import com.citupro.module.menduner.flames.dal.mysql.School;
|
|
|
+import com.citupro.module.menduner.flames.service.SchoolService;
|
|
|
+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 javax.servlet.http.HttpServletResponse;
|
|
|
+import java.io.IOException;
|
|
|
+import java.io.UnsupportedEncodingException;
|
|
|
+import java.net.URLEncoder;
|
|
|
+import java.util.Map;
|
|
|
+
|
|
|
+/**
|
|
|
+ * @author auto
|
|
|
+ * @date 2023-07-21 11:02:36
|
|
|
+ * @eo.api-type http
|
|
|
+ * @eo.groupName 火苗儿.学校管理
|
|
|
+ * @eo.path /flames
|
|
|
+ */
|
|
|
+@RequestMapping("/flames")
|
|
|
+@RestController
|
|
|
+public class SchoolAdminController {
|
|
|
+ @SuppressWarnings("all")
|
|
|
+ private static final org.slf4j.Logger log = org.slf4j.LoggerFactory.getLogger(SchoolAdminController.class);
|
|
|
+ @Autowired
|
|
|
+ private SchoolService schoolService;
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 学生实习明细导出
|
|
|
+ * @param reqVo
|
|
|
+ * @return R
|
|
|
+ * @eo.name 学生实习明细导出
|
|
|
+ * @eo.url /school/student/detail/export
|
|
|
+ * @eo.method post
|
|
|
+ * @eo.request-type formdata
|
|
|
+ */
|
|
|
+ @PostMapping("/school/student/detail/export")
|
|
|
+ public void schoolStudentDetailExport(@RequestBody SchoolStudentDetailReqVo reqVo, HttpServletResponse response) throws IOException {
|
|
|
+ response.addHeader("Pargam", "no-cache");
|
|
|
+ response.addHeader("Cache-Control", "no-cache");
|
|
|
+// response.setContentType("application/octet-stream");
|
|
|
+ response.setCharacterEncoding("UTF-8");
|
|
|
+ response.setHeader("Content-disposition", URLEncoder.encode("学生实习情况导出表.xlsx", "UTF-8"));
|
|
|
+ response.setHeader("Access-Control-Expose-Headers", "Content-disposition");
|
|
|
+ schoolService.schoolStudentDetailExport(reqVo,response.getOutputStream());
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+}
|