|
|
@@ -25,8 +25,9 @@ export interface InAppNotificationDocument extends Document {
|
|
|
|
|
|
export interface InAppNotificationModel extends Model<InAppNotificationDocument> {
|
|
|
findLatestInAppNotificationsByUser(user: Types.ObjectId, skip: number, offset: number): Promise<InAppNotificationDocument[]>
|
|
|
-
|
|
|
+ getUnreadCountByUser(user: Types.ObjectId): Promise<number | undefined>
|
|
|
open(user, id: Types.ObjectId): Promise<InAppNotificationDocument | null>
|
|
|
+ read(user) /* : Promise<Query<any>> */
|
|
|
|
|
|
STATUS_UNREAD: string
|
|
|
STATUS_UNOPENED: string
|