[英]How to give a permission to only some users with same role in drupal?
If I have 3 users of same role (program manager) and now I have to give some permissions(add/edit/delete) to only 1 user in it. 如果我有3个具有相同角色的用户(程序管理员),现在我必须给其中的1个用户一些权限(添加/编辑/删除)。 Can I do this instead of assigning to a particular role so that every user containing the role gets the permissions?
我可以这样做,而不是分配给特定角色,以便每个包含该角色的用户都获得权限吗?
Just add a role containing ONLY the special permissions and then assign that new role AND the program manager role to the person(s) you want (users can have more then 1 role in Drupal). 只需添加一个仅包含特殊权限的角色,然后将该新角色和程序管理员角色分配给您想要的人即可(用户在Drupal中可以拥有多个角色)。 You don't need any 3rd party lib for that functionality.
您不需要该功能的任何第三方库。
The point of roles is to allocate permissions to blocks or types of users. 角色的重点是将权限分配给用户块或类型。 These roles do not necessarily have to correspond to an individual's role within an organization.
这些角色不一定必须与组织中的个人角色相对应。 For example, you could make the one with special permissions an Editing Program Manager, which would be a new role you create with all of the same permissions, plus those extras that the specific user needs.
例如,您可以将具有特殊权限的用户设置为Editing Program Manager,这将是您创建的具有所有相同权限以及特定用户需要的其他功能的新角色。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.