zhubaomin
2025-04-07 ecef3df4890be54c1da2a8a4fc1c8c1f50f1c263
pipIrr-platform/pipIrr-global/src/main/resources/mapper/BaUserMapper.xml
@@ -379,4 +379,22 @@
        FROM  ba_user
        WHERE disabled = 0 AND deleted = 0
    </select>
    <!--获取巡检员列表-->
    <select id="getInspectors" resultType="com.dy.pipIrrGlobal.voBa.VoRoleSimple">
        SELECT
            us.id AS inspectorId,
            us.name AS inspector
        FROM ba_user us
            INNER JOIN ba_user_role ur ON ur.userId = us.id
            INNER JOIN ba_role rol ON rol.id = ur.roleId
        <where>
            AND us.disabled = 0
            AND us.deleted = 0
            AND rol.`name` = '巡检员'
            <if test = "inspector != null and inspector !=''">
                AND us.name LIKE CONCAT('%',#{inspector},'%')
            </if>
        </where>
    </select>
</mapper>