Parcourir la source

Merge remote-tracking branch 'origin/20210512_yw_check' into 20210512_yw_check

songxinlu il y a 4 ans
Parent
commit
698ff273bc

+ 50 - 0
src/main/java/com/diagbot/enums/CheckStatusEnum.java

@@ -0,0 +1,50 @@
+package com.diagbot.enums;
+
+import com.diagbot.core.KeyedNamed;
+import lombok.Setter;
+
+/**
+ * @author wangfeng
+ * @Description: TODO
+ * @date 2018年11月21日 下午2:31:42
+ */
+public enum CheckStatusEnum implements KeyedNamed {
+    Disable(0, "未核查"),
+    Enable(1, "已核查");
+
+    @Setter
+    private int key;
+
+    @Setter
+    private String name;
+
+    CheckStatusEnum(int key, String name) {
+        this.key = key;
+        this.name = name;
+    }
+
+    public static CheckStatusEnum getEnum(int key) {
+        for (CheckStatusEnum item : CheckStatusEnum.values()) {
+            if (item.key == key) {
+                return item;
+            }
+        }
+        return null;
+    }
+
+    public static String getName(int key) {
+        CheckStatusEnum item = getEnum(key);
+        return item != null ? item.name : null;
+    }
+
+    @Override
+    public int getKey() {
+        return key;
+    }
+
+    @Override
+    public String getName() {
+        return name;
+    }
+}
+

+ 3 - 0
src/main/java/com/diagbot/facade/RecordCheckFacade.java

@@ -8,6 +8,7 @@ import com.diagbot.entity.MedQcresultDetail;
 import com.diagbot.entity.SysUserDept;
 import com.diagbot.entity.SysUserRole;
 import com.diagbot.enums.CheckJobTypeEnum;
+import com.diagbot.enums.CheckStatusEnum;
 import com.diagbot.enums.CheckTypeEnum;
 import com.diagbot.enums.CheckerRoleEnum;
 import com.diagbot.exception.CommonErrorCode;
@@ -84,6 +85,8 @@ public class RecordCheckFacade {
             Map<String, Long> behospitalCodeCasesMap = medQcresultDetailService.list(medQcresultDetailQueryWrapper).stream().collect(Collectors.groupingBy(MedQcresultDetail::getBehospitalCode, Collectors.counting()));
             iPage.getRecords().forEach(i -> {
                 i.setCasesEntryNum(behospitalCodeCasesMap.get(i.getBehospitalCode()) == null ? 0 : behospitalCodeCasesMap.get(i.getBehospitalCode()).intValue());
+                i.setMonth(i.getJobDistributionTime());
+                i.setStatus(CheckStatusEnum.getName(Integer.parseInt(i.getStatus())));
             });
         }
 

+ 1 - 1
src/main/resources/bootstrap.yml

@@ -2,7 +2,7 @@ spring:
   application:
     name: mrqc-sys
   profiles:
-    active: local
+    active: test
   main:
     allow-bean-definition-overriding: true
 

+ 1 - 1
src/main/resources/mapper/BasDeptInfoMapper.xml

@@ -27,7 +27,7 @@
             `bas_dept_info` t
         WHERE
             t.is_deleted = 'N'
-        AND t.station = '住院' or t.station = '质管'
+        AND (t.station = '住院' or t.station = '质管')
         AND t.hospital_id = #{hospitalId}
         <if test="inputStr !=null and inputStr != ''">
             AND (UPPER(t.spell) LIKE CONCAT('%', UPPER(TRIM(#{inputStr})),'%') OR UPPER(t.dept_name) LIKE CONCAT('%', UPPER(TRIM(#{inputStr})),'%'))

+ 4 - 4
src/main/resources/mapper/MedCheckInfoMapper.xml

@@ -208,7 +208,7 @@
     <select id="getCheckWorkPage" resultType="com.diagbot.dto.CheckWorkDTO">
         SELECT
         mbi.behospital_code behospitalCode,
-        mbi.name,
+        mbi.`name`,
         mbi.file_code fileCode,
         mbi.sex,
         mhp.age,
@@ -217,7 +217,7 @@
         mhp.behospital_day_num behospitalDayNum,
         mbi.doctor_name doctorName,
         mqi.score_res scoreRes,
-        mqi.level,
+        mqi.`level`,
         mbi.diagnose,
         CASE WHEN mbt.behospital_type='出院病人' THEN '6'
         WHEN mbt.behospital_type='死亡病人' THEN '6'
@@ -262,7 +262,7 @@
             AND mci.job_create_time is null
         </if>
         <if test="name != null and name != ''">
-            AND mbi.name like CONCAT('%',#{name},'%')
+            AND mbi.`name` like CONCAT('%',#{name},'%')
         </if>
         <if test="behospitalCode != null and behospitalCode != ''">
             AND mbi.behospital_code like CONCAT('%',#{behospitalCode},'%')
@@ -286,7 +286,7 @@
             AND mbi.diagnose LIKE CONCAT( '%', #{diagnose}, '%' )
         </if>
         <if test="level != null and level != ''">
-            AND mqi.level= #{level}
+            AND mqi.`level`= #{level}
         </if>
         <if test="isPlacefile != null and isPlacefile != ''">
             AND mbi.is_placefile = #{isPlacefile}