This is kind of a simple application but I'm a bit new to ASP.NET MVC so I'm having a bit of trouble wrapping my head around how to accomplish this because the
What I have are two classes:
public class BugAssignment
{
public int BugAssignmentID { get; set; }
public int BugNumber { get; set; }
public int UserID { get; set; }
public virtual User User { get; set; }
}
public class BugAssignmentList
{
public int BugAssignmentListID { get; set; }
public string Name { get; set; }
public List<BugAssignment> BugAssignments { get; set; }
}
What I want do is populate the List of BugAssignments given user inputted delimited string of BugNumbers from (i.e. 208,576,403). I'm guessing it would explode the string, loop through and create the BugAssignment objects, store into a list and set the BugAssignments property. How could I accomplish this?
Also, I am using Entity Framework Code-first with SQL server 2008 as my database engine.