/// <summary> /// Create a new member entity with a name, short name, and default role /// </summary> /// <param name="name">The full name of the user.</param> /// <param name="shortName">An alias or nickname used throughout the VersionOne user interface.</param> /// <param name="defaultRole">The new user's default role on projects.</param> /// <param name="attributes">Required attributes.</param> /// <returns>A newly minted Member that exists in the VersionOne system.</returns> public Member Member(string name, string shortName, Role defaultRole, IDictionary<string, object> attributes) { var member = new Member(instance) { Name = name, ShortName = shortName, DefaultRole = defaultRole }; AddAttributes(member, attributes); member.Save(); return member; }
/// <summary> /// Create a new member entity with a name, short name, and default role /// </summary> /// <param name="name">The full name of the user.</param> /// <param name="shortName">An alias or nickname used throughout the VersionOne user interface.</param> /// <param name="defaultRole">The new user's default role on projects.</param> /// <returns>A newly minted Member that exists in the VersionOne system.</returns> public Member Member(string name, string shortName, Role defaultRole) { return Member(name, shortName, defaultRole, null); }