public async Task <bool> AccessAdmin(string userId, string groupId) { var accessToken = Session["MicrosoftAccessToken"] as string; RoleTypeService roleTypeService = new RoleTypeService(accessToken); return(await roleTypeService.CanUserAddOrDeleteItem(userId, groupId)); }
public async Task <bool> AccessAdmin(string groupId) { var accessToken = Session["MicrosoftAccessToken"] as string; UserService userService = new UserService(accessToken); string userId = await userService.GetUserInternalId(Session["UserId"] as string, UserDomainEnum.Microsoft); RoleTypeService roleTypeService = new RoleTypeService(accessToken); return(await roleTypeService.CanUserAddOrDeleteItem(userId, groupId)); }