mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-09 15:40:18 +00:00
Can now directly change user permissions in a device group.
This commit is contained in:
parent
32cc09e813
commit
1e1df4b874
6 changed files with 208 additions and 94 deletions
|
@ -1687,7 +1687,7 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use
|
|||
if (newuser != null) {
|
||||
// Add mesh to user
|
||||
if (newuser.links == null) newuser.links = {};
|
||||
newuser.links[command.meshid] = { rights: command.meshadmin };
|
||||
if (newuser.links[command.meshid]) { newuser.links[command.meshid].rights = command.meshadmin; } else { newuser.links[command.meshid] = { rights: command.meshadmin }; }
|
||||
db.SetUser(newuser);
|
||||
parent.parent.DispatchEvent([newuser._id], obj, 'resubscribe');
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue