|
@@ -241,13 +241,13 @@ public interface UpIdCollectionDao {
|
|
|
"left join t_yb_setl_modify_req c on (a.pat_no = c.pat_no and a.times = c.times) " +
|
|
|
"where revoked = 0 " +
|
|
|
"<if test=\"startTime !=null and startTime != '' \">" +
|
|
|
- " and setl_time >= #{startTime} and setl_time <= #{endTime} " +
|
|
|
+ " and a.setl_time >= #{startTime} and a.setl_time <= #{endTime} " +
|
|
|
"</if>" +
|
|
|
"<if test=\"setlType !=null and setlType != '' \">" +
|
|
|
- " and setl_type = #{setlType} " +
|
|
|
+ " and a.setl_type = #{setlType} " +
|
|
|
"</if>" +
|
|
|
"<if test=\"patNo !=null and patNo != '' \">" +
|
|
|
- " and pat_no = #{patNo} " +
|
|
|
+ " and a.pat_no = #{patNo} " +
|
|
|
"</if>" +
|
|
|
"<if test=\"insutypes.size > 0 \">" +
|
|
|
" and insutype in " +
|
|
@@ -255,7 +255,7 @@ public interface UpIdCollectionDao {
|
|
|
"#{item}" +
|
|
|
"</foreach>" +
|
|
|
"</if>" +
|
|
|
- "<if test=\"outDepts.size > 0 \">" +
|
|
|
+ "<if test=\"outDepts.size > 0 and outDepts != null \">" +
|
|
|
"and small_dept in " +
|
|
|
"<foreach collection='outDepts' item='item' index='index' open='(' close=')' separator=','>" +
|
|
|
"#{item} " +
|
|
@@ -328,7 +328,7 @@ public interface UpIdCollectionDao {
|
|
|
" and setl_type = #{setlType} " +
|
|
|
"</if>" +
|
|
|
"<if test=\"patNo !=null and patNo != '' \">" +
|
|
|
- " and pat_no = #{patNo} " +
|
|
|
+ " and a.pat_no = #{patNo} " +
|
|
|
"</if>" +
|
|
|
"<if test=\"insutypes.size > 0 \">" +
|
|
|
" and insutype in " +
|
|
@@ -437,12 +437,12 @@ public interface UpIdCollectionDao {
|
|
|
|
|
|
@Select("<script>" +
|
|
|
"select ward_code,ward_code_name = (select rtrim(name) from zd_unit_code where code = ward_code), " +
|
|
|
- " rtrim(inpatient_no) patNo " +
|
|
|
+ " rtrim(inpatient_no) patNo,admiss_times times " +
|
|
|
"from zy_detail_charge where inpatient_no in " +
|
|
|
"<foreach collection='patNos' item='item' index='index' open='(' close=')' separator=','>" +
|
|
|
"#{item}" +
|
|
|
"</foreach>" +
|
|
|
- "group by ward_code,inpatient_no" +
|
|
|
+ "group by ward_code,inpatient_no,admiss_times " +
|
|
|
"</script>")
|
|
|
List<SiSetlinfoTemp> zhuanKeKeShi(@Param("patNos") Set<String> patNos);
|
|
|
|