提交 2d5e9942 作者: 沈振路

register_user_entity 表添加逻辑删除字段

上级 ec604a7b
package com.yaoyaozw.customer.entity; package com.yaoyaozw.customer.entity;
import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable; import java.io.Serializable;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.Date; import java.util.Date;
...@@ -81,6 +79,10 @@ public class RegisterUserEntity implements Serializable { ...@@ -81,6 +79,10 @@ public class RegisterUserEntity implements Serializable {
@TableField(value = "gmt_create") @TableField(value = "gmt_create")
private Date gmtCreate; private Date gmtCreate;
@TableField("is_deleted")
@TableLogic
private Integer isDeleted;
/** /**
* 延时客服序列 * 延时客服序列
*/ */
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
from register_user_entity from register_user_entity
where customer_publish=#{requestDate} and customer_sort>0 where customer_publish=#{requestDate} and customer_sort>0 and is_deleted = 0
</select> </select>
</mapper> </mapper>
...@@ -36,9 +36,9 @@ ...@@ -36,9 +36,9 @@
on rue.app_id = ai.appid on rue.app_id = ai.appid
where where
rue.is_deleted = 0
<if test="openId != null and openId != ''"> <if test="openId != null and openId != ''">
rue.open_id = #{openId} and and rue.open_id = #{openId} and
</if> </if>
timestampdiff(HOUR, rue.last_active, now()) &lt; 48 timestampdiff(HOUR, rue.last_active, now()) &lt; 48
...@@ -82,6 +82,7 @@ ...@@ -82,6 +82,7 @@
on rue.app_id = ai.appid on rue.app_id = ai.appid
where find_in_set(#{packageId}, rue.in_package) where find_in_set(#{packageId}, rue.in_package)
and rue.is_deleted = 0
</select> </select>
...@@ -97,6 +98,7 @@ ...@@ -97,6 +98,7 @@
DATEDIFF(now(),gmt_create) as dateDiff DATEDIFF(now(),gmt_create) as dateDiff
from register_user_entity from register_user_entity
where find_in_set(#{packageId}, in_package) and TIMESTAMPDIFF(HOUR,last_active,now() ) &lt; 48 where find_in_set(#{packageId}, in_package) and TIMESTAMPDIFF(HOUR,last_active,now() ) &lt; 48
and is_deleted = 0
</select> </select>
...@@ -140,6 +142,6 @@ ...@@ -140,6 +142,6 @@
select id,app_id,customer_sort,customer_publish ,first_active from register_user_entity select id,app_id,customer_sort,customer_publish ,first_active from register_user_entity
where customer_sort > 0 AND first_active is not null and customer_publish &lt; #{requestDate} where customer_sort > 0 AND first_active is not null and customer_publish &lt; #{requestDate} and is_deleted = 0
</select> </select>
</mapper> </mapper>
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论