Commit 9b7ba9514bc3eb1993d6edeedfa7a9cafa0968bf

Authored by liquanyu
1 parent 8ae2978c7a

筛查统计

Showing 2 changed files with 5 additions and 3 deletions

platform-common/src/main/java/com/lyms/platform/common/utils/ExcelUtil.java View file @ 9b7ba95
... ... @@ -287,7 +287,7 @@
287 287 }
288 288  
289 289  
290   - public static void writeWhSieveExclFile(String filePath,OutputStream out,List<Map<String,String>> values,String date) {
  290 + public static void writeWhSieveExclFile(String filePath,OutputStream out,List<Map<String,String>> values,String titleName) {
291 291 File file = new File(filePath);
292 292 InputStream in = null;
293 293 Workbook wb = null;
... ... @@ -305,7 +305,7 @@
305 305 contentFormt.setVerticalAlignment(VerticalAlignment.CENTRE);
306 306  
307 307  
308   - Label label = new Label(0, 0, "ssss",contentFormt);
  308 + Label label = new Label(0, 0, titleName,contentFormt);
309 309 ws.addCell(label);
310 310  
311 311 int arrayIndex = 0;
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/SieveFacade.java View file @ 9b7ba95
... ... @@ -1584,14 +1584,16 @@
1584 1584 List<String> currentUserHospPermissions = areaCountFacade.getCurrentUserHospPermissions(userId, cqSieveQueryRequest.getProvinceId(),
1585 1585 cqSieveQueryRequest.getCityId(), cqSieveQueryRequest.getAreaId());
1586 1586 String[] dates = null;
  1587 + String titleName = "孕妇产前筛查和诊断情况月报表";
1587 1588 if (StringUtils.isNotEmpty(cqSieveQueryRequest.getTime())) {
1588 1589 dates = cqSieveQueryRequest.getTime().split(" - ");
  1590 + titleName+=cqSieveQueryRequest.getTime();
1589 1591 }
1590 1592 List<Map<String,String>> list = getSieveDatas(currentUserHospPermissions,dates,cqSieveQueryRequest.getCityId());
1591 1593 response.setContentType("application/force-download");
1592 1594 response.setHeader("Content-Disposition", "attachment;filename=" + new String(("孕妇产前筛查和诊断情况月报表.xls").getBytes("UTF-8"), "ISO-8859-1"));
1593 1595 String path = this.getClass().getResource("/").getPath()+ "whfy_sieve.xls";
1594   - ExcelUtil.writeWhSieveExclFile(path, response.getOutputStream(), list,cqSieveQueryRequest.getTime());
  1596 + ExcelUtil.writeWhSieveExclFile(path, response.getOutputStream(), list,titleName);
1595 1597  
1596 1598 } catch (Exception e) {
1597 1599 ExceptionUtils.catchException(e, "exportSieveReportExcl error");