From bc8b0b8f9f043ddb2f082904cda95b14b1f00ed0 Mon Sep 17 00:00:00 2001 From: FatttSnake Date: Fri, 26 Apr 2024 16:45:16 +0800 Subject: [PATCH] Refactor(Entity): Add implement Serializable Add implement Serializable to entity --- src/main/kotlin/top/fatweb/oxygen/api/entity/tool/Tool.kt | 3 ++- src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolBase.kt | 3 ++- .../kotlin/top/fatweb/oxygen/api/entity/tool/ToolCategory.kt | 3 ++- src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolData.kt | 3 ++- .../kotlin/top/fatweb/oxygen/api/entity/tool/ToolTemplate.kt | 3 ++- 5 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/Tool.kt b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/Tool.kt index 6788c81..848c2be 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/Tool.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/Tool.kt @@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.annotation.* import com.baomidou.mybatisplus.extension.handlers.JacksonTypeHandler import com.fasterxml.jackson.annotation.JsonValue import top.fatweb.oxygen.api.entity.permission.User +import java.io.Serializable import java.time.LocalDateTime /** @@ -13,7 +14,7 @@ import java.time.LocalDateTime * @since 1.0.0 */ @TableName("t_b_tool_main", autoResultMap = true) -class Tool { +class Tool : Serializable { /** * Tool review type enum * diff --git a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolBase.kt b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolBase.kt index 9de0aa0..94765cf 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolBase.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolBase.kt @@ -2,6 +2,7 @@ package top.fatweb.oxygen.api.entity.tool import com.baomidou.mybatisplus.annotation.* import com.fasterxml.jackson.annotation.JsonValue +import java.io.Serializable import java.time.LocalDateTime /** @@ -11,7 +12,7 @@ import java.time.LocalDateTime * @since 1.0.0 */ @TableName("t_b_tool_base") -class ToolBase { +class ToolBase : Serializable { /** * Platform enum * diff --git a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolCategory.kt b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolCategory.kt index f111e1d..37246b1 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolCategory.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolCategory.kt @@ -1,6 +1,7 @@ package top.fatweb.oxygen.api.entity.tool import com.baomidou.mybatisplus.annotation.* +import java.io.Serializable import java.time.LocalDateTime /** @@ -10,7 +11,7 @@ import java.time.LocalDateTime * @since 1.0.0 */ @TableName("t_b_tool_category") -class ToolCategory { +class ToolCategory : Serializable { /** * ID * diff --git a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolData.kt b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolData.kt index d576b23..dd1f0dd 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolData.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolData.kt @@ -1,6 +1,7 @@ package top.fatweb.oxygen.api.entity.tool import com.baomidou.mybatisplus.annotation.* +import java.io.Serializable import java.time.LocalDateTime /** @@ -10,7 +11,7 @@ import java.time.LocalDateTime * @since 1.0.0 */ @TableName("t_b_tool_data") -class ToolData { +class ToolData : Serializable { /** * ID * diff --git a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolTemplate.kt b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolTemplate.kt index 09e8bde..d82358b 100644 --- a/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolTemplate.kt +++ b/src/main/kotlin/top/fatweb/oxygen/api/entity/tool/ToolTemplate.kt @@ -1,6 +1,7 @@ package top.fatweb.oxygen.api.entity.tool import com.baomidou.mybatisplus.annotation.* +import java.io.Serializable import java.time.LocalDateTime /** @@ -10,7 +11,7 @@ import java.time.LocalDateTime * @since 1.0.0 */ @TableName("t_b_tool_template") -class ToolTemplate { +class ToolTemplate : Serializable { /** * ID *