|
|
@@ -26,4 +26,280 @@
|
|
|
#{item.createType} )
|
|
|
</foreach>
|
|
|
</insert>
|
|
|
+
|
|
|
+ <select id="getAvatarAdvertiserIds">
|
|
|
+ select advertiser_id
|
|
|
+ from deepthink.advertiser_avatar
|
|
|
+ where avatar_status = 'IN_AUDIT'
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <update id="updateAdvertiserAvatar" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserAvatar">
|
|
|
+ update deepthink.advertiser_avatar
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="avatarStatus != null">avatar_status = #{avatarStatus},</if>
|
|
|
+ <if test="avatarReason != null">avatar_reason = #{avatarReason},</if>
|
|
|
+ <if test="sourceStatus != null">source_status = #{sourceStatus},</if>
|
|
|
+ <if test="sourceInfo != null">source_info = #{sourceInfo},</if>
|
|
|
+ <if test="sourceReason != null">source_reason = #{sourceReason},</if>
|
|
|
+ <if test="webUri != null">web_uri = #{webUri},</if>
|
|
|
+ <if test="auditWebUri != null">audit_web_uri = #{auditWebUri},</if>
|
|
|
+ <if test="height != null">height = #{height},</if>
|
|
|
+ <if test="width != null">width = #{width},</if>
|
|
|
+ <if test="webUrl != null">web_url = #{webUrl},</if>
|
|
|
+ <if test="auditWebUrl != null">audit_web_url = #{auditWebUrl},</if>
|
|
|
+ <if test="createTime != null">create_time = #{createTime},</if>
|
|
|
+ <if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
+ </trim>
|
|
|
+ where advertiser_id = #{advertiserId}
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <insert id="insertAdvertiserAvatar" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserAvatar">
|
|
|
+ insert into deepthink.advertiser_avatar
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="advertiserId != null">advertiser_id,</if>
|
|
|
+ <if test="avatarStatus != null">avatar_status,</if>
|
|
|
+ <if test="avatarReason != null">avatar_reason,</if>
|
|
|
+ <if test="sourceStatus != null">source_status,</if>
|
|
|
+ <if test="sourceInfo != null">source_info,</if>
|
|
|
+ <if test="sourceReason != null">source_reason,</if>
|
|
|
+ <if test="webUri != null">web_uri,</if>
|
|
|
+ <if test="auditWebUri != null">audit_web_uri,</if>
|
|
|
+ <if test="height != null">height,</if>
|
|
|
+ <if test="width != null">width,</if>
|
|
|
+ <if test="webUrl != null">web_url,</if>
|
|
|
+ <if test="auditWebUrl != null">audit_web_url,</if>
|
|
|
+ <if test="ossUrl != null">oss_url,</if>
|
|
|
+ <if test="reason != null">reason,</if>
|
|
|
+ <if test="parameters != null">parameters,</if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="advertiserId != null">#{advertiserId},</if>
|
|
|
+ <if test="avatarStatus != null">#{avatarStatus},</if>
|
|
|
+ <if test="avatarReason != null">#{avatarReason},</if>
|
|
|
+ <if test="sourceStatus != null">#{sourceStatus},</if>
|
|
|
+ <if test="sourceInfo != null">#{sourceInfo},</if>
|
|
|
+ <if test="sourceReason != null">#{sourceReason},</if>
|
|
|
+ <if test="webUri != null">#{webUri},</if>
|
|
|
+ <if test="auditWebUri != null">#{auditWebUri},</if>
|
|
|
+ <if test="height != null">#{height},</if>
|
|
|
+ <if test="width != null">#{width},</if>
|
|
|
+ <if test="webUrl != null">#{webUrl},</if>
|
|
|
+ <if test="auditWebUrl != null">#{auditWebUrl},</if>
|
|
|
+ <if test="ossUrl != null">#{ossUrl},</if>
|
|
|
+ <if test="reason != null">#{reason},</if>
|
|
|
+ <if test="parameters != null">#{parameters},</if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <select id="getNameAdvertiserIds">
|
|
|
+ select advertiser_id
|
|
|
+ from deepthink.advertiser_name_info
|
|
|
+ where advertiser_status = 'STATUS_PENDING_CONFIRM'
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <insert id="insertAdvertiserNameInfo" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserNameInfo">
|
|
|
+ insert into deepthink.advertiser_name_info
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="advertiserId != null">advertiser_id,</if>
|
|
|
+ <if test="advertiserName != null">advertiser_name,</if>
|
|
|
+ <if test="advertiserStatus != null">advertiser_status,</if>
|
|
|
+ <if test="reason != null">reason,</if>
|
|
|
+ <if test="parameters != null">parameters,</if>
|
|
|
+ <if test="createTime != null">create_time,</if>
|
|
|
+ <if test="updateTime != null">update_time,</if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="advertiserId != null">#{advertiserId},</if>
|
|
|
+ <if test="advertiserName != null">#{advertiserName},</if>
|
|
|
+ <if test="advertiserStatus != null">#{advertiserStatus},</if>
|
|
|
+ <if test="reason != null">#{reason},</if>
|
|
|
+ <if test="parameters != null">#{parameters},</if>
|
|
|
+ <if test="createTime != null">#{createTime},</if>
|
|
|
+ <if test="updateTime != null">#{updateTime},</if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <update id="updateAdvertiserNameInfo" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserNameInfo">
|
|
|
+ update deepthink.advertiser_name_info
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="advertiserName != null">advertiser_name = #{advertiserName},</if>
|
|
|
+ <if test="advertiserStatus != null">advertiser_status = #{advertiserStatus},</if>
|
|
|
+ <if test="reason != null">reason = #{reason},</if>
|
|
|
+ <if test="parameters != null">parameters = #{parameters},</if>
|
|
|
+ <if test="createTime != null">create_time = #{createTime},</if>
|
|
|
+ <if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
+ </trim>
|
|
|
+ where advertiser_id = #{advertiserId}
|
|
|
+ </update>
|
|
|
+
|
|
|
+
|
|
|
+ <select id="getAppAdvertiserIds">
|
|
|
+ select advertiser_id
|
|
|
+ from deepthink.advertiser_app_list
|
|
|
+ where advertiser_status = 'AUDITING'
|
|
|
+ AND plat_type = #{platType}
|
|
|
+ </select>
|
|
|
+
|
|
|
+
|
|
|
+ <insert id="insertAdvertiserAppList" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserApplet"
|
|
|
+ useGeneratedKeys="true"
|
|
|
+ keyProperty="id">
|
|
|
+ replace into deepthink.advertiser_app_list
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="advertiserId != null">advertiser_id,</if>
|
|
|
+ <if test="appName != null">app_name,</if>
|
|
|
+ <if test="remark != null">remark,</if>
|
|
|
+ <if test="instanceId != null">instance_id,</if>
|
|
|
+ <if test="appId != null">app_id,</if>
|
|
|
+ <if test="originalAppId != null">original_app_id,</if>
|
|
|
+ <if test="platType != null">plat_type,</if>
|
|
|
+ <if test="auditStatus != null">audit_status,</if>
|
|
|
+ <if test="reason != null">reason,</if>
|
|
|
+ <if test="link != null">link,</if>
|
|
|
+ <if test="linkRemark != null">link_remark,</if>
|
|
|
+ <if test="path != null">path,</if>
|
|
|
+ <if test="remarkMessage != null">remark_message,</if>
|
|
|
+ <if test="iconImageUrl != null">icon_image_url,</if>
|
|
|
+ <if test="headerImageUrl != null">header_image_url,</if>
|
|
|
+ <if test="labels != null">labels,</if>
|
|
|
+ <if test="guideText != null">guide_text,</if>
|
|
|
+ <if test="imagesVerticalUrl != null">images_vertical_url,</if>
|
|
|
+ <if test="imagesHorizontalUrl != null">images_horizontal_url,</if>
|
|
|
+ <if test="introduction != null">introduction,</if>
|
|
|
+ <if test="tagInfo != null">tag_info,</if>
|
|
|
+ <if test="startPage != null">start_page,</if>
|
|
|
+ <if test="startParam != null">start_param,</if>
|
|
|
+ <if test="appCreateTime != null">app_create_time,</if>
|
|
|
+ <if test="appUpdateTime != null">app_update_time,</if>
|
|
|
+ <if test="parameters != null">parameters,</if>
|
|
|
+ <if test="taskId != null">task_id,</if>
|
|
|
+ <if test="appShare != null">app_share,</if>
|
|
|
+ <if test="shareAdvertiserId != null">share_advertiser_id,</if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="advertiserId != null">#{advertiserId},</if>
|
|
|
+ <if test="appName != null">#{appName},</if>
|
|
|
+ <if test="remark != null">#{remark},</if>
|
|
|
+ <if test="instanceId != null">#{instanceId},</if>
|
|
|
+ <if test="appId != null">#{appId},</if>
|
|
|
+ <if test="originalAppId != null">#{originalAppId},</if>
|
|
|
+ <if test="platType != null">#{platType},</if>
|
|
|
+ <if test="auditStatus != null">#{auditStatus},</if>
|
|
|
+ <if test="reason != null">#{reason},</if>
|
|
|
+ <if test="link != null">#{link},</if>
|
|
|
+ <if test="linkRemark != null">#{linkRemark},</if>
|
|
|
+ <if test="path != null">#{path},</if>
|
|
|
+ <if test="remarkMessage != null">#{remarkMessage},</if>
|
|
|
+ <if test="iconImageUrl != null">#{iconImageUrl},</if>
|
|
|
+ <if test="headerImageUrl != null">#{headerImageUrl},</if>
|
|
|
+ <if test="labels != null">#{labels},</if>
|
|
|
+ <if test="guideText != null">#{guideText},</if>
|
|
|
+ <if test="imagesVerticalUrl != null">#{imagesVerticalUrl},</if>
|
|
|
+ <if test="imagesHorizontalUrl != null">#{imagesHorizontalUrl},</if>
|
|
|
+ <if test="introduction != null">#{introduction},</if>
|
|
|
+ <if test="tagInfo != null">#{tagInfo},</if>
|
|
|
+ <if test="startPage != null">#{startPage},</if>
|
|
|
+ <if test="startParam != null">#{startParam},</if>
|
|
|
+ <if test="appCreateTime != null">#{appCreateTime},</if>
|
|
|
+ <if test="appUpdateTime != null">#{appUpdateTime},</if>
|
|
|
+ <if test="parameters != null">#{parameters},</if>
|
|
|
+ <if test="taskId != null">#{taskId},</if>
|
|
|
+ <if test="appShare != null">#{appShare},</if>
|
|
|
+ <if test="shareAdvertiserId != null">#{shareAdvertiserId},</if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <update id="updateAdvertiserAppList" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserApplet">
|
|
|
+ update deepthink.advertiser_app_list
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="advertiserId != null">advertiser_id = #{advertiserId},</if>
|
|
|
+ <if test="appName != null">app_name = #{appName},</if>
|
|
|
+ <if test="remark != null">remark = #{remark},</if>
|
|
|
+ <if test="instanceId != null">instance_id = #{instanceId},</if>
|
|
|
+ <if test="appId != null">app_id = #{appId},</if>
|
|
|
+ <if test="originalAppId != null">original_app_id = #{originalAppId},</if>
|
|
|
+ <if test="platType != null">plat_type = #{platType},</if>
|
|
|
+ <if test="auditStatus != null">audit_status = #{auditStatus},</if>
|
|
|
+ <if test="reason != null">reason = #{reason},</if>
|
|
|
+ <if test="link != null">link = #{link},</if>
|
|
|
+ <if test="linkRemark != null">link_remark = #{linkRemark},</if>
|
|
|
+ <if test="path != null">path = #{path},</if>
|
|
|
+ <if test="remarkMessage != null">remark_message = #{remarkMessage},</if>
|
|
|
+ <if test="iconImageUrl != null">icon_image_url = #{iconImageUrl},</if>
|
|
|
+ <if test="headerImageUrl != null">header_image_url = #{headerImageUrl},</if>
|
|
|
+ <if test="labels != null">labels = #{labels},</if>
|
|
|
+ <if test="guideText != null">guide_text = #{guideText},</if>
|
|
|
+ <if test="imagesVerticalUrl != null">images_vertical_url = #{imagesVerticalUrl},</if>
|
|
|
+ <if test="imagesHorizontalUrl != null">images_horizontal_url = #{imagesHorizontalUrl},</if>
|
|
|
+ <if test="introduction != null">introduction = #{introduction},</if>
|
|
|
+ <if test="tagInfo != null">tag_info = #{tagInfo},</if>
|
|
|
+ <if test="startPage != null">start_page = #{startPage},</if>
|
|
|
+ <if test="startParam != null">start_param = #{startParam},</if>
|
|
|
+ <if test="appCreateTime != null">app_create_time = #{appCreateTime},</if>
|
|
|
+ <if test="appUpdateTime != null">app_update_time = #{appUpdateTime},</if>
|
|
|
+ <if test="taskId != null">task_id = #{taskId},</if>
|
|
|
+ <if test="appShare != null">app_share = #{appShare},</if>
|
|
|
+ <if test="shareAdvertiserId != null">share_advertiser_id = #{shareAdvertiserId},</if>
|
|
|
+ </trim>
|
|
|
+ WHERE advertiser_id = #{advertiserId}
|
|
|
+ AND instance_id = #{instanceId}
|
|
|
+ AND plat_type = #{platType}
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <select id="getsiteAdvertiserIds">
|
|
|
+ select advertiser_id
|
|
|
+ from deepthink.advertiser_tools_site
|
|
|
+ where advertiser_status = 'EDIT'
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <update id="updateAdvertiserToolsSite" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserToolsSite">
|
|
|
+ update deepthink.advertiser_tools_site
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="name != null">name = #{name},</if>
|
|
|
+ <if test="thumbnail != null">thumbnail = #{thumbnail},</if>
|
|
|
+ <if test="status != null">status = #{status},</if>
|
|
|
+ <if test="siteType != null">site_type = #{siteType},</if>
|
|
|
+ <if test="functionType != null">function_type = #{functionType},</if>
|
|
|
+ <if test="createType != null">create_type = #{createType},</if>
|
|
|
+ <if test="parameters != null">parameters = #{parameters},</if>
|
|
|
+ <if test="taskId != null">task_id = #{taskId},</if>
|
|
|
+ </trim>
|
|
|
+ where site_id = #{siteId}
|
|
|
+ AND advertiser_id = #{advertiserId}
|
|
|
+ </update>
|
|
|
+
|
|
|
+
|
|
|
+ <insert id="insertAdvertiserToolsSite" parameterType="cn.com.ctop.job.bytedance.data.entity.AdvertiserToolsSite">
|
|
|
+ replace into deepthink.advertiser_tools_site
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="siteId != null">site_id,</if>
|
|
|
+ <if test="advertiserId != null">advertiser_id,</if>
|
|
|
+ <if test="name != null">name,</if>
|
|
|
+ <if test="thumbnail != null">thumbnail,</if>
|
|
|
+ <if test="status != null">status,</if>
|
|
|
+ <if test="reason != null">reason,</if>
|
|
|
+ <if test="siteType != null">site_type,</if>
|
|
|
+ <if test="functionType != null">function_type,</if>
|
|
|
+ <if test="createType != null">create_type,</if>
|
|
|
+ <if test="createTime != null">create_time,</if>
|
|
|
+ <if test="updateTime != null">update_time,</if>
|
|
|
+ <if test="parameters != null">parameters,</if>
|
|
|
+ <if test="taskId != null">task_id,</if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="siteId != null">#{siteId},</if>
|
|
|
+ <if test="advertiserId != null">#{advertiserId},</if>
|
|
|
+ <if test="name != null">#{name},</if>
|
|
|
+ <if test="thumbnail != null">#{thumbnail},</if>
|
|
|
+ <if test="status != null">#{status},</if>
|
|
|
+ <if test="reason != null">#{reason},</if>
|
|
|
+ <if test="siteType != null">#{siteType},</if>
|
|
|
+ <if test="functionType != null">#{functionType},</if>
|
|
|
+ <if test="createType != null">#{createType},</if>
|
|
|
+ <if test="createTime != null">#{createTime},</if>
|
|
|
+ <if test="updateTime != null">#{updateTime},</if>
|
|
|
+ <if test="parameters != null">#{parameters},</if>
|
|
|
+ <if test="taskId != null">#{taskId},</if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
</mapper>
|