|
|
@@ -7,7 +7,7 @@
|
|
|
<sql id="Base_Column_List">
|
|
|
t.staff_id
|
|
|
, t.staff_code, t.staff_name,t.staff_phone, t.org_id, t.role_ids, t.wx_user_id, t.remarks,
|
|
|
- t.flg_valid,t.flg_can_login,
|
|
|
+ t.flg_valid,t.flg_can_login,t.hr_status,
|
|
|
t.cp_id, t.op_create_time, t.op_create_user_id, t.op_update_time, t.op_update_user_id
|
|
|
</sql>
|
|
|
|
|
|
@@ -19,6 +19,7 @@
|
|
|
<result column="staff_phone" property="staffPhone"/>
|
|
|
<result column="org_id" property="orgId" typeHandler="UuidTypeHandler"/>
|
|
|
<result column="org_name" property="orgName"/>
|
|
|
+ <result column="role_names" property="roleNames"/>
|
|
|
<result column="role_ids" property="roleIds" typeHandler="UuidListTypeHandler"/>
|
|
|
<result column="wx_user_id" property="wxUserId" typeHandler="UuidTypeHandler"/>
|
|
|
<result column="remarks" property="remarks"/>
|
|
|
@@ -32,6 +33,7 @@
|
|
|
<result column="op_timestamp" property="opTimestamp" typeHandler="TimestampTypeHandler"/>
|
|
|
<result column="op_db_user" property="opDbUser"/>
|
|
|
<result column="flg_can_login" property="flgCanLogin"/>
|
|
|
+ <result column="hr_status" property="hrStatus"/>
|
|
|
</resultMap>
|
|
|
|
|
|
<!-- 通用条件列 -->
|
|
|
@@ -62,7 +64,9 @@
|
|
|
<if test="cpId != null">
|
|
|
AND t.cp_id = #{cpId}
|
|
|
</if>
|
|
|
-
|
|
|
+ <if test="hrStatus != null">
|
|
|
+ AND t.hr_status = #{hrStatus}
|
|
|
+ </if>
|
|
|
<if test="roleIds != null and roleIds.size()>0">
|
|
|
AND t.role_ids =
|
|
|
any(#{roleIds, typeHandler=StringListTypeHandler})
|
|
|
@@ -74,29 +78,12 @@
|
|
|
</where>
|
|
|
</sql>
|
|
|
|
|
|
- <!-- 根据主键修改 -->
|
|
|
-<!-- <update id="update">-->
|
|
|
-<!-- update dkic_b.t_mst_staff-->
|
|
|
-<!-- <set>-->
|
|
|
-<!-- <if test="staffCode != null">staff_code = #{staffCode},</if>-->
|
|
|
-<!-- <if test="staffName != null" >staff_name = #{staffName},</if>-->
|
|
|
-<!-- <if test="staffPhone != null">staff_phone = #{staffPhone},</if>-->
|
|
|
-<!-- <if test="orgId != null">org_id = #{orgId},</if>-->
|
|
|
-<!-- <if test="roleIds != null">role_ids = #{roleIds},</if>-->
|
|
|
-<!-- <if test="remarks != null">remarks = #{remarks},</if>-->
|
|
|
-<!-- <if test="flgCanLogin != null">flg_can_login = #{flgCanLogin},</if>-->
|
|
|
-<!-- <if test="updateUserId != null">update_user_id = #{updateUserId},</if>-->
|
|
|
-<!-- <if test="updateUserName != null">update_user_name = #{updateUserName},</if>-->
|
|
|
-<!-- <if test="updateTime != null">update_time = #{updateTime},</if>-->
|
|
|
-<!-- </set>-->
|
|
|
-<!-- where staff_id = #{staffId}::uuid-->
|
|
|
-<!-- </update>-->
|
|
|
-
|
|
|
<!-- 查询表t_mst_staff,(条件查询+分页)列表 -->
|
|
|
<select id="selectByCond" resultMap="BaseResultMap">
|
|
|
SELECT
|
|
|
<include refid="Base_Column_List"/>
|
|
|
, org.org_name
|
|
|
+
|
|
|
FROM dkic_b.t_mst_staff t
|
|
|
LEFT JOIN dkic_b.t_mst_org org
|
|
|
ON t.org_Id = org.org_Id
|
|
|
@@ -126,9 +113,6 @@
|
|
|
WHERE t.staff_id = #{staffId}::uuid
|
|
|
</select>
|
|
|
|
|
|
-
|
|
|
-
|
|
|
-
|
|
|
<insert id="insertBatch">
|
|
|
insert into dkic_b.t_mst_staff
|
|
|
(
|