|
|
@ -135,7 +135,7 @@ |
|
|
<if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 --> |
|
|
<if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 --> |
|
|
AND date_format(u.create_time,'%y%m%d') <= date_format(#{params.endTime},'%y%m%d') |
|
|
AND date_format(u.create_time,'%y%m%d') <= date_format(#{params.endTime},'%y%m%d') |
|
|
</if> |
|
|
</if> |
|
|
<if test="deptId != null and deptId != 0"> |
|
|
<if test="deptId != null and deptId != ''"> |
|
|
AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE FIND_IN_SET |
|
|
AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE FIND_IN_SET |
|
|
(#{deptId},ancestors) )) |
|
|
(#{deptId},ancestors) )) |
|
|
</if> |
|
|
</if> |
|
|
@ -154,7 +154,7 @@ |
|
|
left join sys_dept d on u.dept_id = d.dept_id |
|
|
left join sys_dept d on u.dept_id = d.dept_id |
|
|
left join sys_tenant t on t.tenant_code = u.tenant_code |
|
|
left join sys_tenant t on t.tenant_code = u.tenant_code |
|
|
where u.del_flag = '0' |
|
|
where u.del_flag = '0' |
|
|
<if test="deptId != null and deptId != 0"> |
|
|
<if test="deptId != null and deptId != ''"> |
|
|
AND (u.dept_id = #{deptId}) |
|
|
AND (u.dept_id = #{deptId}) |
|
|
</if> |
|
|
</if> |
|
|
<!-- 租户数据过滤 --> |
|
|
<!-- 租户数据过滤 --> |
|
|
@ -189,7 +189,7 @@ |
|
|
<if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 --> |
|
|
<if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 --> |
|
|
AND u.create_time <= to_date(#{params.endTime},'yyyy-MM-dd HH24:mi:ss') |
|
|
AND u.create_time <= to_date(#{params.endTime},'yyyy-MM-dd HH24:mi:ss') |
|
|
</if> |
|
|
</if> |
|
|
<if test="deptId != null and deptId != 0"> |
|
|
<if test="deptId != null and deptId != ''"> |
|
|
AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE FIND_IN_SET |
|
|
AND (u.dept_id = #{deptId} OR u.dept_id IN ( SELECT t.dept_id FROM sys_dept t WHERE FIND_IN_SET |
|
|
(#{deptId},ancestors) <![CDATA[ <> ]]> 0 )) |
|
|
(#{deptId},ancestors) <![CDATA[ <> ]]> 0 )) |
|
|
</if> |
|
|
</if> |
|
|
@ -318,7 +318,7 @@ |
|
|
<update id="updateUser" parameterType="User"> |
|
|
<update id="updateUser" parameterType="User"> |
|
|
update sys_user |
|
|
update sys_user |
|
|
<set> |
|
|
<set> |
|
|
<if test="deptId != null and deptId != 0">dept_id = #{deptId},</if> |
|
|
<if test="deptId != null and deptId != ''">dept_id = #{deptId},</if> |
|
|
<if test="loginName != null and loginName != ''">login_name = #{loginName},</if> |
|
|
<if test="loginName != null and loginName != ''">login_name = #{loginName},</if> |
|
|
<if test="userName != null and userName != ''">user_name = #{userName},</if> |
|
|
<if test="userName != null and userName != ''">user_name = #{userName},</if> |
|
|
<if test="lawCertificateNum != null and lawCertificateNum != ''">law_certificate_num = #{lawCertificateNum},</if> |
|
|
<if test="lawCertificateNum != null and lawCertificateNum != ''">law_certificate_num = #{lawCertificateNum},</if> |
|
|
@ -365,7 +365,7 @@ |
|
|
|
|
|
|
|
|
<set> |
|
|
<set> |
|
|
|
|
|
|
|
|
<if test="deptId != null and deptId != 0">dept_id = #{deptId},</if> |
|
|
<if test="deptId != null and deptId != ''">dept_id = #{deptId},</if> |
|
|
<if test="loginName != null and loginName != ''">login_name = #{loginName},</if> |
|
|
<if test="loginName != null and loginName != ''">login_name = #{loginName},</if> |
|
|
<if test="userName != null and userName != ''">user_name = #{userName},</if> |
|
|
<if test="userName != null and userName != ''">user_name = #{userName},</if> |
|
|
<if test="email != null and email != ''">email = #{email},</if> |
|
|
<if test="email != null and email != ''">email = #{email},</if> |
|
|
@ -391,7 +391,7 @@ |
|
|
<insert id="insertUser" parameterType="User" useGeneratedKeys="true" keyProperty="userId"> |
|
|
<insert id="insertUser" parameterType="User" useGeneratedKeys="true" keyProperty="userId"> |
|
|
insert into sys_user( |
|
|
insert into sys_user( |
|
|
<if test="userId != null and userId != 0">user_id,</if> |
|
|
<if test="userId != null and userId != 0">user_id,</if> |
|
|
<if test="deptId != null and deptId != 0">dept_id,</if> |
|
|
<if test="deptId != null and deptId != ''">dept_id,</if> |
|
|
<if test="loginName != null and loginName != ''">login_name,</if> |
|
|
<if test="loginName != null and loginName != ''">login_name,</if> |
|
|
<if test="userName != null and userName != ''">user_name,</if> |
|
|
<if test="userName != null and userName != ''">user_name,</if> |
|
|
<if test="email != null and email != ''">email,</if> |
|
|
<if test="email != null and email != ''">email,</if> |
|
|
|