The Zurich release has arrived! Interested in new features and functionalities? Click here for more

a user is manager of any group he should be able to edit group member list.

sowp
Mega Contributor

I have been assigned to a task. The task is as follows: If a user is manager of any group he should be able to edit group member list. I am not getting the task Please let me know any approach.

2 REPLIES 2

M Iftikhar
Mega Sage

Hello @sowp,

What this task means is: you want to allow a user who is set as the manager of a group (on the  sys_user_group record) to be able to edit that group’s members (sys_user_grmember), while preventing others from doing so.

You can approach it like this:

  1. Set the group manager

    • On the group record (sys_user_group), populate the Manager field with the user who should control membership.

  2. Use ACLs for control

    • Create/modify ACLs on the sys_user_grmember table.

    • Add a condition or script that checks whether the current user is the manager of the related group.

So in practice:

  • If Abraham Lincoln is the Manager of a group, then only he can add/remove members from that group’s membership list via the edit buttons.

    MIftikhar_0-1758124970965.png

     

This way, you don’t need to give broad roles like user_admin to everyone, but only the designated manager.

 

Thanks & Regards,  
Muhammad Iftikhar  

If my response helped, please mark it as the accepted solution so others can benefit as well

SunilKumar_P
Giga Sage

@sowp - You can hide the Edit / New button using the List Control on the Group Members related list.

SunilKumar_P_0-1758127508672.png

 

SunilKumar_P_2-1758127605720.png

var answer;
if (parent.manager == gs.getUserID()) {
    answer = false;
} else {
    answer = true;
}
answer;