Browse Source

ai病例质控后台维护修改

wangfeng 5 years ago
parent
commit
87130217b1
31 changed files with 644 additions and 169 deletions
  1. 1 1
      config-server/src/main/resources/shared/mrman-service-dev.yml
  2. 1 1
      config-server/src/main/resources/shared/mrman-service-local.yml
  3. 1 1
      config-server/src/main/resources/shared/mrman-service-pre.yml
  4. 1 1
      config-server/src/main/resources/shared/mrman-service-pro.yml
  5. 1 1
      config-server/src/main/resources/shared/mrman-service-test.yml
  6. 4 2
      mrman-service/src/main/java/com/diagbot/dto/GetAllByHospitalDetialDTO.java
  7. 1 1
      mrman-service/src/main/java/com/diagbot/dto/GetUpdateInfoDetialDTO.java
  8. 1 1
      mrman-service/src/main/java/com/diagbot/dto/QcCasesAllDTO.java
  9. 41 3
      mrman-service/src/main/java/com/diagbot/dto/QcCasesEntryAllDTO.java
  10. 56 0
      mrman-service/src/main/java/com/diagbot/dto/QcCasesEntryDTO.java
  11. 27 0
      mrman-service/src/main/java/com/diagbot/dto/QcModeDTO.java
  12. 13 3
      mrman-service/src/main/java/com/diagbot/entity/CasesEntryHospital.java
  13. 62 46
      mrman-service/src/main/java/com/diagbot/entity/QcCases.java
  14. 84 71
      mrman-service/src/main/java/com/diagbot/entity/QcCasesEntry.java
  15. 157 0
      mrman-service/src/main/java/com/diagbot/entity/QcMode.java
  16. 2 1
      mrman-service/src/main/java/com/diagbot/facade/CasesEntryHospitalFacade.java
  17. 10 9
      mrman-service/src/main/java/com/diagbot/facade/QcCasesFacade.java
  18. 33 0
      mrman-service/src/main/java/com/diagbot/facade/QcModeFacade.java
  19. 2 1
      mrman-service/src/main/java/com/diagbot/mapper/QcCasesMapper.java
  20. 16 0
      mrman-service/src/main/java/com/diagbot/mapper/QcModeMapper.java
  21. 2 1
      mrman-service/src/main/java/com/diagbot/service/QcCasesService.java
  22. 16 0
      mrman-service/src/main/java/com/diagbot/service/QcModeService.java
  23. 2 1
      mrman-service/src/main/java/com/diagbot/service/impl/QcCasesServiceImpl.java
  24. 20 0
      mrman-service/src/main/java/com/diagbot/service/impl/QcModeServiceImpl.java
  25. 1 4
      mrman-service/src/main/java/com/diagbot/vo/InsertByHospitalVO.java
  26. 1 1
      mrman-service/src/main/java/com/diagbot/vo/QcCasesEntryAllVO.java
  27. 46 0
      mrman-service/src/main/java/com/diagbot/web/QcModeController.java
  28. 1 0
      mrman-service/src/main/resources/mapper/CasesEntryHospitalMapper.xml
  29. 15 9
      mrman-service/src/main/resources/mapper/QcCasesEntryMapper.xml
  30. 7 10
      mrman-service/src/main/resources/mapper/QcCasesMapper.xml
  31. 19 0
      mrman-service/src/main/resources/mapper/QcModeMapper.xml

+ 1 - 1
config-server/src/main/resources/shared/mrman-service-dev.yml

@@ -52,7 +52,7 @@ spring:
         master:
           driver-class-name: com.mysql.cj.jdbc.Driver
           platform: mysql
-          url: jdbc:mysql://192.168.2.236:3306/sys-qctest?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
+          url: jdbc:mysql://192.168.2.236:3306/qc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
           username: root
           password: lantone
           druid:

+ 1 - 1
config-server/src/main/resources/shared/mrman-service-local.yml

@@ -52,7 +52,7 @@ spring:
         master:
           driver-class-name: com.mysql.cj.jdbc.Driver
           platform: mysql
-          url: jdbc:mysql://192.168.2.236:3306/sys-mrqc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
+          url: jdbc:mysql://192.168.2.236:3306/qc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
           username: root
           password: lantone
           druid:

+ 1 - 1
config-server/src/main/resources/shared/mrman-service-pre.yml

@@ -52,7 +52,7 @@ spring:
         master:
           driver-class-name: com.mysql.cj.jdbc.Driver
           platform: mysql
-          url: jdbc:mysql://192.168.2.236:3306/sys-mrqc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
+          url: jdbc:mysql://192.168.2.236:3306/qc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
           username: root
           password: lantone
           druid:

+ 1 - 1
config-server/src/main/resources/shared/mrman-service-pro.yml

@@ -52,7 +52,7 @@ spring:
         master:
           driver-class-name: com.mysql.cj.jdbc.Driver
           platform: mysql
-          url: jdbc:mysql://192.168.2.236:3306/sys-mrqc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
+          url: jdbc:mysql://192.168.2.236:3306/qc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
           username: root
           password: lantone
           druid:

+ 1 - 1
config-server/src/main/resources/shared/mrman-service-test.yml

