|
@@ -34,6 +34,7 @@
|
|
|
<result property="deptName" column="dept_name"/>
|
|
<result property="deptName" column="dept_name"/>
|
|
|
<result property="tutorUserName" column="tutorUserName"/>
|
|
<result property="tutorUserName" column="tutorUserName"/>
|
|
|
<result property="cardNum" column="card_num"/>
|
|
<result property="cardNum" column="card_num"/>
|
|
|
|
|
+ <result property="cardNumSimple" column="card_num_simple"/>
|
|
|
<result property="wechatId" column="wechat_id"/>
|
|
<result property="wechatId" column="wechat_id"/>
|
|
|
<result property="education" column="education"/>
|
|
<result property="education" column="education"/>
|
|
|
<result property="nationality" column="nationality"/>
|
|
<result property="nationality" column="nationality"/>
|
|
@@ -89,7 +90,7 @@
|
|
|
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,u.user_type,
|
|
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,u.user_type,
|
|
|
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.dept_name, d.order_num, d.leader, d.status as dept_status,
|
|
|
sm.`major_name` major, u.grade, u.category, u.tutor_user_id, u.position, u.nature, u.signature,
|
|
sm.`major_name` major, u.grade, u.category, u.tutor_user_id, u.position, u.nature, u.signature,
|
|
|
- u.card_num,u.wechat_id,u.education,u.nationality,u.addr,u.work_status,u.date_birth,
|
|
|
|
|
|
|
+ u.card_num,u.card_num_simple,u.wechat_id,u.education,u.nationality,u.addr,u.work_status,u.date_birth,
|
|
|
ut.nick_name tutorUserName,u.is_check,
|
|
ut.nick_name tutorUserName,u.is_check,
|
|
|
uf.face_img,sc.class_name,u.major_id,u.signature,pt.`post_name` positionName
|
|
uf.face_img,sc.class_name,u.major_id,u.signature,pt.`post_name` positionName
|
|
|
from sys_user u
|
|
from sys_user u
|
|
@@ -322,7 +323,7 @@
|
|
|
|
|
|
|
|
<select id="selectUserByCardNum" parameterType="String" resultMap="SysUserResult">
|
|
<select id="selectUserByCardNum" parameterType="String" resultMap="SysUserResult">
|
|
|
<include refid="selectUserNewVo"/>
|
|
<include refid="selectUserNewVo"/>
|
|
|
- where u.card_num = #{cardNum} and u.del_flag = 0
|
|
|
|
|
|
|
+ where u.card_num_simple = #{cardNumSimple} and u.del_flag = 0
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
<select id="selectUserById" parameterType="Long" resultMap="SysUserResult">
|
|
<select id="selectUserById" parameterType="Long" resultMap="SysUserResult">
|
|
@@ -342,6 +343,10 @@
|
|
|
select count(1) from sys_user where card_num = #{cardNum} and del_flag=0 limit 1
|
|
select count(1) from sys_user where card_num = #{cardNum} and del_flag=0 limit 1
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
+ <select id="checkCardSimpleUnique" parameterType="com.zd.model.entity.SysUser" resultType="int">
|
|
|
|
|
+ select count(1) from sys_user where card_num_simple = #{cardNumSimple} and del_flag=0 limit 1
|
|
|
|
|
+ </select>
|
|
|
|
|
+
|
|
|
<select id="checkPhoneUnique" parameterType="String" resultMap="SysUserResult">
|
|
<select id="checkPhoneUnique" parameterType="String" resultMap="SysUserResult">
|
|
|
select user_id, phonenumber from sys_user where phonenumber = #{phonenumber} limit 1
|
|
select user_id, phonenumber from sys_user where phonenumber = #{phonenumber} limit 1
|
|
|
</select>
|
|
</select>
|
|
@@ -463,6 +468,7 @@
|
|
|
<if test="department != null and department != ''">department,</if>
|
|
<if test="department != null and department != ''">department,</if>
|
|
|
<if test="nature != null and nature != ''">nature,</if>
|
|
<if test="nature != null and nature != ''">nature,</if>
|
|
|
<if test="cardNum != null and cardNum != ''">card_num,</if>
|
|
<if test="cardNum != null and cardNum != ''">card_num,</if>
|
|
|
|
|
+ <if test="cardNumSimple != null and cardNumSimple != ''">card_num_simple,</if>
|
|
|
<if test="education != null and education != ''">education,</if>
|
|
<if test="education != null and education != ''">education,</if>
|
|
|
<if test="nationality != null and nationality != ''">nationality,</if>
|
|
<if test="nationality != null and nationality != ''">nationality,</if>
|
|
|
<if test="addr != null and addr != ''">addr,</if>
|
|
<if test="addr != null and addr != ''">addr,</if>
|
|
@@ -493,6 +499,7 @@
|
|
|
<if test="department != null and department != ''">#{department},</if>
|
|
<if test="department != null and department != ''">#{department},</if>
|
|
|
<if test="nature != null and nature != ''">#{nature},</if>
|
|
<if test="nature != null and nature != ''">#{nature},</if>
|
|
|
<if test="cardNum != null and cardNum != ''">#{cardNum},</if>
|
|
<if test="cardNum != null and cardNum != ''">#{cardNum},</if>
|
|
|
|
|
+ <if test="cardNumSimple != null and cardNumSimple != ''">#{cardNumSimple},</if>
|
|
|
<if test="education != null and education != ''">#{education},</if>
|
|
<if test="education != null and education != ''">#{education},</if>
|
|
|
<if test="nationality != null and nationality != ''">#{nationality},</if>
|
|
<if test="nationality != null and nationality != ''">#{nationality},</if>
|
|
|
<if test="addr != null and addr != ''">#{addr},</if>
|
|
<if test="addr != null and addr != ''">#{addr},</if>
|
|
@@ -528,7 +535,8 @@
|
|
|
<if test="position != null ">position = #{position},</if>
|
|
<if test="position != null ">position = #{position},</if>
|
|
|
<if test="department != null ">department = #{department},</if>
|
|
<if test="department != null ">department = #{department},</if>
|
|
|
<if test="nature != null and nature!=''">nature = #{nature},</if>
|
|
<if test="nature != null and nature!=''">nature = #{nature},</if>
|
|
|
- <if test="cardNum != null ">card_num = #{cardNum},</if>
|
|
|
|
|
|
|
+ card_num = #{cardNum},
|
|
|
|
|
+ card_num_simple = #{cardNumSimple},
|
|
|
<if test="education != null and education!=''">education = #{education},</if>
|
|
<if test="education != null and education!=''">education = #{education},</if>
|
|
|
<if test="nationality != null and nationality!=''">nationality = #{nationality},</if>
|
|
<if test="nationality != null and nationality!=''">nationality = #{nationality},</if>
|
|
|
<if test="addr != null and addr != ''">addr = #{addr},</if>
|
|
<if test="addr != null and addr != ''">addr = #{addr},</if>
|
|
@@ -568,6 +576,7 @@
|
|
|
<if test="department != null ">department = #{department},</if>
|
|
<if test="department != null ">department = #{department},</if>
|
|
|
<if test="nature != null and nature!=''">nature = #{nature},</if>
|
|
<if test="nature != null and nature!=''">nature = #{nature},</if>
|
|
|
card_num = #{cardNum},
|
|
card_num = #{cardNum},
|
|
|
|
|
+ card_num_simple = #{cardNumSimple},
|
|
|
<if test="education != null and education!=''">education = #{education},</if>
|
|
<if test="education != null and education!=''">education = #{education},</if>
|
|
|
<if test="nationality != null and nationality!=''">nationality = #{nationality},</if>
|
|
<if test="nationality != null and nationality!=''">nationality = #{nationality},</if>
|
|
|
<if test="addr != null and addr != ''">addr = #{addr},</if>
|
|
<if test="addr != null and addr != ''">addr = #{addr},</if>
|
|
@@ -606,6 +615,7 @@
|
|
|
<if test="department != null ">department = #{department},</if>
|
|
<if test="department != null ">department = #{department},</if>
|
|
|
<if test="nature != null and nature!=''">nature = #{nature},</if>
|
|
<if test="nature != null and nature!=''">nature = #{nature},</if>
|
|
|
card_num = #{cardNum},
|
|
card_num = #{cardNum},
|
|
|
|
|
+ card_num_simple = #{cardNumSimple},
|
|
|
<if test="education != null and education!=''">education = #{education},</if>
|
|
<if test="education != null and education!=''">education = #{education},</if>
|
|
|
<if test="nationality != null and nationality!=''">nationality = #{nationality},</if>
|
|
<if test="nationality != null and nationality!=''">nationality = #{nationality},</if>
|
|
|
<if test="addr != null and addr != ''">addr = #{addr},</if>
|
|
<if test="addr != null and addr != ''">addr = #{addr},</if>
|
|
@@ -795,7 +805,7 @@
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
<select id="selectUserInfoByCardNum" resultType="com.zd.model.entity.SysUser">
|
|
<select id="selectUserInfoByCardNum" resultType="com.zd.model.entity.SysUser">
|
|
|
- SELECT user_id,nick_name,card_num FROM sys_user u WHERE u.card_num = #{cardNum}
|
|
|
|
|
|
|
+ SELECT user_id,nick_name,card_num,card_num_simple FROM sys_user u WHERE u.card_num_simple = #{cardNumSimple}
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
<select id="getSafeUserList" parameterType="com.zd.model.entity.SysUser" resultMap="SysUserResult">
|
|
<select id="getSafeUserList" parameterType="com.zd.model.entity.SysUser" resultMap="SysUserResult">
|