fix: お知らせの未読通知が消えない不具合を修正

This commit is contained in:
Nafu Satsuki 2023-10-28 22:34:13 +09:00 committed by riku6460
parent f85b80f376
commit 9fb3966b53
No known key found for this signature in database
GPG Key ID: 27414FA27DB94CF6

View File

@ -51,7 +51,6 @@ export class AnnouncementService {
'read."announcementId" = announcement.id AND read."userId" = :userId',
{ userId: user.id },
);
q.andWhere('read.id IS NULL');
q
.where('announcement.isActive = true')
@ -62,7 +61,8 @@ export class AnnouncementService {
.andWhere(new Brackets(qb => {
qb.orWhere('announcement.forExistingUsers = false');
qb.orWhere('announcement.id > :userId', { userId: user.id });
}));
}))
.andWhere('read.id IS NULL');
q.orderBy({
'announcement."displayOrder"': 'DESC',