update
This commit is contained in:
@@ -52,7 +52,7 @@
|
||||
is_leader_in_depts, department, jobnumber, monitored_departments, departments, user_region_ids
|
||||
</sql>
|
||||
<insert id="insertSelective" keyColumn="id" keyProperty="record.id" useGeneratedKeys="true">
|
||||
insert into enterprise_user_${enterpriseId}
|
||||
insert into enterprise_user
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="record.userId != null">
|
||||
user_id,
|
||||
@@ -275,7 +275,7 @@
|
||||
</trim>
|
||||
</insert>
|
||||
<update id="updateByPrimaryKeySelective">
|
||||
update enterprise_user_${enterpriseId}
|
||||
update enterprise_user
|
||||
<set>
|
||||
<if test="record.userId != null">
|
||||
user_id = #{record.userId},
|
||||
@@ -394,14 +394,14 @@
|
||||
<include refid="Base_Column_List"/>,
|
||||
<include refid="Blob_Column_List"/>
|
||||
from
|
||||
enterprise_user_${enterpriseId}
|
||||
enterprise_user
|
||||
where
|
||||
user_id = #{userId}
|
||||
</select>
|
||||
|
||||
|
||||
<insert id="batchInsertOrUpdate" parameterType="java.util.List">
|
||||
insert into enterprise_user_${eid} (
|
||||
insert into enterprise_user (
|
||||
id,
|
||||
user_id,
|
||||
`name`,
|
||||
@@ -469,7 +469,7 @@
|
||||
</insert>
|
||||
|
||||
<update id="batchUpdateDiffUserDiffRegionIds">
|
||||
update enterprise_user_${eid}
|
||||
update enterprise_user
|
||||
set user_region_ids =
|
||||
<foreach collection="list" item="item" index="index" separator=" " open="case user_id" close="end">
|
||||
when #{item.userId} then #{item.userRegionIds}
|
||||
@@ -493,9 +493,9 @@
|
||||
u.avatar as avatar,
|
||||
u.user_status as userStatus,
|
||||
u.unionid as unionid
|
||||
from enterprise_user_${eid} u
|
||||
left join enterprise_user_role_${eid} ul on u.user_id=ul.user_id
|
||||
left join sys_role_${eid} r on ul.role_id=r.id
|
||||
from enterprise_user u
|
||||
left join enterprise_user_role ul on u.user_id=ul.user_id
|
||||
left join sys_role r on ul.role_id=r.id
|
||||
<where>
|
||||
u.active = true and u.user_id != 'a100000001'
|
||||
<if test="deptId !=null and deptId !=''">
|
||||
@@ -544,7 +544,7 @@
|
||||
departments as departments,
|
||||
user_status as userStatus,
|
||||
unionid
|
||||
from enterprise_user_${eid}
|
||||
from enterprise_user
|
||||
<where>
|
||||
active = true and user_id != 'a100000001'
|
||||
<if test="deptId !=null and deptId !=''">
|
||||
@@ -588,7 +588,7 @@
|
||||
`language`,
|
||||
user_status as userStatus,
|
||||
subordinate_range as subordinateRange
|
||||
from enterprise_user_${eid}
|
||||
from enterprise_user
|
||||
<where>
|
||||
user_id != 'a100000001'
|
||||
and
|
||||
@@ -615,8 +615,8 @@
|
||||
u.departments as departments,
|
||||
u.user_status as userStatus,
|
||||
u.unionid as unionid
|
||||
from enterprise_user_${eid} u
|
||||
left join enterprise_user_group_mapping_${eid} ug on u.user_id=ug.user_id
|
||||
from enterprise_user u
|
||||
left join enterprise_user_group_mapping ug on u.user_id=ug.user_id
|
||||
<where>
|
||||
ug.group_id = #{groupId} and u.active = true and u.user_id != 'a100000001'
|
||||
<if test="userName !=null and userName !=''">
|
||||
@@ -663,7 +663,7 @@
|
||||
face_url as faceUrl,
|
||||
create_time as createTime,
|
||||
`language` as language
|
||||
from enterprise_user_${eid} where user_id != 'a100000001'
|
||||
from enterprise_user where user_id != 'a100000001'
|
||||
<foreach collection="regionIdList" item="regionId" separator=" or " open="and (" close=" )">
|
||||
user_region_ids like concat('%/', #{regionId}, '/%')
|
||||
</foreach>
|
||||
@@ -671,7 +671,7 @@
|
||||
</select>
|
||||
|
||||
<update id="updateEnterpriseUser">
|
||||
update enterprise_user_${eid}
|
||||
update enterprise_user
|
||||
<set>
|
||||
<if test="enterpriseUserDO.name != null and enterpriseUserDO.name !=''">`name` = #{enterpriseUserDO.name},</if>
|
||||
<if test="enterpriseUserDO.tel != null and enterpriseUserDO.tel !=''">`tel` = #{enterpriseUserDO.tel},</if>
|
||||
@@ -760,20 +760,20 @@
|
||||
</update>
|
||||
|
||||
<select id="getMainAdminUserIds" resultType="string">
|
||||
select user_id from enterprise_user_${eid} where main_admin = true and active = true
|
||||
select user_id from enterprise_user where main_admin = true and active = true
|
||||
</select>
|
||||
|
||||
<select id="selectSpecifyNodeUserIds" resultType="string">
|
||||
select
|
||||
user_id
|
||||
from
|
||||
enterprise_user_${eid}
|
||||
enterprise_user
|
||||
where
|
||||
departments like concat('%/',#{dingDeptId},'/%')
|
||||
</select>
|
||||
|
||||
<select id="selectAllUserIds" resultType="java.lang.String">
|
||||
select user_id as userId from enterprise_user_${eid}
|
||||
select user_id as userId from enterprise_user
|
||||
</select>
|
||||
|
||||
<select id="selectByUserIdIgnoreActive" resultType="com.cool.store.entity.EnterpriseUserDO">
|
||||
@@ -810,11 +810,11 @@
|
||||
third_oa_unique_flag as thirdOaUniqueFlag,
|
||||
subordinate_change as subordinateChange,
|
||||
subordinate_range as subordinateRange
|
||||
from enterprise_user_${enterpriseId} where user_id = #{userId, jdbcType=VARCHAR}
|
||||
from enterprise_user where user_id = #{userId, jdbcType=VARCHAR}
|
||||
</select>
|
||||
|
||||
<insert id="insertEnterpriseUser">
|
||||
insert into enterprise_user_${eid}
|
||||
insert into enterprise_user
|
||||
( `id`,
|
||||
`user_id`,
|
||||
`name`,
|
||||
|
||||
Reference in New Issue
Block a user