public void SetAsAdmin() { User adminUser = userLogic.GetUserByEmail("*****@*****.**"); var obj = teamLogic.VerifyUserInvited("*****@*****.**", adminUser.UserId); teamLogic.SetAsAdmin(obj.Id, obj.InviteeUserId, true); }
public HttpResponseMessage UpdateAdminAccess(TeamMember mem) { Initialize(); logic.SetAsAdmin(mem.Id, mem.InviteeUserId, mem.IsAdmin); if (string.IsNullOrEmpty(logic.ErrorMessage)) { return(Request.CreateResponse(HttpStatusCode.OK, "success")); } else { return(Request.CreateErrorResponse(HttpStatusCode.ExpectationFailed, logic.ErrorMessage)); } }