添加统一的逻辑删除常量

This commit is contained in:
HuangXin 2022-07-20 08:02:49 +00:00 committed by Gitee
parent 801615f780
commit 93fc8bd074
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 23 additions and 0 deletions

View File

@ -77,5 +77,15 @@ public interface Constants {
*/
String TOKEN = "token";
/**
* 逻辑删除正常标记0正常2删除
*/
String DEL_FLAG_NORMAL = "0";
/**
* 逻辑删除删除标记0正常2删除
*/
String DEL_FLAG_DELETE = "2";
}

View File

@ -2,6 +2,7 @@ package com.ruoyi.common.core.domain;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.ruoyi.common.constant.Constants;
import lombok.Data;
import java.io.Serializable;
@ -56,4 +57,16 @@ public class BaseEntity implements Serializable {
@TableField(exist = false)
private Map<String, Object> params = new HashMap<>();
/**
* 逻辑删除正常标记0正常2删除
*/
@TableField(exist = false)
public static final String DEL_FLAG_NORMAL = Constants.DEL_FLAG_NORMAL;
/**
* 逻辑删除删除标记0正常2删除
*/
@TableField(exist = false)
public static final String DEL_FLAG_DELETE = Constants.DEL_FLAG_DELETE;
}