I have a script I'm stuck on - I have a domain object that has a set of objects associated with it. Something like that:
public class Person
{
public string Name { get; set; }
public IList<PhoneNumber> PhoneNumbers {get; set; }
public IList<Address> Addresses { get; set; }
}
The user interface that the client requires has one input form for adding and editing. The user can enter 0 for many phones / addresses for each person. How do I handle sending a collection of values back to the controller?
I can come up with a couple of approaches, but they all seem brute force and not very elegant. Is there a best practice to solve this problem?
Jason source
share