From c9352b4732459e6c94ce7054c5785dd308301de5 Mon Sep 17 00:00:00 2001 From: wangqing <408564126@qq.com> Date: Mon, 16 Sep 2024 20:25:03 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E8=AF=84=E8=AE=BA=E6=95=B0?= =?UTF-8?q?=E9=87=8F=E5=8F=98=E9=87=8F=E7=B1=BB=E5=9E=8B=E8=BD=AC=E6=8D=A2?= =?UTF-8?q?=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/luoo/comment/controller/CommentController.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/luoo_comment/src/main/java/com/luoo/comment/controller/CommentController.java b/luoo_comment/src/main/java/com/luoo/comment/controller/CommentController.java index 47ce5bd..8f1edc5 100644 --- a/luoo_comment/src/main/java/com/luoo/comment/controller/CommentController.java +++ b/luoo_comment/src/main/java/com/luoo/comment/controller/CommentController.java @@ -416,7 +416,7 @@ public class CommentController extends BaseController { List list = (List) cacheChannel.get(Constants.J2CACHE_REGION_JOURNAL_COMMENT_PAGE_CHILDREN+"_"+parentId,page+"_"+size, key->getChildrenCommentList(parentId,page,size),true).getValue(); // List list = getChildrenCommentList(parentId,page,size); //验证是否登录,并且拿到ID - Integer count = (Integer) cacheChannel.get(Constants.J2CACHE_REGION_JOURNAL_COMMENT_PAGE_CHILDREN_COUNT,parentId, key->getChildrenCommentListCount(parentId,page,size),true).getValue(); + Long count = (Long) cacheChannel.get(Constants.J2CACHE_REGION_JOURNAL_COMMENT_PAGE_CHILDREN_COUNT,parentId, key->getChildrenCommentListCount(parentId,page,size),true).getValue(); UserLoginDto userLoginDto = getUserLoginDto(authorization); if (null == userLoginDto) { @@ -425,7 +425,7 @@ public class CommentController extends BaseController { String userId = userLoginDto.getUserId(); Set publicationLikeSet = publicationLikeDao.findAllByUserId(userId).parallelStream().map(p->p.getLikedItemId()).collect(Collectors.toSet()); list = list.parallelStream().map(c->updateHaveThumbup(c,publicationLikeSet)).collect(Collectors.toList()); - return Result.success(new PageResult(Long.valueOf(count),list)); + return Result.success(new PageResult(count,list)); }