How to define roles per group RRS feed

  • Question

  • User341232629 posted

    With the new release of identity 2 I am wondering if there is inbuilt support for defining roles on a group basis AND user basis.

    Clearly you can define many roles per user using .HasMany() with EF6 but is there a way to define different roles based on a group the user is allocated to? Whereby the users can be in many groups.

    user1 is a member of groups A,B,C
    and has Permissions:
    groupA: see, no edit
    groupB: basic admin rights
    groupC: full admin rights

    can I map users to groups and roles in this way? I need to be able to do the following:
    See list of groups
    See users in each group
    See list of users
    See list of groups each user is part of
    Which are do-able but also:

    See user rank in each list of users (e.g. lists for users in a group and list of groups a user is a member of)

    Many thanks for any guidence 


    Further consideration has led to me to the idea of defining roles named via "groupName_RoleType"
    However I still have the issue of getting a list of admins for a specific group without searching every role of every user.

    Wednesday, April 30, 2014 6:58 AM

All replies