From 15ce168f45a349b8037bab04a5de78b40057f4d7 Mon Sep 17 00:00:00 2001 From: DaxPay Dev Date: Wed, 24 Jun 2026 18:48:14 +0800 Subject: [PATCH] =?UTF-8?q?fix(notify):=20=E4=BF=AE=E5=A4=8D=E9=93=83?= =?UTF-8?q?=E9=93=9B=E7=BA=A2=E7=82=B9=E4=B8=8D=E6=B6=88=E5=A4=B1(?= =?UTF-8?q?=E5=B7=B2=E5=BF=BD=E7=95=A5=E5=85=AC=E5=91=8A=E8=AF=AF=E8=AE=A1?= =?UTF-8?q?=E4=B8=BA=E6=9C=AA=E8=AF=BB)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit unreadCount 的已读集合改用 findAllByUser(含已忽略), 与 list() 已读判定对齐, 避免已忽略公告被反复计为未读导致红点常亮 --- .../notify/service/notice/NotifyUserNoticeService.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/daxpay-platform/daxpay-platform-service/service-notify/src/main/java/cn/daxpay/open/platform/notify/service/notice/NotifyUserNoticeService.java b/daxpay-platform/daxpay-platform-service/service-notify/src/main/java/cn/daxpay/open/platform/notify/service/notice/NotifyUserNoticeService.java index 16a2ff2c0..fb0a4537b 100644 --- a/daxpay-platform/daxpay-platform-service/service-notify/src/main/java/cn/daxpay/open/platform/notify/service/notice/NotifyUserNoticeService.java +++ b/daxpay-platform/daxpay-platform-service/service-notify/src/main/java/cn/daxpay/open/platform/notify/service/notice/NotifyUserNoticeService.java @@ -47,8 +47,8 @@ public class NotifyUserNoticeService { Long userId = SecurityUtil.getUserId(); // 可见公告 List visibleNotices = findVisibleNotices(); - // 用户已读(且未忽略)的公告id集合 - Set readNoticeIds = readManager.findAllByUserAndNotIgnored(userId).stream() + // 用户已读的公告id集合(含被忽略的, 忽略视同已读, 与 list() 判定一致, 避免已忽略公告被反复计为未读) + Set readNoticeIds = readManager.findAllByUser(userId).stream() .map(NotifyNoticeRead::getNoticeId) .collect(Collectors.toSet()); int noticeUnread = (int) visibleNotices.stream()