xiaoyong931011
2022-06-10 93e281b3cc60c8d24a0ed5547d3d399c03f9bab6
src/main/resources/mapper/UserMapper.xml
@@ -9,6 +9,10 @@
        t_user a
        left join t_belong b on a.belong_id = b.id
        <where>
            and a.id not in (
            SELECT b.user_id FROM t_user_role b
            WHERE b.role_id = ( SELECT id FROM t_role WHERE role_name = #{record.roleName})
            )
            <if test="record != null" >
                <if test="record.username!=null">
                    and a.username like concat ('%',#{record.username},'%')