Commit 38650fc65b088a877148e3b46e2c7462e7ef884d
1 parent
72aa953fa0
Exists in
master
产程完成
Showing 6 changed files with 31 additions and 18 deletions
- parent/hospital.mac/src/main/java/com/lyms/hospital/dao/woman/WomanFetationRecordMapper.xml
- parent/hospital.mac/src/main/java/com/lyms/hospital/entity/childbirth/ChildbirthInfo.java
- parent/hospital.mac/src/main/java/com/lyms/hospital/entity/leave/LeaveInfo.java
- parent/hospital.mac/src/main/java/com/lyms/hospital/entity/recheck/PostpartumRee.java
- parent/hospital.mac/src/main/java/com/lyms/hospital/entity/woman/WomanFetationRecord.java
- parent/hospital.mac/src/main/java/com/lyms/hospital/entity/woman/WomanRecord.java
parent/hospital.mac/src/main/java/com/lyms/hospital/dao/woman/WomanFetationRecordMapper.xml
View file @
38650fc
| ... | ... | @@ -101,10 +101,33 @@ |
| 101 | 101 | </select> |
| 102 | 102 | |
| 103 | 103 | |
| 104 | - <select id="getFetationStages" resultMap="HighriskMapsResult"> | |
| 105 | - select | |
| 106 | - <include refid="Maps_Column_List"></include> | |
| 107 | - from HIGHRISK_MAPS m left join HIGHRISK_CONF c on m.SOURCE_ID = c.SOURCE_ID where m.DIAGNOSE_ID = #{id} | |
| 104 | + <select id="getFetationStages" resultType="com.lyms.hospital.entity.woman.FetationStages"> | |
| 105 | + select al.*,o.`NAME` as hospitalName from ( | |
| 106 | + select f.id,'孕妇建档' as title,BUILD_DATE as checkTime,1 as type,f.HOSTPITAL_ID as hospitalId from WOMAN_FETATION_RECORD f | |
| 107 | + where WOMAN_PERSON_ID = #{personId} and f.ID = f.SOURCE_ID | |
| 108 | + union all | |
| 109 | + select tt.id,title,tt.DIAGNOSE_TIME as checkTime,CASE type | |
| 110 | + WHEN 0 THEN 2 | |
| 111 | + WHEN 1 THEN 3 else null end as type,tt.org_id as hospitalId | |
| 112 | + from ( | |
| 113 | + select CASE type | |
| 114 | + WHEN 0 THEN '初诊p' | |
| 115 | + WHEN 1 THEN '复诊' else null end as title,d.* from DIAGNOSE_INFO d | |
| 116 | + where PERSON_ID = #{personId} | |
| 117 | + ) tt | |
| 118 | + union all | |
| 119 | + select c.id,'孕妇分娩' as title,CHILDBIRTH_TIME as checkTime,4 as type,c.org_id as hospitalId from CHILDBIRTH_INFO c | |
| 120 | + where PERSON_ID = #{personId} | |
| 121 | + union all | |
| 122 | + select id,'自动分娩' as title,FM_DATE as checkTime,5 as type,-1 as hospitalId from WOMAN_FETATION_RECORD f | |
| 123 | + where PERSON_ID = #{personId} and f.ID = f.SOURCE_ID and f.ifautofm = 1 | |
| 124 | + union all | |
| 125 | + select l.id,'出院小结' as title,leave_TIME as checkTime,6 as type,l.org_id as hospitalId from LEAVE_INFO l | |
| 126 | + where PERSON_ID = #{personId} | |
| 127 | + union all | |
| 128 | + select r.id,'产后复查' as title,REE_TIME as checkTime,7 as type,r.org_id as hospitalId from POSTPARTUM_REE r | |
| 129 | + where PERSON_ID = #{personId} | |
| 130 | + ) al left join SYS_ORGANIZATIONS o on al.hospitalId = o.ID order by al.checkTime desc,al.type asc | |
| 108 | 131 | </select> |
| 109 | 132 | |
| 110 | 133 | </mapper> |
parent/hospital.mac/src/main/java/com/lyms/hospital/entity/childbirth/ChildbirthInfo.java
View file @
38650fc
parent/hospital.mac/src/main/java/com/lyms/hospital/entity/leave/LeaveInfo.java
View file @
38650fc
parent/hospital.mac/src/main/java/com/lyms/hospital/entity/recheck/PostpartumRee.java
View file @
38650fc
parent/hospital.mac/src/main/java/com/lyms/hospital/entity/woman/WomanFetationRecord.java
View file @
38650fc
| ... | ... | @@ -27,8 +27,6 @@ |
| 27 | 27 | @TableId(value="ID") |
| 28 | 28 | private String id; |
| 29 | 29 | |
| 30 | - @TableId(value="PERSON_ID") | |
| 31 | - private String personId; | |
| 32 | 30 | /** |
| 33 | 31 | * 孕妇姓名 |
| 34 | 32 | */ |
| ... | ... | @@ -849,14 +847,6 @@ |
| 849 | 847 | |
| 850 | 848 | public void setFmDate(Date fmDate) { |
| 851 | 849 | this.fmDate = fmDate; |
| 852 | - } | |
| 853 | - | |
| 854 | - public String getPersonId() { | |
| 855 | - return personId; | |
| 856 | - } | |
| 857 | - | |
| 858 | - public void setPersonId(String personId) { | |
| 859 | - this.personId = personId; | |
| 860 | 850 | } |
| 861 | 851 | |
| 862 | 852 | public Integer getIfautofm() { |
parent/hospital.mac/src/main/java/com/lyms/hospital/entity/woman/WomanRecord.java
View file @
38650fc