Allow to edit email verified and initials at Admin Panel/People/People.

Thanks to xet7 !

Fixes #1426
This commit is contained in:
Lauri Ojansivu 2020-12-29 15:33:14 +02:00
parent d0cdc33c19
commit d03e2170dd
4 changed files with 68 additions and 12 deletions

View file

@ -836,6 +836,34 @@ if (Meteor.isServer) {
}
}
},
setEmailVerified(email, verified, userId) {
if (Meteor.user() && Meteor.user().isAdmin) {
check(email, String);
check(verified, Boolean);
check(userId, String);
Users.update(userId, {
$set: {
emails: [
{
address: email,
verified,
},
],
},
});
}
},
setInitials(initials, userId) {
if (Meteor.user() && Meteor.user().isAdmin) {
check(initials, String);
check(userId, String);
Users.update(userId, {
$set: {
'profile.initials': initials,
},
});
}
},
// we accept userId, username, email
inviteUserToBoard(username, boardId) {
check(username, String);