fix: 本地ui优先已读

This commit is contained in:
Tim
2025-08-20 20:55:22 +08:00
parent 22c9bd7d39
commit 99644046fc
3 changed files with 15 additions and 17 deletions

View File

@@ -542,7 +542,7 @@ import {
fetchNotifications,
fetchUnreadCount,
isLoadingMessage,
markRead as markNotificationRead,
markNotificationRead,
notifications,
markAllRead,
hasMore,
@@ -598,7 +598,7 @@ const togglePref = async (pref) => {
}
const markRead = async (id) => {
await markNotificationRead(id)
markNotificationRead(id)
if (selectedTab.value === 'unread') {
const index = notifications.value.findIndex((n) => n.id === id)
if (index !== -1) notifications.value.splice(index, 1)