From e4ce074e88bf1102fea1c62897fccb1c56434afd Mon Sep 17 00:00:00 2001 From: Ziin Date: Mon, 30 Jun 2025 19:13:55 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9=E4=B8=BB=E6=92=AD=E5=85=A5?= =?UTF-8?q?=E5=BA=93=E6=97=B6=E9=97=B4=E7=B1=BB=E5=9E=8B=E4=B8=BA=20LocalD?= =?UTF-8?q?ateTime?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 4 ++-- .../java/com/yupi/springbootinit/model/entity/NewHosts.java | 3 ++- .../yupi/springbootinit/service/impl/HostInfoServiceImpl.java | 2 +- src/main/resources/application-dev.yml | 2 +- src/main/resources/application-prod.yml | 2 +- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/pom.xml b/pom.xml index d8665bc..ae69827 100644 --- a/pom.xml +++ b/pom.xml @@ -12,8 +12,8 @@ com.yupi - springboot-init - 0.0.1-SNAPSHOT + tkDataSave + 1.0 tk-dataSave 17 diff --git a/src/main/java/com/yupi/springbootinit/model/entity/NewHosts.java b/src/main/java/com/yupi/springbootinit/model/entity/NewHosts.java index 93fb3d3..ff363fe 100644 --- a/src/main/java/com/yupi/springbootinit/model/entity/NewHosts.java +++ b/src/main/java/com/yupi/springbootinit/model/entity/NewHosts.java @@ -6,6 +6,7 @@ import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; +import java.time.LocalDateTime; import java.util.Date; /* @@ -104,7 +105,7 @@ public class NewHosts { /** * 数据插入时间 */ - private Date createTime; + private LocalDateTime createTime; diff --git a/src/main/java/com/yupi/springbootinit/service/impl/HostInfoServiceImpl.java b/src/main/java/com/yupi/springbootinit/service/impl/HostInfoServiceImpl.java index 028d121..c995c19 100644 --- a/src/main/java/com/yupi/springbootinit/service/impl/HostInfoServiceImpl.java +++ b/src/main/java/com/yupi/springbootinit/service/impl/HostInfoServiceImpl.java @@ -111,7 +111,7 @@ public class HostInfoServiceImpl extends ServiceImpl i @Override public void queryCount(QueryCountDTO queryCountDTO) { - redisTemplate.opsForValue().increment("tkaccount:" + queryCountDTO.getTkAccount(),1); + redisTemplate.opsForValue().increment( "tkaccount:" + queryCountDTO.getTkAccount(),1); } diff --git a/src/main/resources/application-dev.yml b/src/main/resources/application-dev.yml index ad65298..e190c6b 100644 --- a/src/main/resources/application-dev.yml +++ b/src/main/resources/application-dev.yml @@ -14,7 +14,7 @@ spring: # Redis 配置 # todo 需替换配置 redis: - database: 0 + database: 1 host: localhost port: 6379 timeout: 5000 diff --git a/src/main/resources/application-prod.yml b/src/main/resources/application-prod.yml index dd1eef4..9d33b56 100644 --- a/src/main/resources/application-prod.yml +++ b/src/main/resources/application-prod.yml @@ -14,7 +14,7 @@ spring: # Redis 配置 # todo 需替换配置 redis: - database: 0 + database: 1 host: localhost port: 16379 timeout: 5000