|
|
@ -97,7 +97,7 @@ public class PresonManagementController extends BladeController { |
|
|
|
@OperationAnnotation(moduleName = "档案管理",title = "档案管理",operatorType = OperatorType.MOBILE,businessType = |
|
|
|
@OperationAnnotation(moduleName = "档案管理",title = "档案管理",operatorType = OperatorType.MOBILE,businessType = |
|
|
|
BusinessType.GENCODE,action |
|
|
|
BusinessType.GENCODE,action |
|
|
|
= "档案管理") |
|
|
|
= "档案管理") |
|
|
|
public void exportPersonManagemetVo(HttpServletResponse response,PersonManagemetVo personManagemetVo) { |
|
|
|
public void exportPersonManagemetVo(HttpServletResponse response,PersonManagemetVo personManagemetVo) throws IOException { |
|
|
|
try { |
|
|
|
try { |
|
|
|
response.setContentType("application/vnd.ms-excel"); |
|
|
|
response.setContentType("application/vnd.ms-excel"); |
|
|
|
response.setCharacterEncoding("UTF-8"); |
|
|
|
response.setCharacterEncoding("UTF-8"); |
|
|
@ -111,8 +111,9 @@ public class PresonManagementController extends BladeController { |
|
|
|
EasyExcel.write(response.getOutputStream(), PersonManagemetExportVo.class).autoCloseStream(Boolean.FALSE).sheet("档案管理报表") |
|
|
|
EasyExcel.write(response.getOutputStream(), PersonManagemetExportVo.class).autoCloseStream(Boolean.FALSE).sheet("档案管理报表") |
|
|
|
.doWrite(list); |
|
|
|
.doWrite(list); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
response.getOutputStream().close(); |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
|
System.out.println("exportExcel = " + e); |
|
|
|
e.printStackTrace(); |
|
|
|
// 重置response
|
|
|
|
// 重置response
|
|
|
|
response.reset(); |
|
|
|
response.reset(); |
|
|
|
response.setContentType("application/json"); |
|
|
|
response.setContentType("application/json"); |
|
|
@ -122,9 +123,12 @@ public class PresonManagementController extends BladeController { |
|
|
|
map.put("msg", "档案管理报表导出失败" + e.getMessage()); |
|
|
|
map.put("msg", "档案管理报表导出失败" + e.getMessage()); |
|
|
|
try { |
|
|
|
try { |
|
|
|
response.getWriter().println(JSONUtil.toJsonStr(map)); |
|
|
|
response.getWriter().println(JSONUtil.toJsonStr(map)); |
|
|
|
|
|
|
|
response.getOutputStream().close(); |
|
|
|
} catch (IOException e3) { |
|
|
|
} catch (IOException e3) { |
|
|
|
|
|
|
|
response.getOutputStream().close(); |
|
|
|
throw new ServiceException( "发生异常 :" + e); |
|
|
|
throw new ServiceException( "发生异常 :" + e); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|