<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.xq.mapper.UserInfoMapper">

    <select id="pageAdmin" resultType="com.ruoyi.xq.dto.admin.user.UserInfoAdminVo">
        select t2.*,
            t1.nickname,t1.type,t1.mobile,t1.avatar,t1.gender,t1.age,t1.birthday,
        t1.height,t1.weight,t1.somatotype,t1.zodiac,t1.sign,t1.residence_name,t1.address_name,t1.residence_city_name,
        t1.education,t1.marriage,t1.profession,t1.annual_income,t1.company_nature,t1.for_personals,
        t1.remark,t1.status,t1.finish_base_status
        from xq_user t1
        join xq_user_info t2 on t1.id = t2.user_id
        <where>
            <if test="bo.usercode != null and bo.usercode != ''">
                and t1.usercode = #{bo.usercode}
            </if>
            <if test="bo.mobile != null and bo.mobile != ''">
                and t1.mobile = #{bo.mobile}
            </if>
            <if test="bo.nickname != null and bo.nickname != ''">
                and t1.nickname like concat('%',#{bo.nickname},'%')
            </if>
        </where>
    </select>


</mapper>
