|
|
@ -4,50 +4,51 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" |
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
|
|
|
<mapper namespace="com.ruoyi.system.mapper.SysUserMapper"> |
|
|
|
<mapper namespace="com.ruoyi.system.mapper.SysUserMapper"> |
|
|
|
|
|
|
|
|
|
|
|
<resultMap type="SysUser" id="SysUserResult"> |
|
|
|
<resultMap type="SysUser" id="SysUserResult"> |
|
|
|
<id property="userId" column="user_id" /> |
|
|
|
<id property="userId" column="user_id" /> |
|
|
|
<result property="deptId" column="dept_id" /> |
|
|
|
<result property="deptId" column="dept_id" /> |
|
|
|
<result property="userName" column="user_name" /> |
|
|
|
<result property="userName" column="user_name" /> |
|
|
|
<result property="nickName" column="nick_name" /> |
|
|
|
<result property="nickName" column="nick_name" /> |
|
|
|
<result property="email" column="email" /> |
|
|
|
<result property="email" column="email" /> |
|
|
|
<result property="phonenumber" column="phonenumber" /> |
|
|
|
<result property="phonenumber" column="phonenumber" /> |
|
|
|
<result property="sex" column="sex" /> |
|
|
|
<result property="sex" column="sex" /> |
|
|
|
<result property="avatar" column="avatar" /> |
|
|
|
<result property="avatar" column="avatar" /> |
|
|
|
<result property="password" column="password" /> |
|
|
|
<result property="password" column="password" /> |
|
|
|
<result property="status" column="status" /> |
|
|
|
<result property="status" column="status" /> |
|
|
|
<result property="delFlag" column="del_flag" /> |
|
|
|
<result property="delFlag" column="del_flag" /> |
|
|
|
<result property="loginIp" column="login_ip" /> |
|
|
|
<result property="loginIp" column="login_ip" /> |
|
|
|
<result property="loginDate" column="login_date" /> |
|
|
|
<result property="loginDate" column="login_date" /> |
|
|
|
<result property="createBy" column="create_by" /> |
|
|
|
<result property="createBy" column="create_by" /> |
|
|
|
<result property="createTime" column="create_time" /> |
|
|
|
<result property="createTime" column="create_time" /> |
|
|
|
<result property="updateBy" column="update_by" /> |
|
|
|
<result property="updateBy" column="update_by" /> |
|
|
|
<result property="updateTime" column="update_time" /> |
|
|
|
<result property="updateTime" column="update_time" /> |
|
|
|
<result property="remark" column="remark" /> |
|
|
|
<result property="remark" column="remark" /> |
|
|
|
<association property="dept" column="dept_id" javaType="SysDept" resultMap="deptResult" /> |
|
|
|
<association property="dept" column="dept_id" javaType="SysDept" resultMap="deptResult" /> |
|
|
|
<collection property="roles" javaType="java.util.List" resultMap="RoleResult" /> |
|
|
|
<collection property="roles" javaType="java.util.List" resultMap="RoleResult" /> |
|
|
|
</resultMap> |
|
|
|
</resultMap> |
|
|
|
|
|
|
|
|
|
|
|
<resultMap id="deptResult" type="SysDept"> |
|
|
|
<resultMap id="deptResult" type="SysDept"> |
|
|
|
<id property="deptId" column="dept_id" /> |
|
|
|
<id property="deptId" column="dept_id" /> |
|
|
|
<result property="parentId" column="parent_id" /> |
|
|
|
<result property="parentId" column="parent_id" /> |
|
|
|
<result property="deptName" column="dept_name" /> |
|
|
|
<result property="deptName" column="dept_name" /> |
|
|
|
<result property="orderNum" column="order_num" /> |
|
|
|
<result property="ancestors" column="ancestors" /> |
|
|
|
<result property="leader" column="leader" /> |
|
|
|
<result property="orderNum" column="order_num" /> |
|
|
|
<result property="status" column="dept_status" /> |
|
|
|
<result property="leader" column="leader" /> |
|
|
|
</resultMap> |
|
|
|
<result property="status" column="dept_status" /> |
|
|
|
|
|
|
|
</resultMap> |
|
|
|
<resultMap id="RoleResult" type="SysRole"> |
|
|
|
|
|
|
|
<id property="roleId" column="role_id" /> |
|
|
|
<resultMap id="RoleResult" type="SysRole"> |
|
|
|
<result property="roleName" column="role_name" /> |
|
|
|
<id property="roleId" column="role_id" /> |
|
|
|
<result property="roleKey" column="role_key" /> |
|
|
|
<result property="roleName" column="role_name" /> |
|
|
|
<result property="roleSort" column="role_sort" /> |
|
|
|
<result property="roleKey" column="role_key" /> |
|
|
|
<result property="dataScope" column="data_scope" /> |
|
|
|
<result property="roleSort" column="role_sort" /> |
|
|
|
<result property="status" column="role_status" /> |
|
|
|
<result property="dataScope" column="data_scope" /> |
|
|
|
</resultMap> |
|
|
|
<result property="status" column="role_status" /> |
|
|
|
|
|
|
|
</resultMap> |
|
|
|
|
|
|
|
|
|
|
|
<sql id="selectUserVo"> |
|
|
|
<sql id="selectUserVo"> |
|
|
|
select u.user_id, u.dept_id, u.user_name, u.nick_name, u.email, u.avatar, u.phonenumber, u.password, u.sex, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark, |
|
|
|
select u.user_id, u.dept_id, u.user_name, u.nick_name, u.email, u.avatar, u.phonenumber, u.password, u.sex, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.remark, |
|
|
|
d.dept_id, d.parent_id, d.dept_name, d.order_num, d.leader, d.status as dept_status, |
|
|
|
d.dept_id, d.parent_id, d.ancestors, d.dept_name, d.order_num, d.leader, d.status as dept_status, |
|
|
|
r.role_id, r.role_name, r.role_key, r.role_sort, r.data_scope, r.status as role_status |
|
|
|
r.role_id, r.role_name, r.role_key, r.role_sort, r.data_scope, r.status as role_status |
|
|
|
from sys_user u |
|
|
|
from sys_user u |
|
|
|
left join sys_dept d on u.dept_id = d.dept_id |
|
|
|
left join sys_dept d on u.dept_id = d.dept_id |
|
|
|