diff --git a/parent/hospital.mac/src/main/java/com/lyms/hospital/entity/history/HistorySource.java b/parent/hospital.mac/src/main/java/com/lyms/hospital/entity/history/HistorySource.java index 51840a0..95680a4 100644 --- a/parent/hospital.mac/src/main/java/com/lyms/hospital/entity/history/HistorySource.java +++ b/parent/hospital.mac/src/main/java/com/lyms/hospital/entity/history/HistorySource.java @@ -3,6 +3,8 @@ package com.lyms.hospital.entity.history; import com.baomidou.mybatisplus.annotations.TableId; import com.baomidou.mybatisplus.annotations.TableField; import com.baomidou.mybatisplus.annotations.TableName; +import com.lyms.util.InstanceUtils; + import java.io.Serializable; import java.util.List; @@ -59,7 +61,7 @@ public class HistorySource implements Serializable { * 子级别元素 */ @TableField(exist=false) - private List children; + private List children = InstanceUtils.newArrayList(); public String getId() { return id; diff --git a/parent/hospital.mac/src/main/java/com/lyms/hospital/service/history/impl/HistorySourceServiceImpl.java b/parent/hospital.mac/src/main/java/com/lyms/hospital/service/history/impl/HistorySourceServiceImpl.java index b89e03d..b030ed9 100644 --- a/parent/hospital.mac/src/main/java/com/lyms/hospital/service/history/impl/HistorySourceServiceImpl.java +++ b/parent/hospital.mac/src/main/java/com/lyms/hospital/service/history/impl/HistorySourceServiceImpl.java @@ -31,8 +31,8 @@ public class HistorySourceServiceImpl extends ServiceImpl dataList = null; EntityWrapper ew = new EntityWrapper(); ew.where("enable=1"); - if(null != historyPatientType){ - ew.and("type={}", "'"+historyPatientType+"'"); + if(historyPatientType.length > 0){ + ew.and("type={0}", "'"+historyPatientType[0]+"'"); } dataList = selectList(ew); return dataList; @@ -47,13 +47,11 @@ public class HistorySourceServiceImpl extends ServiceImpl