|
@@ -30,6 +30,29 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<association property="tenant" column="tenant_id" javaType="SysTenant" resultMap="tenantResult" />
|
|
<association property="tenant" column="tenant_id" javaType="SysTenant" resultMap="tenantResult" />
|
|
<collection property="roles" javaType="java.util.List" resultMap="RoleResult" />
|
|
<collection property="roles" javaType="java.util.List" resultMap="RoleResult" />
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
+
|
|
|
|
+ <resultMap type="SysUser" id="SysUserInfoResult">
|
|
|
|
+ <id property="userId" column="user_id" />
|
|
|
|
+ <result property="deptId" column="dept_id" />
|
|
|
|
+ <result property="tenantId" column="tenant_id" />
|
|
|
|
+ <result property="userName" column="user_name" />
|
|
|
|
+ <result property="nickName" column="nick_name" />
|
|
|
|
+ <result property="userType" column="user_type" />
|
|
|
|
+ <result property="email" column="email" />
|
|
|
|
+ <result property="phonenumber" column="phonenumber" />
|
|
|
|
+ <result property="sex" column="sex" />
|
|
|
|
+ <result property="avatar" column="avatar" />
|
|
|
|
+ <result property="password" column="password" />
|
|
|
|
+ <result property="status" column="status" />
|
|
|
|
+ <result property="delFlag" column="del_flag" />
|
|
|
|
+ <result property="loginIp" column="login_ip" />
|
|
|
|
+ <result property="loginDate" column="login_date" />
|
|
|
|
+ <result property="createBy" column="create_by" />
|
|
|
|
+ <result property="createTime" column="create_time" />
|
|
|
|
+ <result property="updateBy" column="update_by" />
|
|
|
|
+ <result property="updateTime" column="update_time" />
|
|
|
|
+ <result property="remark" column="remark" />
|
|
|
|
+ </resultMap>
|
|
|
|
|
|
<resultMap id="deptResult" type="SysDept">
|
|
<resultMap id="deptResult" type="SysDept">
|
|
<id property="deptId" column="dept_id" />
|
|
<id property="deptId" column="dept_id" />
|
|
@@ -167,6 +190,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="phonenumber != null and phonenumber != ''">
|
|
<if test="phonenumber != null and phonenumber != ''">
|
|
AND u.phonenumber like concat('%', #{phonenumber}, '%')
|
|
AND u.phonenumber like concat('%', #{phonenumber}, '%')
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="tenantId != null">
|
|
|
|
+ AND u.tenant_Id = #{tenantId}
|
|
|
|
+ </if>
|
|
<!-- 数据范围过滤 -->
|
|
<!-- 数据范围过滤 -->
|
|
${params.dataScope}
|
|
${params.dataScope}
|
|
</select>
|
|
</select>
|
|
@@ -199,6 +225,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="deptId != null and deptId != 0">dept_id,</if>
|
|
<if test="deptId != null and deptId != 0">dept_id,</if>
|
|
<if test="userName != null and userName != ''">user_name,</if>
|
|
<if test="userName != null and userName != ''">user_name,</if>
|
|
<if test="nickName != null and nickName != ''">nick_name,</if>
|
|
<if test="nickName != null and nickName != ''">nick_name,</if>
|
|
|
|
+ <if test="userType != null and userType != ''">user_type,</if>
|
|
<if test="email != null and email != ''">email,</if>
|
|
<if test="email != null and email != ''">email,</if>
|
|
<if test="avatar != null and avatar != ''">avatar,</if>
|
|
<if test="avatar != null and avatar != ''">avatar,</if>
|
|
<if test="phonenumber != null and phonenumber != ''">phonenumber,</if>
|
|
<if test="phonenumber != null and phonenumber != ''">phonenumber,</if>
|
|
@@ -214,6 +241,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="deptId != null and deptId != ''">#{deptId},</if>
|
|
<if test="deptId != null and deptId != ''">#{deptId},</if>
|
|
<if test="userName != null and userName != ''">#{userName},</if>
|
|
<if test="userName != null and userName != ''">#{userName},</if>
|
|
<if test="nickName != null and nickName != ''">#{nickName},</if>
|
|
<if test="nickName != null and nickName != ''">#{nickName},</if>
|
|
|
|
+ <if test="userType != null and userType != ''">#{userType},</if>
|
|
<if test="email != null and email != ''">#{email},</if>
|
|
<if test="email != null and email != ''">#{email},</if>
|
|
<if test="avatar != null and avatar != ''">#{avatar},</if>
|
|
<if test="avatar != null and avatar != ''">#{avatar},</if>
|
|
<if test="phonenumber != null and phonenumber != ''">#{phonenumber},</if>
|
|
<if test="phonenumber != null and phonenumber != ''">#{phonenumber},</if>
|
|
@@ -270,5 +298,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
#{userId}
|
|
#{userId}
|
|
</foreach>
|
|
</foreach>
|
|
</delete>
|
|
</delete>
|
|
|
|
+
|
|
|
|
+ <select id="selectAllUser" resultMap="SysUserInfoResult">
|
|
|
|
+ select * from sys_user where del_flag = '0'
|
|
|
|
+ </select>
|
|
|
|
|
|
</mapper>
|
|
</mapper>
|