添加 @Serial 序列化注解
This commit is contained in:
@@ -16,6 +16,8 @@ import com.jeesite.modules.cms.utils.CmsUtils;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import jakarta.validation.constraints.Size;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
@@ -66,6 +68,7 @@ import java.util.Date;
|
||||
public class Article extends DataEntity<Article> {
|
||||
|
||||
public static final String DEFAULT_TEMPLATE = "viewArticle"; // 默认文章内容模板
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private Category category; // 栏目编码
|
||||
|
||||
@@ -11,6 +11,8 @@ import com.jeesite.common.entity.Extend;
|
||||
import com.jeesite.common.mybatis.annotation.Column;
|
||||
import com.jeesite.common.mybatis.annotation.Table;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 文章详情表Entity
|
||||
* @author 长春叭哥、ThinkGem
|
||||
@@ -26,6 +28,7 @@ import com.jeesite.common.mybatis.annotation.Table;
|
||||
)
|
||||
public class ArticleData extends DataEntity<ArticleData> {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String content; // 文章内容
|
||||
private String relation; // 相关文章
|
||||
|
||||
@@ -8,6 +8,8 @@ import com.jeesite.common.entity.DataEntity;
|
||||
import com.jeesite.common.mybatis.annotation.Column;
|
||||
import com.jeesite.common.mybatis.annotation.Table;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 文章推荐位Entity
|
||||
* @author 长春叭哥、ThinkGem
|
||||
@@ -20,6 +22,7 @@ import com.jeesite.common.mybatis.annotation.Table;
|
||||
)
|
||||
public class ArticlePosid extends DataEntity<ArticlePosid> {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String articleId; // 内容编号
|
||||
private String postid; // 推荐位置(1轮播图 2首页推荐 3栏目页面)
|
||||
|
||||
@@ -8,6 +8,8 @@ import com.jeesite.common.entity.DataEntity;
|
||||
import com.jeesite.common.mybatis.annotation.Column;
|
||||
import com.jeesite.common.mybatis.annotation.Table;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 文章与标签关系Entity
|
||||
* @author 长春叭哥、ThinkGem
|
||||
@@ -20,6 +22,7 @@ import com.jeesite.common.mybatis.annotation.Table;
|
||||
)
|
||||
public class ArticleTag extends DataEntity<ArticleTag> {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String articleId; // 内容编号
|
||||
private String tagName; // 标签名称
|
||||
|
||||
@@ -16,6 +16,8 @@ import com.jeesite.modules.cms.utils.CmsUtils;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.Size;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@@ -59,6 +61,7 @@ public class Category extends TreeEntity<Category> {
|
||||
public static final String SHOW_MODES_CENTENT_LIST = "2"; // 首栏目内容列表
|
||||
public static final String SHOW_MODES_FIRST_CONTENT = "3"; // 简介类栏目,栏目第一条内容
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String categoryCode; // 栏目编码
|
||||
private String categoryName; // 栏目名称
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
*/
|
||||
package com.jeesite.modules.cms.entity;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.util.Date;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
@@ -43,6 +44,7 @@ import com.jeesite.common.mybatis.mapper.query.QueryType;
|
||||
)
|
||||
public class Comment extends DataEntity<Comment> {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
private Category category;// 分类编号
|
||||
|
||||
@@ -6,6 +6,7 @@ package com.jeesite.modules.cms.entity;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.Serial;
|
||||
import java.io.Serializable;
|
||||
import java.util.Objects;
|
||||
|
||||
@@ -23,6 +24,7 @@ import com.jeesite.common.lang.ExceptionUtils;
|
||||
*/
|
||||
public class FileTemplete implements Comparable<FileTemplete>, Serializable {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private Resource resource;
|
||||
private String fileName;
|
||||
|
||||
@@ -10,6 +10,8 @@ import com.jeesite.common.entity.DataEntity;
|
||||
import com.jeesite.common.mybatis.annotation.Column;
|
||||
import com.jeesite.common.mybatis.annotation.Table;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 内容举报表Entity
|
||||
* @author 长春叭哥、ThinkGem
|
||||
@@ -26,6 +28,7 @@ import com.jeesite.common.mybatis.annotation.Table;
|
||||
)
|
||||
public class Report extends DataEntity<Report> {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String reportSource; // 举报来源(1文章、2评论)
|
||||
private String reportContent; // 举报内容(文章标题 评论内容)
|
||||
|
||||
@@ -16,6 +16,8 @@ import com.jeesite.modules.sys.utils.UserUtils;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.Size;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@@ -53,6 +55,7 @@ public class Site extends DataEntity<Site> {
|
||||
*/
|
||||
public static final String DEFAULT_TEMPLATE = "index";
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String siteCode; // 站点编码
|
||||
private String siteName; // 站点名称
|
||||
|
||||
@@ -10,6 +10,8 @@ import com.jeesite.common.entity.DataEntity;
|
||||
import com.jeesite.common.mybatis.annotation.Column;
|
||||
import com.jeesite.common.mybatis.annotation.Table;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 内容标签Entity
|
||||
* @author 长春叭哥、ThinkGem
|
||||
@@ -22,6 +24,7 @@ import com.jeesite.common.mybatis.annotation.Table;
|
||||
)
|
||||
public class Tag extends DataEntity<Tag> {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String tagName; // 标签名称
|
||||
private Integer clicknum; // 点击次数
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
*/
|
||||
package com.jeesite.modules.cms.entity;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.util.Date;
|
||||
|
||||
import jakarta.validation.constraints.Size;
|
||||
@@ -57,6 +58,7 @@ import com.jeesite.common.mybatis.mapper.query.QueryType;
|
||||
)
|
||||
public class VisitLog extends DataEntity<VisitLog> {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
private String requestUrl; // 请求的URL地址
|
||||
private String requestUrlHost; // 受访域名
|
||||
|
||||
Reference in New Issue
Block a user