gaodm 5 år sedan
förälder
incheckning
e774161827

+ 2 - 0
src/main/java/com/diagbot/config/ResourceServerConfigurer.java

@@ -122,6 +122,8 @@ public class ResourceServerConfigurer extends ResourceServerConfigurerAdapter {
                 .antMatchers("/console/export/getAverageFeeExport").permitAll()
                 .antMatchers("/console/export/levelPercentGroupByDeptExport").permitAll()
                 .antMatchers("/console/export/entryCountGroupByEntryExport").permitAll()
+                .antMatchers("/console/export/entryCountGroupByCaseExport").permitAll()
+                .antMatchers("/console/export/entryStatisticsExport").permitAll()
                 .antMatchers("/qc/data/sendDoctorInfos").permitAll()
                 .antMatchers("/qc/data/sendDeptInfos").permitAll()
                 .antMatchers("/qc/data/sendRecordTypes").permitAll()

+ 2 - 0
src/main/java/com/diagbot/config/security/UrlAccessDecisionManager.java

@@ -165,6 +165,8 @@ public class UrlAccessDecisionManager implements AccessDecisionManager {
                 || matchers("/console/export/getAverageFeeExport", request)
                 || matchers("/console/export/levelPercentGroupByDeptExport", request)
                 || matchers("/console/export/entryCountGroupByEntryExport", request)
+                || matchers("/console/export/entryCountGroupByCaseExport", request)
+                || matchers("/console/export/entryStatisticsExport", request)
                 || matchers("/qc/data/sendDoctorInfos", request)
                 || matchers("/qc/data/sendDeptInfos", request)
                 || matchers("/qc/data/sendRecordTypes", request)

+ 14 - 0
src/main/java/com/diagbot/dto/EntryStatisticsDTO.java

@@ -1,5 +1,6 @@
 package com.diagbot.dto;
 
+import cn.afterturn.easypoi.excel.annotation.Excel;
 import lombok.Getter;
 import lombok.Setter;
 
@@ -18,10 +19,12 @@ public class EntryStatisticsDTO {
     /**
      * 科室名称
      */
+    @Excel(name = "科室名称", width = 30, orderNum = "1")
     private String deptName;
     /**
      * 未在24小时内完成会诊数
      */
+    @Excel(name = "未在24小时内完成会诊数", width = 15, orderNum = "2")
     private Integer consultationNum = 0;
     /**
      * 未在24小时内完成会诊条目id
@@ -38,6 +41,7 @@ public class EntryStatisticsDTO {
     /**
      * 未在24小时内完成会诊率(百分比)
      */
+    @Excel(name = "未在24小时内完成会诊率", width = 15, orderNum = "3")
     private String consultationPercentStr = "0.00%";
     /**
      * 会诊病历数
@@ -54,6 +58,7 @@ public class EntryStatisticsDTO {
     /**
      * 手术记录名称不匹配数
      */
+    @Excel(name = "手术记录名称不匹配数", width = 15, orderNum = "4")
     private Integer operationNameNum = 0;
     /**
      * 手术记录名称不匹配率
@@ -62,6 +67,7 @@ public class EntryStatisticsDTO {
     /**
      * 手术记录名称不匹配率(百分比)
      */
+    @Excel(name = "手术记录名称不匹配率", width = 15, orderNum = "5")
     private String operationNamePercentStr = "0.00%";
     /**
      * 术后首程未在15分钟内完成条目id
@@ -74,6 +80,7 @@ public class EntryStatisticsDTO {
     /**
      * 术后首程未在15分钟内完成数
      */
+    @Excel(name = "术后首程未在15分钟内完成数", width = 15, orderNum = "6")
     private Integer operation15MinuteNum = 0;
     /**
      * 术后首程未在15分钟内完成率
@@ -82,6 +89,7 @@ public class EntryStatisticsDTO {
     /**
      * 术后首程未在15分钟内完成率(百分比)
      */
+    @Excel(name = "术后首程未在15分钟内完成率", width = 15, orderNum = "7")
     private String operation15MinutePercentStr = "0.00%";
     /**
      * 病案首页手术时间不匹配条目id
@@ -94,6 +102,7 @@ public class EntryStatisticsDTO {
     /**
      * 病案首页手术时间不匹配数
      */
+    @Excel(name = "病案首页手术时间不匹配数", width = 15, orderNum = "8")
     private Integer operationTimeNum = 0;
     /**
      * 病案首页手术时间不匹配率
@@ -102,6 +111,7 @@ public class EntryStatisticsDTO {
     /**
      * 病案首页手术时间不匹配率(百分比)
      */
+    @Excel(name = "病案首页手术时间不匹配率", width = 15, orderNum = "9")
     private String operationTimePercentStr = "0.00%";
     /**
      * 手术记录病历数
@@ -118,6 +128,7 @@ public class EntryStatisticsDTO {
     /**
      * 未在6小时内书写危急值记录数
      */
+    @Excel(name = "未在6小时内书写危急值记录数", width = 15, orderNum = "10")
     private Integer crisisNum = 0;
     /**
      * 未在6小时内书写危急值记录率
@@ -126,6 +137,7 @@ public class EntryStatisticsDTO {
     /**
      * 未在6小时内书写危急值记录率(百分比)
      */
+    @Excel(name = "未在6小时内书写危急值记录率", width = 15, orderNum = "11")
     private String crisisPercentStr = "0.00%";
     /**
      * 危急值记录病历数
@@ -142,6 +154,7 @@ public class EntryStatisticsDTO {
     /**
      * 阶段小节未书写数
      */
+    @Excel(name = "阶段小节未书写数", width = 15, orderNum = "12")
     private Integer stageSummaryNum = 0;
     /**
      * 阶段小节未书写率
@@ -150,6 +163,7 @@ public class EntryStatisticsDTO {
     /**
      * 阶段小节未书写率(百分比)
      */
+    @Excel(name = "阶段小节未书写率", width = 15, orderNum = "13")
     private String stageSummaryPercentStr = "0.00%";
     /**
      * 病人住院超过30天的病历数

+ 3 - 0
src/main/java/com/diagbot/dto/NumDTO.java

@@ -1,5 +1,6 @@
 package com.diagbot.dto;
 
+import cn.afterturn.easypoi.excel.annotation.Excel;
 import lombok.Getter;
 import lombok.Setter;
 
@@ -15,6 +16,7 @@ public class NumDTO {
     /**
      * 名称
      */
+    @Excel(name = "模块名称", width = 20, orderNum = "1")
     private String name;
     /**
      * 总数
@@ -31,5 +33,6 @@ public class NumDTO {
     /**
      * 占比(百分比)
      */
+    @Excel(name = "缺陷占比", orderNum = "2")
     private String percentStr = "0.00%";
 }

+ 31 - 0
src/main/java/com/diagbot/facade/ConsoleExportFacade.java

@@ -5,11 +5,14 @@ import com.diagbot.dto.AverageStatisticsDTO;
 import com.diagbot.dto.AverageStatisticsFeeDTO;
 import com.diagbot.dto.EntryNumDTO;
 import com.diagbot.dto.EntryNumGroupDTO;
+import com.diagbot.dto.EntryStatisticsDTO;
 import com.diagbot.dto.HomePageNumDTO;
 import com.diagbot.dto.LevelStatisticsDTO;
 import com.diagbot.dto.LevelStatisticsTZDTO;
+import com.diagbot.dto.NumDTO;
 import com.diagbot.dto.QcResultPercentDTO;
 import com.diagbot.util.ExcelUtils;
+import com.diagbot.vo.EntryStatisticsVO;
 import com.diagbot.vo.FilterOrderVO;
 import com.diagbot.vo.FilterPageByAverageVO;
 import com.diagbot.vo.FilterPageVO;
@@ -142,4 +145,32 @@ public class ConsoleExportFacade {
         String fileName = "缺陷详情.xls";
         ExcelUtils.exportExcel(page.getRecords(), null, "sheet1", EntryNumGroupDTO.class, fileName, response, 12.8f);
     }
+
+
+    /**
+     * 各模块缺陷占比导出
+     *
+     * @param filterPageVO
+     * @return
+     */
+    public void entryCountGroupByCaseExport(HttpServletResponse response, FilterPageVO filterPageVO) {
+        filterPageVO.setCurrent(1L);
+        filterPageVO.setSize(Long.MAX_VALUE);
+        filterPageVO.setSearchCount(false);
+        IPage<NumDTO> page = consoleFacade.entryCountGroupByCasePage(filterPageVO);
+        String fileName = "缺陷详情.xls";
+        ExcelUtils.exportExcel(page.getRecords(), null, "sheet1", NumDTO.class, fileName, response, 12.8f);
+    }
+
+    /**
+     * 关键条目缺陷占比统计
+     *
+     * @param entryStatisticsVO
+     * @return
+     */
+    public void entryStatisticsExport(HttpServletResponse response, EntryStatisticsVO entryStatisticsVO) {
+        List<EntryStatisticsDTO> records = consoleFacade.entryStatistics(entryStatisticsVO);
+        String fileName = "关键条目缺陷占比统计.xls";
+        ExcelUtils.exportExcel(records, null, "sheet1", EntryStatisticsDTO.class, fileName, response, 12.8f);
+    }
 }

+ 33 - 0
src/main/java/com/diagbot/web/ConsoleExportController.java

@@ -2,6 +2,7 @@ package com.diagbot.web;
 
 import com.diagbot.annotation.SysLogger;
 import com.diagbot.facade.ConsoleExportFacade;
+import com.diagbot.vo.EntryStatisticsVO;
 import com.diagbot.vo.FilterOrderVO;
 import com.diagbot.vo.FilterPageByAverageVO;
 import com.diagbot.vo.FilterPageVO;
@@ -162,4 +163,36 @@ public class ConsoleExportController {
         consoleExportFacade.entryCountGroupByEntryExport(response, filterPageVO);
     }
 
+    /**
+     * 各模块缺陷占比导出
+     *
+     * @param filterPageVO
+     * @return
+     */
+    @ApiOperation(value = "各模块缺陷占比导出[by:gaodm]",
+            notes = "type: 统计维度 1-本月,2-本年(必填)<br>")
+    @PostMapping("/entryCountGroupByCaseExport")
+    @SysLogger("entryCountGroupByCaseExport")
+    public void entryCountGroupByCaseExport(HttpServletResponse response, @RequestBody @Valid FilterPageVO filterPageVO) {
+        consoleExportFacade.entryCountGroupByCaseExport(response, filterPageVO);
+    }
+
+    /**
+     * 关键条目缺陷占比统计导出
+     *
+     * @param entryStatisticsVO
+     * @return
+     */
+    @ApiOperation(value = "关键条目缺陷占比统计导出[by:gaodm]",
+            notes = "deptName:科室名称 <br>" +
+                    "asc: 排序(升序) <br>" +
+                    "desc:排序(降序) <br>" +
+                    "startDate: 起始时间 <br>" +
+                    "endDate: 截止时间 <br>")
+    @PostMapping("/entryStatisticsExport")
+    @SysLogger("entryStatisticsExport")
+    public void entryStatisticsExport(HttpServletResponse response, @RequestBody @Valid EntryStatisticsVO entryStatisticsVO) {
+        consoleExportFacade.entryStatisticsExport(response, entryStatisticsVO);
+    }
+
 }