UpdateUserGroupStatus(string userGroupId, UserGroupStatus newStatus) { return RestEndpointFactory.Create<IUserGroupsEndpoint>(SessionManager .Instance.CurrentLoggedUser) .UpdateUserGroup(userGroupId, new UserGroup { Status = newStatus }) .ToObservable() .SubscribeOn(TaskPoolScheduler.Default) .InterpretingErrors(); }
protected void raise_UserGroupStatus(ulong value0, ulong value1, [MarshalAs(UnmanagedType.U1)] bool value2, [MarshalAs(UnmanagedType.U1)] bool value3) { // TODO [vicent] current stub implementation // UserGroupStatus userGroupStatus = this.<backing_store>UserGroupStatus; UserGroupStatus userGroupStatus = this.UserGroupStatus; if (userGroupStatus != null) { userGroupStatus(value0, value1, value2, value3); } }
private string GetOption(UserGroupStatus id, int vid, string name, UserGroupStatus sel) { var res = "<option value=\"" + vid + "\""; if (id != sel) { return(res + ">" + name + "</option>"); } else { return(res + " selected>" + name + "</option>"); } }
public AccessCode ChangeUserRole(int groupId, int userId, UserGroupStatus status, UserDTO userDTO) { using (var Data = DataFactory.Get()) { var check = CheckRule(userDTO, groupId, GroupRule.CanControlUsers, Data); if (check.Code == AccessCode.Succsess) { var userGroup = check.Group.Users.FirstOrDefault(x => x.UserId == userId); if (userGroup == null) { return(AccessCode.NotFound); } else { userGroup.Status = status; } Data.UserGroupRepository.Edited(userGroup); Data.SaveChanges(); } return(check.Code); } }