Quellcode durchsuchen

update content-api ReplyUser

reghao vor 9 Monaten
Ursprung
Commit
6bdd1a93fa

+ 1 - 1
content/content-api/src/main/java/cn/reghao/tnb/content/api/dto/comment/ReplyUser.java

@@ -14,7 +14,7 @@ import java.io.Serializable;
 public class ReplyUser implements Serializable {
     private static final long serialVersionUID = 1L;
 
-    private Long userId;
+    private String userId;
     private String name;
     private String avatar;
     private Boolean author;

+ 2 - 1
content/content-service/src/main/java/cn/reghao/tnb/content/app/vod/service/CommentService.java

@@ -109,6 +109,7 @@ public class CommentService {
     private UserReply getCommentVo(UserComment userComment) {
         Long commentId = userComment.getCommentId();
         Long userId = userComment.getPublishBy();
+        String userIdStr = accountQuery.getUserIdStr(userId);
         String postId = userComment.getPostId();
         String content = userComment.getContent();
         Long createAt = userComment.getPublishAt();
@@ -116,7 +117,7 @@ public class CommentService {
         List<String> images = userComment.getCommentImages();
 
         ReplyUser commentUser = new ReplyUser();
-        commentUser.setUserId(userId);
+        commentUser.setUserId(userIdStr);
         UserCard userCard = userService.getUserAvatar(userId);
         if (userCard != null) {
             commentUser.setName(userCard.getScreenName());