add a notification drawer like trello

This commit is contained in:
Jonathan Baird 2020-03-27 11:35:03 -06:00
parent 29d62440a5
commit 9819c9f801
20 changed files with 701 additions and 257 deletions

View file

@ -219,6 +219,9 @@ if (Meteor.isServer) {
type: 'card',
activityType: 'addAttachment',
attachmentId: doc._id,
// this preserves the name so that notifications can be meaningful after
// this file is removed
attachmentName: doc.original.name,
boardId: doc.boardId,
cardId: doc.cardId,
listId: doc.listId,
@ -246,18 +249,15 @@ if (Meteor.isServer) {
type: 'card',
activityType: 'deleteAttachment',
attachmentId: doc._id,
// this preserves the name so that notifications can be meaningful after
// this file is removed
attachmentName: doc.original.name,
boardId: doc.boardId,
cardId: doc.cardId,
listId: doc.listId,
swimlaneId: doc.swimlaneId,
});
});
Attachments.files.after.remove((userId, doc) => {
Activities.remove({
attachmentId: doc._id,
});
});
}
export default Attachments;