#
luxiaotao1123
2024-02-12 3c9589bcfaa163d410ae7987a3121e4ed68d60ab
zy-asrs-wcs/src/main/resources/mapper/sys/UserRoleMapper.xml
@@ -3,13 +3,14 @@
<mapper namespace="com.zy.asrs.wcs.sys.mapper.UserRoleMapper">
    <select id="selectByUserId" resultType="com.zy.asrs.wcs.sys.entity.Role">
        SELECT *
        FROM sys_role
        WHERE role_id IN (
            SELECT role_id
            FROM sys_user_role
            WHERE user_id = #{userId}
        select *
        from sys_role
        where 1=1
        and id in (
            select role_id
            from sys_user_role
            where user_id = #{userId}
        )
        AND deleted = 0
        and deleted = 0
    </select>
</mapper>