Browse Source

修复:agency_pids为""的小区,社区查询搜不出来的bug

dev
wangxianzhang 4 years ago
parent
commit
5f074419ff
  1. 5
      epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcHouseDao.xml

5
epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcHouseDao.xml

@ -130,7 +130,10 @@
LEFT JOIN ic_building_unit d on a.BUILDING_UNIT_ID = d.ID and d.DEL_FLAG = '0' LEFT JOIN ic_building_unit d on a.BUILDING_UNIT_ID = d.ID and d.DEL_FLAG = '0'
<where> <where>
<if test="pids != null and pids != ''"> <if test="pids != null and pids != ''">
AND CONCAT(c.AGENCY_PIDS,':',c.AGENCY_ID) like CONCAT(#{pids},'%') case c.AGENCY_PIDS
when '' then CONCAT(c.AGENCY_ID) like CONCAT(#{pids}, '%')
else CONCAT(c.AGENCY_PIDS, ':', c.AGENCY_ID) like CONCAT(#{pids}, '%')
end
</if> </if>
<if test="buildingId != null and buildingId.trim() != ''"> <if test="buildingId != null and buildingId.trim() != ''">
AND a.BUILDING_ID = #{buildingId} AND a.BUILDING_ID = #{buildingId}

Loading…
Cancel
Save