- Timestamp:
- 12/07/17 14:41:47 (7 years ago)
- Location:
- branches/HiveProjectManagement/HeuristicLab.Services.Access/3.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HiveProjectManagement/HeuristicLab.Services.Access/3.3/Interfaces/IUserManager.cs
r14185 r15500 31 31 MembershipUser GetUserById(Guid userId); 32 32 string GetUserNameById(Guid userId); 33 IEnumerable<Guid> GetUserGroupIdsOfUser(Guid userId); 33 34 bool VerifyUser(Guid userId, List<Guid> allowedUserGroups); 34 35 } -
branches/HiveProjectManagement/HeuristicLab.Services.Access/3.3/UserManager.cs
r14185 r15500 54 54 } 55 55 56 public IEnumerable<Guid> GetUserGroupIdsOfUser(Guid userId) { 57 using (DA.AccessServiceDataContext context = new DA.AccessServiceDataContext()) { 58 var groupIds = from g in context.UserGroupUserGroups 59 where g.UserGroupId == userId 60 select g.UserGroupUserGroupId; 61 62 var query = from g in context.UserGroupBases.OfType<DA.UserGroup>() 63 where groupIds.Contains(g.Id) 64 select g.Id; 65 66 return query.ToList(); 67 } 68 } 69 56 70 public bool VerifyUser(Guid userId, List<Guid> allowedUserGroups) { 57 71 List<DA.UserGroupUserGroup> userGroupBases;
Note: See TracChangeset
for help on using the changeset viewer.