1
0
mirror of https://gitlab.com/comunic/comunicapiv2 synced 2025-06-20 00:25:17 +00:00

Can delete all the notifications of a user

This commit is contained in:
2020-03-25 08:30:19 +01:00
parent 3bf3f18710
commit 50c6d8d0c2
3 changed files with 25 additions and 0 deletions

View File

@ -255,6 +255,17 @@ export class NotificationsHelper {
}
/**
* Delete all the notifications of a given user
*
* @param userID Target user ID
*/
public static async DeleteAllUser(userID: number) {
await this.Delete(new Notif({
destUserID: userID
}));
}
/**
* Count the number of unread notifications of a user
*