@@ -53,7 +53,7 @@ spring:
         master:
           driver-class-name: com.mysql.cj.jdbc.Driver
           platform: mysql
-          url: jdbc:mysql://192.168.2.236:3306/sys-mrqc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
+          url: jdbc:mysql://192.168.2.236:3306/qc?serverTimezone=GMT%2B8&useUnicode=true&characterEncoding=utf8&characterSetResults=utf8&useSSL=false
           username: root
           password: lantone
           druid:

+ 4 - 2
mrman-service/src/main/java/com/diagbot/dto/GetAllByHospitalDetialDTO.java

@@ -15,9 +15,11 @@ public class GetAllByHospitalDetialDTO {
     private String casesName;
     private String code;
     private String name;
+    private String modeName;
     private String precond;
-    private String levelNo;
+    private Long modeId;
     private String score;
-    private String isUsed;
+    private Integer isUsed;
+    private Integer isReject;
     private String msg;
 }

+ 1 - 1
mrman-service/src/main/java/com/diagbot/dto/GetUpdateInfoDetialDTO.java

@@ -13,6 +13,6 @@ import lombok.Setter;
 public class GetUpdateInfoDetialDTO {
     private String hospitalName;
     private String score;
-    private String isUsed;
+    private Integer isUsed;
     private String msg;
 }

+ 1 - 1
mrman-service/src/main/java/com/diagbot/dto/QcCasesAllDTO.java

@@ -51,5 +51,5 @@ public class QcCasesAllDTO {
      */
     private String remark;
 
-    private List<QcCasesEntry> qcCasesEntry;
+    private List<QcCasesEntryDTO> qcCasesEntry;
 }

+ 41 - 3
mrman-service/src/main/java/com/diagbot/dto/QcCasesEntryAllDTO.java

@@ -1,5 +1,7 @@
 package com.diagbot.dto;
 
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
 import com.diagbot.entity.QcCasesEntry;
 import lombok.Getter;
 import lombok.Setter;
@@ -11,9 +13,45 @@ import lombok.Setter;
  */
 @Getter
 @Setter
