| | |
| | | <select id="getAccessControlWhiteInfo" parameterType="Map" resultType="Map"> |
| | | select t.third_id,t.third_id thirdId,t.id_card,t.id_card idCard,t.access_control_key,t.access_control_key |
| | | accessControlKey,t.status_cd,t.status_cd statusCd,t.person_name,t.person_name |
| | | personName,t.machine_id,t.machine_id machineId,t.acw_id,t.acw_id acwId,t.person_id,t.person_id |
| | | personName,t.acw_id,t.acw_id acwId,t.person_id,t.person_id |
| | | personId,t.tel,t.start_time,t.start_time startTime,t.end_time,t.end_time endTime,t.community_id,t.community_id |
| | | communityId,t.person_type,t.person_type personType,t.create_time createTime,m.machine_code,m.machine_name machineName, |
| | | td.`name` personTypeName |
| | | communityId,t.person_type,t.person_type personType,td.`name` personTypeName,t.create_time createTime,count(acwa.acwa_id) machineCount |
| | | from access_control_white t |
| | | left join machine m on t.machine_id = m.machine_id and m.status_cd = '0' |
| | | left join t_dict td on t.person_type = td.status_cd and td.table_name ='access_control_white' and td.table_columns = 'person_type' |
| | | left join access_control_white_auth acwa on t.acw_id = acwa.acw_id and acwa.community_id = t.community_id and acwa.status_cd = '0' |
| | | where 1 =1 |
| | | <if test="thirdId !=null and thirdId != ''"> |
| | | and t.third_id= #{thirdId} |
| | |
| | | </if> |
| | | <if test="personName !=null and personName != ''"> |
| | | and t.person_name= #{personName} |
| | | </if> |
| | | <if test="personNameLike !=null and personNameLike != ''"> |
| | | and t.person_name like concat('%',#{personNameLike},'%') |
| | | </if> |
| | | <if test="machineId !=null and machineId != ''"> |
| | | and t.machine_id= #{machineId} |
| | |
| | | <if test="personType !=null and personType != ''"> |
| | | and t.person_type= #{personType} |
| | | </if> |
| | | group by t.third_id,t.id_card,t.access_control_key,t.status_cd,t.person_name,t.acw_id,t.person_id,t.tel,t.start_time, |
| | | t.end_time,t.community_id,t.person_type,td.`name`,t.create_time |
| | | order by t.create_time desc |
| | | <if test="page != -1 and page != null "> |
| | | limit #{page}, #{row} |
| | |
| | | <if test="personName !=null and personName != ''"> |
| | | and t.person_name= #{personName} |
| | | </if> |
| | | <if test="personNameLike !=null and personNameLike != ''"> |
| | | and t.person_name like concat('%',#{personNameLike},'%') |
| | | </if> |
| | | <if test="machineId !=null and machineId != ''"> |
| | | and t.machine_id= #{machineId} |
| | | </if> |