|
@@ -1,7 +1,7 @@
|
|
|
<?xml version="1.0" encoding="UTF-8" ?>
|
|
|
<!DOCTYPE mapper
|
|
|
- PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
- "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
<mapper namespace="com.fs.qw.mapper.QwUserMapper">
|
|
|
|
|
|
<resultMap type="QwUser" id="QwUserResult">
|
|
@@ -27,15 +27,10 @@
|
|
|
<result property="toolStatus" column="tool_status" />
|
|
|
<result property="loginCodeUrl" column="login_code_url" />
|
|
|
<result property="version" column="version" />
|
|
|
- <result property="vid" column="vid" />
|
|
|
- <result property="uid" column="uid" />
|
|
|
- <result property="ipadStatus" column="ipad_status" />
|
|
|
- <result property="serverId" column="server_id" />
|
|
|
- <result property="serverStatus" column="server_status" />
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectQwUserVo">
|
|
|
- select id, qw_user_id,server_id,server_status,ipad_status,config_id,vid,uid,contact_way,app_key, qw_user_name, department, openid, company_id, company_user_id, corp_id, status, is_del, welcome_text, welcome_image, is_send_msg,app_key,qw_hook_id,fastGpt_role_id,login_status,tool_status,login_code_url,version from qw_user
|
|
|
+ select id, qw_user_id,config_id,contact_way,app_key, qw_user_name, department, openid, company_id, company_user_id, corp_id, status, is_del, welcome_text, welcome_image, is_send_msg,app_key,qw_hook_id,fastGpt_role_id,login_status,tool_status,login_code_url,version from qw_user
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectQwUserList" parameterType="QwUser" resultMap="QwUserResult">
|
|
@@ -80,15 +75,6 @@
|
|
|
</foreach>
|
|
|
</select>
|
|
|
|
|
|
- <select id="batchSelectQwUserByQwUserIdAndCorpId" resultType="QwUser">
|
|
|
- SELECT qw_user_id, corp_id, qw_user_name
|
|
|
- FROM qw_user
|
|
|
- WHERE
|
|
|
- <foreach collection="data" item="query" open="(" separator=" OR " close=")">
|
|
|
- (qw_user_id = #{query.qwUserId} AND corp_id = #{query.corpId})
|
|
|
- </foreach>
|
|
|
- </select>
|
|
|
-
|
|
|
<insert id="insertQwUser" parameterType="QwUser" useGeneratedKeys="true" keyProperty="id">
|
|
|
insert into qw_user
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
@@ -113,12 +99,7 @@
|
|
|
<if test="toolStatus != null">tool_status,</if>
|
|
|
<if test="loginCodeUrl != null">login_code_url,</if>
|
|
|
<if test="version != null">version,</if>
|
|
|
- <if test="vid != null">vid,</if>
|
|
|
- <if test="uid != null">uid,</if>
|
|
|
- <if test="ipadStatus != null">ipad_status,</if>
|
|
|
- <if test="serverId != null">server_id,</if>
|
|
|
- <if test="serverStatus != null">server_status,</if>
|
|
|
- </trim>
|
|
|
+ </trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="qwUserId != null">#{qwUserId},</if>
|
|
|
<if test="qwUserName != null">#{qwUserName},</if>
|
|
@@ -140,12 +121,7 @@
|
|
|
<if test="loginStatus != null">#{loginStatus},</if>
|
|
|
<if test="toolStatus != null">#{tool_status},</if>
|
|
|
<if test="version != null">#{version},</if>
|
|
|
- <if test="vid != null">#{vid},</if>
|
|
|
- <if test="uid != null">#{uid},</if>
|
|
|
- <if test="ipadStatus != null">#{ipadStatus},</if>
|
|
|
- <if test="serverId != null">#{serverId},</if>
|
|
|
- <if test="serverStatus != null">#{serverStatus},</if>
|
|
|
- </trim>
|
|
|
+ </trim>
|
|
|
</insert>
|
|
|
|
|
|
<update id="updateQwUser" parameterType="QwUser">
|
|
@@ -172,11 +148,6 @@
|
|
|
<if test="toolStatus != null">tool_status = #{toolStatus},</if>
|
|
|
<if test="loginCodeUrl != null">login_code_url = #{loginCodeUrl},</if>
|
|
|
<if test="version != null">version = #{version},</if>
|
|
|
- <if test="vid != null">`vid` = #{vid},</if>
|
|
|
- <if test="uid != null">uid = #{uid},</if>
|
|
|
- <if test="ipadStatus != null">ipad_status = #{ipadStatus},</if>
|
|
|
- <if test="serverId != null">server_id = #{serverId},</if>
|
|
|
- <if test="serverStatus != null">server_status = #{serverStatus},</if>
|
|
|
</trim>
|
|
|
where id = #{id}
|
|
|
</update>
|
|
@@ -223,26 +194,4 @@
|
|
|
#{userId}
|
|
|
</foreach>
|
|
|
</select>
|
|
|
-
|
|
|
- <!-- 查询企微用户列表 -->
|
|
|
- <select id="selectQwUserListByMap" resultType="com.fs.company.vo.OptionVO">
|
|
|
- select
|
|
|
- qu.qw_user_name as label,
|
|
|
- qu.id as value
|
|
|
- from qw_user qu
|
|
|
- <where>
|
|
|
- <if test="params.qwUserName != null and params.qwUserName != ''">
|
|
|
- and qu.qw_user_name like concat(#{params.qwUserName}, '%')
|
|
|
- </if>
|
|
|
- </where>
|
|
|
- </select>
|
|
|
- <select id="selectQwWorkTaskList" resultType="com.fs.qw.domain.QwWorkTask">
|
|
|
- select
|
|
|
- qwt.id,qwt.ext_id, qwt.qw_user_id, qwt.status, qwt.track_type, qwt.type, qwt.title, qwt.remark, qwt.score, qwt.sop_id,
|
|
|
- qwt.company_id, qwt.company_user_id, qwt.duration, qwt.create_time, qwt.update_time
|
|
|
- from qw_work_task qwt
|
|
|
- where qwt.qw_user_id = #{userId}
|
|
|
- and date(qwt.create_time) = #{date}
|
|
|
- and qwt.status = 0
|
|
|
- </select>
|
|
|
</mapper>
|