|
|
@@ -338,7 +338,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<select id="selectByNikeName" resultType="com.ruoyi.common.core.domain.entity.SysUser">
|
|
|
select a.user_id userId, a.user_name userName,a.nick_name nickName,a.open_id openId
|
|
|
from sys_user a left join sys_user b on a.superior_id=b.user_id
|
|
|
- where a.nick_name = #{nikeName}
|
|
|
+ where a.del_flag=0
|
|
|
+ a.nick_name = #{nikeName}
|
|
|
<if test="companyId !=null and companyId != 0">
|
|
|
AND (a.dept_id = #{companyId} OR a.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE find_in_set(#{companyId}, ancestors) ))
|
|
|
</if>
|