Administrator
2024-01-25 6b268e3e7ee7e71d4dcb7760b005242679a1608f
pipIrr-platform/pipIrr-global/src/main/resources/mapper/BaUserMapper.xml
@@ -245,14 +245,18 @@
    <!--根据用户编号获取用户信息-->
    <select id="getUserInfoById" resultType="java.util.Map">
        SELECT
            id AS userId,
            name AS userName
        FROM ba_user
            us.id AS userId,
            us.name AS userName,
            us.phone,
            IFNULL(us.blockId, 0) AS blockId,
            IFNULL(blo.name, 0) AS blockName
        FROM ba_user us
            LEFT JOIN ba_block blo ON us.blockId = blo.id
        <where>
            AND disabled = 0
            AND deleted = 0
            AND us.disabled = 0
            AND us.deleted = 0
            <if test = "userId != null and userId > 0">
                AND ba_user.id = ${userId}
                AND us.id = ${userId}
            </if>
        </where>
    </select>