-public class QcCasesEntryAllDTO extends QcCasesEntry {
+public class QcCasesEntryAllDTO {
+
+    /**
+     * 主键
+     */
+    @TableId(value = "id", type = IdType.AUTO)
+    private Long id;
+
     /**
-     * 所属模块名称
+     * 病历id
      */
-    private String caseName;
+    private Long casesId;
+
+    private String casesName;
+
+    /**
+     * 数据模块ID-对应qc_mode.id
+     */
+    private Long modeId;
+
+    private String modeName;
+    private String code;
+
+    /**
+     * 条目
+     */
+    private String name;
+
+    private String precond;
+
+    /**
+     * 顺序号
+     */
+    private Integer orderNo;
+
+
+    /**
+     * 备注
+     */
+
+    private String remark;
 }

+ 56 - 0
mrman-service/src/main/java/com/diagbot/dto/QcCasesEntryDTO.java

@@ -0,0 +1,56 @@
+package com.diagbot.dto;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ * @author wangfeng
+ * @Description:
+ * @date 2020-04-27 10:09
+ */
+@Setter
+@Getter
+public class QcCasesEntryDTO {
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键
+     */
+    @TableId(value = "id", type = IdType.AUTO)
+    private Long id;
+
+    /**
+     * 病历id
+     */
+    private Long casesId;
+
+    private String casesName;
+
+    /**
+     * 数据模块ID-对应qc_mode.id
+     */
+    private Long modeId;
+
+    private String modeName;
+
+    private String code;
+
+    /**
+     * 条目
+     */
+    private String name;
+
+    private String precond;
+
+    /**
+     * 顺序号
+     */
+    private Integer orderNo;
+
+    /**
+     * 备注
+     */
+    private String remark;
+}

+ 27 - 0
mrman-service/src/main/java/com/diagbot/dto/QcModeDTO.java

@@ -0,0 +1,27 @@
+package com.diagbot.dto;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import lombok.Getter;
+import lombok.Setter;
+
+/**
+ * @author wangfeng
+ * @Description:
+ * @date 2020-04-26 17:25
+ */
+@Setter
+@Getter
+public class QcModeDTO {
+    private Long id;
+
+    /**
+     * 模块名称
+     */
+    private String name;
+
+    /**
+     * 排序号
+     */
+    private Integer orderNo;
+}

+ 13 - 3
mrman-service/src/main/java/com/diagbot/entity/CasesEntryHospital.java

@@ -65,13 +65,23 @@ public class CasesEntryHospital implements Serializable {
 
     private String msg;
 
-    private String isUsed;
+    private Integer isUsed;
 
-    public String getIsUsed() {
+    private Integer isReject;
+
+    public Integer getIsReject() {
+        return isReject;
+    }
+
+    public void setIsReject(Integer isReject) {
+        this.isReject = isReject;
+    }
+
+    public Integer getIsUsed() {
         return isUsed;
     }
 
-    public void setIsUsed(String isUsed) {
+    public void setIsUsed(Integer isUsed) {
         this.isUsed = isUsed;
     }
 

+ 62 - 46
mrman-service/src/main/java/com/diagbot/entity/QcCases.java

@@ -5,14 +5,15 @@ import com.baomidou.mybatisplus.annotation.TableId;
 
 import java.io.Serializable;
 import java.time.LocalDateTime;
+import java.util.Date;
 
 /**
  * <p>
- * 病历
+ * 模块数据标准
  * </p>
  *
  * @author wangfeng
- * @since 2020-03-10
+ * @since 2020-04-27
  */
 public class QcCases implements Serializable {
 
@@ -24,6 +25,26 @@ public class QcCases implements Serializable {
     @TableId(value = "id", type = IdType.AUTO)
     private Long id;
 
+    /**
+     * 模块名称
+     */
+    private String name;
+
+    /**
+     * 模块编码前缀
+     */
+    private String prefix;
+
+    /**
+     * 顺序号
+     */
+    private Integer orderNo;
+
+    /**
+     * 备注
+     */
+    private String remark;
+
     /**
      * 是否删除,N:未删除,Y:删除
      */
@@ -32,12 +53,12 @@ public class QcCases implements Serializable {
     /**
      * 记录创建时间
      */
-    private LocalDateTime gmtCreate;
+    private Date gmtCreate;
 
     /**
      * 记录修改时间,如果时间是1970年则表示纪录未修改
      */
-    private LocalDateTime gmtModified;
+    private Date gmtModified;
 
     /**
      * 创建人,0表示无创建人值
@@ -49,11 +70,20 @@ public class QcCases implements Serializable {
      */
     private String modifier;
 
-    /**
-     * 病历
-     */
-    private String name;
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+    public String getName() {
+        return name;
+    }
 
+    public void setName(String name) {
+        this.name = name;
+    }
     public String getPrefix() {
         return prefix;
     }
@@ -61,20 +91,19 @@ public class QcCases implements Serializable {
     public void setPrefix(String prefix) {
         this.prefix = prefix;
     }
+    public Integer getOrderNo() {
+        return orderNo;
+    }
 
-    private String prefix;
-
-    /**
-     * 备注
-     */
-    private String remark;
-
-    public Long getId() {
-        return id;
+    public void setOrderNo(Integer orderNo) {
+        this.orderNo = orderNo;
+    }
+    public String getRemark() {
+        return remark;
     }
 
-    public void setId(Long id) {
-        this.id = id;
+    public void setRemark(String remark) {
+        this.remark = remark;
     }
     public String getIsDeleted() {
         return isDeleted;
@@ -83,18 +112,18 @@ public class QcCases implements Serializable {
     public void setIsDeleted(String isDeleted) {
         this.isDeleted = isDeleted;
     }
-    public LocalDateTime getGmtCreate() {
+    public Date getGmtCreate() {
         return gmtCreate;
     }
 
-    public void setGmtCreate(LocalDateTime gmtCreate) {
+    public void setGmtCreate(Date gmtCreate) {
         this.gmtCreate = gmtCreate;
     }
-    public LocalDateTime getGmtModified() {
+    public Date getGmtModified() {
         return gmtModified;
     }
 
-    public void setGmtModified(LocalDateTime gmtModified) {
+    public void setGmtModified(Date gmtModified) {
         this.gmtModified = gmtModified;
     }
     public String getCreator() {
@@ -111,33 +140,20 @@ public class QcCases implements Serializable {
     public void setModifier(String modifier) {
         this.modifier = modifier;
     }
-    public String getName() {
-        return name;
-    }
-
-    public void setName(String name) {
-        this.name = name;
-    }
-    public String getRemark() {
-        return remark;
-    }
-
-    public void setRemark(String remark) {
-        this.remark = remark;
-    }
 
     @Override
     public String toString() {
         return "QcCases{" +
-            "id=" + id +
-            ", isDeleted=" + isDeleted +
-            ", gmtCreate=" + gmtCreate +
-            ", gmtModified=" + gmtModified +
-            ", creator=" + creator +
-            ", modifier=" + modifier +
-            ", name=" + name +
-            ", remark=" + remark +
+                "id=" + id +
+                ", name=" + name +
                 ", prefix=" + prefix +
-        "}";
+                ", orderNo=" + orderNo +
+                ", remark=" + remark +
+                ", isDeleted=" + isDeleted +
+                ", gmtCreate=" + gmtCreate +
+                ", gmtModified=" + gmtModified +
+                ", creator=" + creator +
+                ", modifier=" + modifier +
+                "}";
     }
 }

+ 84 - 71
mrman-service/src/main/java/com/diagbot/entity/QcCasesEntry.java

@@ -2,7 +2,7 @@ package com.diagbot.entity;
 
 import com.baomidou.mybatisplus.annotation.IdType;
 import com.baomidou.mybatisplus.annotation.TableId;
-
+import java.time.LocalDateTime;
 import java.io.Serializable;
 import java.util.Date;
 
@@ -12,7 +12,7 @@ import java.util.Date;
  * </p>
  *
  * @author wangfeng
- * @since 2020-03-10
+ * @since 2020-04-27
  */
 public class QcCasesEntry implements Serializable {
 
@@ -25,55 +25,60 @@ public class QcCasesEntry implements Serializable {
     private Long id;
 
     /**
-     * 是否删除,N:未删除,Y:删除
+     * 病历id
      */
-    private String isDeleted;
+    private Long casesId;
+
+    private String casesName;
 
     /**
-     * 记录创建时间
+     * 数据模块ID-对应qc_mode.id
      */
-    private Date gmtCreate;
+    private Long modeId;
+
+    private String code;
 
     /**
-     * 记录修改时间,如果时间是1970年则表示纪录未修改
+     * 条目
      */
-    private Date gmtModified;
+    private String name;
+
+    private String precond;
 
     /**
-     * 创建人,0表示无创建人值
+     * 顺序号
      */
-    private String creator;
+    private Integer orderNo;
 
     /**
-     * 修改人,如果为0则表示纪录未修改
+     * 备注
      */
-    private String modifier;
+    private String remark;
 
     /**
-     * 病历id
+     * 是否删除,N:未删除,Y:删除
      */
-    private Long casesId;
-
-    private String casesName;
-
-    private String code;
+    private String isDeleted;
 
     /**
-     * 条目
+     * 记录创建时间
      */
-    private String name;
+    private Date gmtCreate;
 
-    private String precond;
+    /**
+     * 记录修改时间,如果时间是1970年则表示纪录未修改
+     */
+    private Date gmtModified;
 
     /**
-     * 用于层级定义,由操作人控制录入,需按该列排序
+     * 创建人,0表示无创建人值
      */
-    private String levelNo;
+    private String creator;
 
     /**
-     * 备注
+     * 修改人,如果为0则表示纪录未修改
      */
-    private String remark;
+    private String modifier;
 
     public Long getId() {
         return id;
@@ -82,41 +87,6 @@ public class QcCasesEntry implements Serializable {
     public void setId(Long id) {
         this.id = id;
     }
-    public String getIsDeleted() {
-        return isDeleted;
-    }
-
-    public void setIsDeleted(String isDeleted) {
-        this.isDeleted = isDeleted;
-    }
-    public Date getGmtCreate() {
-        return gmtCreate;
-    }
-
-    public void setGmtCreate(Date gmtCreate) {
-        this.gmtCreate = gmtCreate;
-    }
-    public Date getGmtModified() {
-        return gmtModified;
-    }
-
-    public void setGmtModified(Date gmtModified) {
-        this.gmtModified = gmtModified;
-    }
-    public String getCreator() {
-        return creator;
-    }
-
-    public void setCreator(String creator) {
-        this.creator = creator;
-    }
-    public String getModifier() {
-        return modifier;
-    }
-
-    public void setModifier(String modifier) {
-        this.modifier = modifier;
-    }
     public Long getCasesId() {
         return casesId;
     }
@@ -131,6 +101,13 @@ public class QcCasesEntry implements Serializable {
     public void setCasesName(String casesName) {
         this.casesName = casesName;
     }
+    public Long getModeId() {
+        return modeId;
+    }
+
+    public void setModeId(Long modeId) {
+        this.modeId = modeId;
+    }
     public String getCode() {
         return code;
     }
@@ -152,12 +129,12 @@ public class QcCasesEntry implements Serializable {
     public void setPrecond(String precond) {
         this.precond = precond;
     }
-    public String getLevelNo() {
-        return levelNo;
+    public Integer getOrderNo() {
+        return orderNo;
     }
 
-    public void setLevelNo(String levelNo) {
-        this.levelNo = levelNo;
+    public void setOrderNo(Integer orderNo) {
+        this.orderNo = orderNo;
     }
     public String getRemark() {
         return remark;
@@ -166,23 +143,59 @@ public class QcCasesEntry implements Serializable {
     public void setRemark(String remark) {
         this.remark = remark;
     }
+    public String getIsDeleted() {
+        return isDeleted;
+    }
+
+    public void setIsDeleted(String isDeleted) {
+        this.isDeleted = isDeleted;
+    }
+    public Date getGmtCreate() {
+        return gmtCreate;
+    }
+
+    public void setGmtCreate(Date gmtCreate) {
+        this.gmtCreate = gmtCreate;
+    }
+    public Date getGmtModified() {
+        return gmtModified;
+    }
+
+    public void setGmtModified(Date gmtModified) {
+        this.gmtModified = gmtModified;
+    }
+    public String getCreator() {
+        return creator;
+    }
+
+    public void setCreator(String creator) {
+        this.creator = creator;
+    }
+    public String getModifier() {
+        return modifier;
+    }
+
+    public void setModifier(String modifier) {
+        this.modifier = modifier;
+    }
 
     @Override
     public String toString() {
-        return "CasesEntry{" +
+        return "QcCasesEntry{" +
                 "id=" + id +
-                ", isDeleted=" + isDeleted +
-                ", gmtCreate=" + gmtCreate +
-                ", gmtModified=" + gmtModified +
-                ", creator=" + creator +
-                ", modifier=" + modifier +
                 ", casesId=" + casesId +
                 ", casesName=" + casesName +
+                ", modeId=" + modeId +
                 ", code=" + code +
                 ", name=" + name +
                 ", precond=" + precond +
-                ", levelNo=" + levelNo +
+                ", orderNo=" + orderNo +
                 ", remark=" + remark +
+                ", isDeleted=" + isDeleted +
+                ", gmtCreate=" + gmtCreate +
+                ", gmtModified=" + gmtModified +
+                ", creator=" + creator +
+                ", modifier=" + modifier +
                 "}";
     }
 }

+ 157 - 0
mrman-service/src/main/java/com/diagbot/entity/QcMode.java

@@ -0,0 +1,157 @@
+package com.diagbot.entity;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableId;
+import java.io.Serializable;
+import java.util.Date;
+
+/**
+ * <p>
+ * 病历
+ * </p>
+ *
+ * @author wangfeng
+ * @since 2020-04-26
+ */
+public class QcMode implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 主键
+     */
+    @TableId(value = "id", type = IdType.AUTO)
+    private Long id;
+
+    /**
+     * 模块名称
+     */
+    private String name;
+
+    /**
+     * 排序号
+     */
+    private Integer orderNo;
+
+    /**
+     * 上级模块
+     */
+    private Long parentId;
+
+    /**
+     * 是否删除,N:未删除,Y:删除
+     */
+    private String isDeleted;
+
+    /**
+     * 记录创建时间
+     */
+    private Date gmtCreate;
+
+    /**
+     * 记录修改时间,如果时间是1970年则表示纪录未修改
+     */
+    private Date gmtModified;
+
+    /**
+     * 创建人,0表示无创建人值
+     */
+    private String creator;
+
+    /**
+     * 修改人,如果为0则表示纪录未修改
+     */
+    private String modifier;
+
+    /**
+     * 备注
+     */
+    private String remark;
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+    public Integer getOrderNo() {
+        return orderNo;
+    }
+
+    public void setOrderNo(Integer orderNo) {
+        this.orderNo = orderNo;
+    }
+    public Long getParentId() {
+        return parentId;
+    }
+
+    public void setParentId(Long parentId) {
+        this.parentId = parentId;
+    }
+    public String getIsDeleted() {
+        return isDeleted;
+    }
+
+    public void setIsDeleted(String isDeleted) {
+        this.isDeleted = isDeleted;
+    }
+    public Date getGmtCreate() {
+        return gmtCreate;
+    }
+
+    public void setGmtCreate(Date gmtCreate) {
+        this.gmtCreate = gmtCreate;
+    }
+    public Date getGmtModified() {
+        return gmtModified;
+    }
+
+    public void setGmtModified(Date gmtModified) {
+        this.gmtModified = gmtModified;
+    }
+    public String getCreator() {
+        return creator;
+    }
+
+    public void setCreator(String creator) {
+        this.creator = creator;
+    }
+    public String getModifier() {
+        return modifier;
+    }
+
+    public void setModifier(String modifier) {
+        this.modifier = modifier;
+    }
+    public String getRemark() {
+        return remark;
+    }
+
+    public void setRemark(String remark) {
+        this.remark = remark;
+    }
+
+    @Override
+    public String toString() {
+        return "QcMode{" +
+            "id=" + id +
+            ", name=" + name +
+            ", orderNo=" + orderNo +
+            ", parentId=" + parentId +
+            ", isDeleted=" + isDeleted +
+            ", gmtCreate=" + gmtCreate +
+            ", gmtModified=" + gmtModified +
+            ", creator=" + creator +
+            ", modifier=" + modifier +
+            ", remark=" + remark +
+        "}";
+    }
+}

+ 2 - 1
mrman-service/src/main/java/com/diagbot/facade/CasesEntryHospitalFacade.java

@@ -79,7 +79,8 @@ public class CasesEntryHospitalFacade extends CasesEntryHospitalServiceImpl {
                     getAllByHospitalDetialDTO.setCasesEntryId(qcCasesEntry.getId());
                     getAllByHospitalDetialDTO.setCasesName(qcCasesEntry.getCasesName());
                     getAllByHospitalDetialDTO.setCode(qcCasesEntry.getCode());
-                    getAllByHospitalDetialDTO.setLevelNo(qcCasesEntry.getLevelNo());
+                    getAllByHospitalDetialDTO.setModeId(qcCasesEntry.getModeId());
+                    //getAllByHospitalDetialDTO.setModeName(qcCasesEntry.getModeName());
                     getAllByHospitalDetialDTO.setMsg(casesEntryHospitalMap.get(qcCasesEntry.getId()).getMsg());
                     getAllByHospitalDetialDTO.setIsUsed(casesEntryHospitalMap.get(qcCasesEntry.getId()).getIsUsed());
                     getAllByHospitalDetialDTO.setScore(casesEntryHospitalMap.get(qcCasesEntry.getId()).getScore());

+ 10 - 9
mrman-service/src/main/java/com/diagbot/facade/QcCasesFacade.java

@@ -3,7 +3,7 @@ package com.diagbot.facade;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.diagbot.dto.QcCasesAllDTO;
 import com.diagbot.dto.QcCasesDTO;
-import com.diagbot.entity.CasesEntryHospital;
+import com.diagbot.dto.QcCasesEntryDTO;
 import com.diagbot.entity.QcCases;
 import com.diagbot.entity.QcCasesEntry;
 import com.diagbot.enums.IsDeleteEnum;
@@ -19,7 +19,6 @@ import org.springframework.stereotype.Component;
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Map;
-import java.util.stream.Collectors;
 
 /**
  * @author wangfeng
@@ -49,16 +48,18 @@ public class QcCasesFacade extends QcCasesServiceImpl {
         QueryWrapper<QcCasesEntry> qcCasesEntryQuery = new QueryWrapper<>();
         qcCasesEntryQuery
                 .eq("is_deleted", IsDeleteEnum.N.getKey())
-                .orderByDesc("level_no");
+                .orderByDesc("");
         List<QcCasesEntry> dataEntry = qcCasesEntryService.list(qcCasesEntryQuery);
+        List<QcCasesEntryDTO> dataEntryDTO = new ArrayList<>();
+        dataEntryDTO = BeanUtil.listCopyTo(dataEntry,QcCasesEntryDTO.class);
        // 然后把所有病例类型放进去
-        Map<Long, List<QcCasesEntry>> map
-                = EntityUtil.makeEntityListMap(dataEntry, "casesId");
+        Map<Long, List<QcCasesEntryDTO>> map
+                = EntityUtil.makeEntityListMap(dataEntryDTO, "casesId");
       //List<QcCases> data = qcCasesService.list();
         //把模板放进文件夹中
         if (dataNew.size() > 0) {
             for (QcCasesAllDTO ts : dataNew) {
-                List<QcCasesEntry> tmp = map.get(ts.getId());
+                List<QcCasesEntryDTO> tmp = map.get(ts.getId());
                 if (ListUtil.isNotEmpty(tmp)) {
                     ts.setQcCasesEntry(tmp);
                 }
@@ -78,15 +79,15 @@ public class QcCasesFacade extends QcCasesServiceImpl {
         List<QcCasesAllDTO> dataNew = new ArrayList<QcCasesAllDTO>();
         dataNew = BeanUtil.listCopyTo(data, QcCasesAllDTO.class);
         // 查出所有病例病例类型
-        List<QcCasesEntry> dataEntry = this.getCasesEntryByHospitalId(getAllByHospitalVO.getHospitalId());
+        List<QcCasesEntryDTO> dataEntry = this.getCasesEntryByHospitalId(getAllByHospitalVO.getHospitalId());
         // 然后把所有病例类型放进去
-        Map<Long, List<QcCasesEntry>> map
+        Map<Long, List<QcCasesEntryDTO>> map
                 = EntityUtil.makeEntityListMap(dataEntry, "casesId");
         //List<QcCases> data = qcCasesService.list();
         //把模板放进文件夹中
         if (dataNew.size() > 0) {
             for (QcCasesAllDTO ts : dataNew) {
-                List<QcCasesEntry> tmp = map.get(ts.getId());
+                List<QcCasesEntryDTO> tmp = map.get(ts.getId());
                 if (ListUtil.isNotEmpty(tmp)) {
                     ts.setQcCasesEntry(tmp);
                 }

+ 33 - 0
mrman-service/src/main/java/com/diagbot/facade/QcModeFacade.java

@@ -0,0 +1,33 @@
+package com.diagbot.facade;
+
+import com.diagbot.dto.QcModeDTO;
+import com.diagbot.entity.QcMode;
+import com.diagbot.service.QcModeService;
+import com.diagbot.service.impl.QcModeServiceImpl;
+import com.diagbot.util.BeanUtil;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.beans.factory.annotation.Qualifier;
+import org.springframework.stereotype.Component;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * @author wangfeng
+ * @Description:
+ * @date 2020-04-26 17:24
+ */
+@Component
+public class QcModeFacade extends QcModeServiceImpl {
+
+    @Autowired
+    QcModeService qcModeService;
+
+    public List<QcModeDTO> getModeAll() {
+        List<QcMode> data = qcModeService.list();
+        List<QcModeDTO> dataNew = new ArrayList<QcModeDTO>();
+        dataNew = BeanUtil.listCopyTo(data, QcModeDTO.class);
+        return dataNew;
+
+    }
+}

+ 2 - 1
mrman-service/src/main/java/com/diagbot/mapper/QcCasesMapper.java

@@ -2,6 +2,7 @@ package com.diagbot.mapper;
 
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
 import com.diagbot.dto.QcCasesDTO;
+import com.diagbot.dto.QcCasesEntryDTO;
 import com.diagbot.entity.QcCases;
 import com.diagbot.entity.QcCasesEntry;
 
@@ -19,5 +20,5 @@ public interface QcCasesMapper extends BaseMapper<QcCases> {
 
     List<QcCasesDTO> getCasesList(Long casesId);
 
-    List<QcCasesEntry> getCasesEntryByHospitalId(Long hospitalId);
+    List<QcCasesEntryDTO> getCasesEntryByHospitalId(Long hospitalId);
 }

+ 16 - 0
mrman-service/src/main/java/com/diagbot/mapper/QcModeMapper.java

@@ -0,0 +1,16 @@
+package com.diagbot.mapper;
+
+import com.diagbot.entity.QcMode;
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+
+/**
+ * <p>
+ * 病历 Mapper 接口
+ * </p>
+ *
+ * @author wangfeng
+ * @since 2020-04-26
+ */
+public interface QcModeMapper extends BaseMapper<QcMode> {
+
+}

+ 2 - 1
mrman-service/src/main/java/com/diagbot/service/QcCasesService.java

@@ -2,6 +2,7 @@ package com.diagbot.service;
 
 import com.baomidou.mybatisplus.extension.service.IService;
 import com.diagbot.dto.QcCasesDTO;
+import com.diagbot.dto.QcCasesEntryDTO;
 import com.diagbot.entity.QcCases;
 import com.diagbot.entity.QcCasesEntry;
 
@@ -20,5 +21,5 @@ public interface QcCasesService extends IService<QcCases> {
 
     public  List<QcCasesDTO>  getCasesLists(Long casesId);
 
-    List<QcCasesEntry> getCasesEntryByHospitalId(Long hospitalId);
+    List<QcCasesEntryDTO> getCasesEntryByHospitalId(Long hospitalId);
 }

+ 16 - 0
mrman-service/src/main/java/com/diagbot/service/QcModeService.java

@@ -0,0 +1,16 @@
+package com.diagbot.service;
+
+import com.diagbot.entity.QcMode;
+import com.baomidou.mybatisplus.extension.service.IService;
+
+/**
+ * <p>
+ * 病历 服务类
+ * </p>
+ *
+ * @author wangfeng
+ * @since 2020-04-26
+ */
+public interface QcModeService extends IService<QcMode> {
+
+}

+ 2 - 1
mrman-service/src/main/java/com/diagbot/service/impl/QcCasesServiceImpl.java

@@ -2,6 +2,7 @@ package com.diagbot.service.impl;
 
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.diagbot.dto.QcCasesDTO;
+import com.diagbot.dto.QcCasesEntryDTO;
 import com.diagbot.entity.QcCases;
 import com.diagbot.entity.QcCasesEntry;
 import com.diagbot.mapper.QcCasesMapper;
@@ -27,7 +28,7 @@ public class QcCasesServiceImpl extends ServiceImpl<QcCasesMapper, QcCases> impl
     }
 
     @Override
-    public List<QcCasesEntry> getCasesEntryByHospitalId(Long hospitalId) {
+    public List<QcCasesEntryDTO> getCasesEntryByHospitalId(Long hospitalId) {
         return baseMapper.getCasesEntryByHospitalId(hospitalId);
     }
 }

+ 20 - 0
mrman-service/src/main/java/com/diagbot/service/impl/QcModeServiceImpl.java

@@ -0,0 +1,20 @@
+package com.diagbot.service.impl;
+
+import com.diagbot.entity.QcMode;
+import com.diagbot.mapper.QcModeMapper;
+import com.diagbot.service.QcModeService;
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
+import org.springframework.stereotype.Service;
+
+/**
+ * <p>
+ * 病历 服务实现类
+ * </p>
+ *
+ * @author wangfeng
+ * @since 2020-04-26
+ */
+@Service
+public class QcModeServiceImpl extends ServiceImpl<QcModeMapper, QcMode> implements QcModeService {
+
+}

+ 1 - 4
mrman-service/src/main/java/com/diagbot/vo/InsertByHospitalVO.java

@@ -53,10 +53,7 @@ public class InsertByHospitalVO {
 
     private String precond;
 
-    /**
-     * 用于层级定义,由操作人控制录入,需按该列排序
-     */
-    private String levelNo;
+    private Integer modeId;
 
     /**
      * 备注

+ 1 - 1
mrman-service/src/main/java/com/diagbot/vo/QcCasesEntryAllVO.java

@@ -21,7 +21,7 @@ public class QcCasesEntryAllVO extends Page {
     /**
      * 用于层级定义,由操作人控制录入,需按该列排序
      */
-    private String levelNo;
+    private String modeId;
 
     /**
      * 条目

+ 46 - 0
mrman-service/src/main/java/com/diagbot/web/QcModeController.java

@@ -0,0 +1,46 @@
+package com.diagbot.web;
+
+
+import com.diagbot.annotation.SysLogger;
+import com.diagbot.dto.QcCasesDTO;
+import com.diagbot.dto.QcModeDTO;
+import com.diagbot.dto.RespDTO;
+import com.diagbot.facade.QcCasesFacade;
+import com.diagbot.facade.QcModeFacade;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestMapping;
+
+import org.springframework.stereotype.Controller;
+import org.springframework.web.bind.annotation.RestController;
+
+import java.util.List;
+
+/**
+ * <p>
+ * 病历 前端控制器
+ * </p>
+ *
+ * @author wangfeng
+ * @since 2020-04-26
+ */
+
+@RestController
+@RequestMapping("/qcMode")
+@Api(value = "医院数据模块相关接口", tags = { "医院数据模块相关接口" })
+public class QcModeController {
+
+    @Autowired
+    private QcModeFacade qcModeFacade;
+
+    @ApiOperation(value = "获取医院全部模块[by:wangfeng]",
+            notes = "获取医院全部模块")
+    @PostMapping("/getModes")
+    @SysLogger("getModes")
+    public RespDTO<List<QcModeDTO>> getModeAlls() {
+
+        return RespDTO.onSuc(qcModeFacade.getModeAll());
+    }
+}

+ 1 - 0
mrman-service/src/main/resources/mapper/CasesEntryHospitalMapper.xml

@@ -15,6 +15,7 @@
         <result column="score" property="score" />
         <result column="msg" property="msg" />
         <result column="is_used" property="isUsed" />
+        <result column="is_reject" property="isReject" />
         <result column="remark" property="remark" />
     </resultMap>
 

+ 15 - 9
mrman-service/src/main/resources/mapper/QcCasesEntryMapper.xml

@@ -5,31 +5,37 @@
     <!-- 通用查询映射结果 -->
     <resultMap id="BaseResultMap" type="com.diagbot.entity.QcCasesEntry">
         <id column="id" property="id" />
+        <result column="cases_id" property="casesId" />
+        <result column="cases_name" property="casesName" />
+        <result column="mode_id" property="modeId" />
+        <result column="code" property="code" />
+        <result column="name" property="name" />
+        <result column="precond" property="precond" />
+        <result column="order_no" property="orderNo" />
+        <result column="remark" property="remark" />
         <result column="is_deleted" property="isDeleted" />
         <result column="gmt_create" property="gmtCreate" />
         <result column="gmt_modified" property="gmtModified" />
         <result column="creator" property="creator" />
         <result column="modifier" property="modifier" />
-        <result column="cases_id" property="casesId" />
-        <result column="name" property="name" />
-        <result column="remark" property="remark" />
     </resultMap>
 
     <select id="getAllQcCasesEntry" parameterType="com.diagbot.vo.QcCasesEntryAllVO" resultType="com.diagbot.dto.QcCasesEntryAllDTO">
-        SELECT a.* FROM `qc_cases_entry` a
+        SELECT a.*,b.name as modeName FROM qc_cases_entry a
+        LEFT JOIN  qc_mode b ON b.id= a.mode_id
         WHERE a.is_deleted = 'N'
         <if test="casesId != null and casesId != ''">
             AND a.cases_id = #{casesId}
         </if>
-        <if test="levelNo != null and levelNo != ''">
-            AND a.level_no = #{levelNo}
+        <if test="modeId != null and modeId != ''">
+            AND b.modeId = #{modeId}
         </if>
         <if test="name != null and name != ''">
-            AND a.`name` LIKE CONCAT('%',#{name},'%')
+            AND a.name LIKE CONCAT('%',#{name},'%')
         </if>
         <if test="code != null and code != ''">
-            AND a.`code` = #{code}
+            AND a.code = #{code}
         </if>
-        ORDER BY a.cases_id,a.id,a.level_no
+        ORDER BY a.cases_id,a.id
     </select>
 </mapper>

+ 7 - 10
mrman-service/src/main/resources/mapper/QcCasesMapper.xml

@@ -3,20 +3,17 @@
 <mapper namespace="com.diagbot.mapper.QcCasesMapper">
 
     <!-- 通用查询映射结果 -->
-    <resultMap id="BaseResultMap" type="com.diagbot.entity.QcCasesEntry">
+    <resultMap id="BaseResultMap" type="com.diagbot.entity.QcCases">
         <id column="id" property="id" />
+        <result column="name" property="name" />
+        <result column="prefix" property="prefix" />
+        <result column="order_no" property="orderNo" />
+        <result column="remark" property="remark" />
         <result column="is_deleted" property="isDeleted" />
         <result column="gmt_create" property="gmtCreate" />
         <result column="gmt_modified" property="gmtModified" />
         <result column="creator" property="creator" />
         <result column="modifier" property="modifier" />
-        <result column="cases_id" property="casesId" />
-        <result column="cases_name" property="casesName" />
-        <result column="code" property="code" />
-        <result column="name" property="name" />
-        <result column="precond" property="precond" />
-        <result column="level_no" property="levelNo" />
-        <result column="remark" property="remark" />
     </resultMap>
 
     <select id="getCasesList" parameterType="Long" resultType="com.diagbot.dto.QcCasesDTO">
@@ -38,11 +35,11 @@
 
     </select>
 
-    <select id="getCasesEntryByHospitalId" resultType="com.diagbot.entity.QcCasesEntry">
+    <select id="getCasesEntryByHospitalId" resultType="com.diagbot.entity.QcCasesEntryDTO">
         SELECT * FROM `qc_cases_entry` a
         LEFT JOIN qc_cases_entry_hospital b on a.id = b.cases_entry_id
         WHERE a.is_deleted='N' AND b.is_deleted='N'
         AND b.hospital_id = #{hospitalId}
-        ORDER BY a.level_no DESC
+        ORDER BY a.cases_id,a.order_no DESC
     </select>
 </mapper>

+ 19 - 0
mrman-service/src/main/resources/mapper/QcModeMapper.xml

@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.diagbot.mapper.QcModeMapper">
+
+    <!-- 通用查询映射结果 -->
+    <resultMap id="BaseResultMap" type="com.diagbot.entity.QcMode">
+        <id column="id" property="id" />
+        <result column="name" property="name" />
+        <result column="order_no" property="orderNo" />
+        <result column="parent_id" property="parentId" />
+        <result column="is_deleted" property="isDeleted" />
+        <result column="gmt_create" property="gmtCreate" />
+        <result column="gmt_modified" property="gmtModified" />
+        <result column="creator" property="creator" />
+        <result column="modifier" property="modifier" />
+        <result column="remark" property="remark" />
+    </resultMap>
+
+</mapper>