From 78f60238c1cd0e35f34fff1bae5612114d711a2d Mon Sep 17 00:00:00 2001 From: whz <303054730@qq.com> Date: Fri, 31 May 2024 11:04:06 +0800 Subject: [PATCH] fix --- src/main/java/com/lk/paopao/controller/SiteController.java | 2 +- src/main/java/com/lk/paopao/mapper/PostContentMapper.java | 1 + src/main/java/com/lk/paopao/mapper/PostMapper.java | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/lk/paopao/controller/SiteController.java b/src/main/java/com/lk/paopao/controller/SiteController.java index e5f8348..d4c3bca 100644 --- a/src/main/java/com/lk/paopao/controller/SiteController.java +++ b/src/main/java/com/lk/paopao/controller/SiteController.java @@ -27,7 +27,7 @@ public class SiteController { "tweet_web_ellipsis_size", 400, "tweet_mobile_ellipsis_size", 300, "default_tweet_visibility", "friend", - "default_msg_loop_interval", 5000, + "default_msg_loop_interval", 50000, "copyright_top", "2023 paopao.info", "copyright_left", "Roc's Me", "copyright_left_link", "", diff --git a/src/main/java/com/lk/paopao/mapper/PostContentMapper.java b/src/main/java/com/lk/paopao/mapper/PostContentMapper.java index 87ddaca..fcd18b8 100644 --- a/src/main/java/com/lk/paopao/mapper/PostContentMapper.java +++ b/src/main/java/com/lk/paopao/mapper/PostContentMapper.java @@ -8,6 +8,7 @@ import org.mapstruct.*; public interface PostContentMapper { PostContent toEntity(PostContentDto postContentDto); + @Mapping(source = "post.id", target = "postId") PostContentDto toDto(PostContent postContent); @BeanMapping(nullValuePropertyMappingStrategy = NullValuePropertyMappingStrategy.IGNORE) diff --git a/src/main/java/com/lk/paopao/mapper/PostMapper.java b/src/main/java/com/lk/paopao/mapper/PostMapper.java index 5baa9b3..ba3b29b 100644 --- a/src/main/java/com/lk/paopao/mapper/PostMapper.java +++ b/src/main/java/com/lk/paopao/mapper/PostMapper.java @@ -8,6 +8,7 @@ import org.mapstruct.*; public interface PostMapper { Post toEntity(PostDto postDto); + @Mapping(source = "user.id", target = "userId") PostDto toDto(Post post); @BeanMapping(nullValuePropertyMappingStrategy = NullValuePropertyMappingStrategy.IGNORE)