update: notification

This commit is contained in:
Mahyargdz
2025-05-21 15:35:09 +03:30
parent 8da977291b
commit b57dc5319f
19 changed files with 151 additions and 72 deletions
@@ -8,7 +8,7 @@ export class NotificationRepository extends EntityRepository<Notification> {
async getAllNotifications(queryDto: SearchNotificationQueryDto, recipientId: string) {
const { skip, limit } = PaginationUtils(queryDto);
const qb = this.qb("notification").where({ recipientId });
const qb = this.qb("notification").where({ recipient: { id: recipientId } });
if (queryDto.isRead !== undefined) {
qb.andWhere({ isRead: queryDto.isRead === 1 });