mirror of
https://github.com/wekan/wekan.git
synced 2026-01-06 17:48:49 +01:00
improve notifications
This commit is contained in:
parent
28a01862d0
commit
b925b8e74d
9 changed files with 163 additions and 59 deletions
|
|
@ -152,17 +152,6 @@ if (Meteor.isServer) {
|
|||
if (board) {
|
||||
const watchingUsers = _.pluck(_.where(board.watchers, {level: 'watching'}), 'userId');
|
||||
const trackingUsers = _.pluck(_.where(board.watchers, {level: 'tracking'}), 'userId');
|
||||
const mutedUsers = _.pluck(_.where(board.watchers, {level: 'muted'}), 'userId');
|
||||
switch(board.getWatchDefault()) {
|
||||
case 'muted':
|
||||
participants = _.intersection(participants, trackingUsers);
|
||||
watchers = _.intersection(watchers, trackingUsers);
|
||||
break;
|
||||
case 'tracking':
|
||||
participants = _.difference(participants, mutedUsers);
|
||||
watchers = _.difference(watchers, mutedUsers);
|
||||
break;
|
||||
}
|
||||
watchers = _.union(watchers, watchingUsers || []);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue