| 
						
						
							
								
							
						
						
					 | 
					@ -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} | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
					
  |