guoshilong
2023-05-25 affff835d01de682a503eee8b71d48bf35255a50
skjcmanager/skjcmanager-service/skjcmanager-user/src/main/java/cn/gistack/system/user/mapper/UserMapper.xml
@@ -39,10 +39,13 @@
            and account = #{user.account}
        </if>
        <if test="user.realName!=null and user.realName != ''">
            and real_name = #{user.realName}
            and real_name like concat(concat('%',#{user.realName}),'%')
        </if>
        <if test="user.userType!=null and user.userType != ''">
            and user_type = #{user.userType}
        </if>
        <if test="user.roleId!=null and user.roleId != ''">
            and role_id like concat('%',#{user.roleId},'%')
        </if>
        <if test="deptIdList!=null and deptIdList.size>0">
            and id in (
@@ -78,4 +81,15 @@
        where D.AD_CODE = #{user.adCode} and U.ROLE_ID like CONCAT('%',(select id from BLADE_ROLE where ROLE_ALIAS = 'qxgly'),'%')
    </select>
    <!--根据手机号码或者账户查询用户信息-->
    <select id="selectUserByPhoneOrAccount" resultType="cn.gistack.system.user.entity.User">
        select * from BLADE_USER where is_deleted = 0
        and TENANT_ID = #{tenantId}
        and (ACCOUNT = #{key} or PHONE = #{key})
    </select>
    <select id="getUserByPhoneIds" resultType="cn.gistack.system.user.entity.User">
        SELECT * FROM BLADE_USER
        WHERE IS_DELETED = 0 AND PHONE LIKE CONCAT('%',#{phoneIds},'%')
    </select>
</mapper>