I'm running into a few problems with CRUD Update (Edit) scenarios where an entity relationship is altered via drop down list of possible entities, using ASP.NET MVC and NHibernate. Probably I am just doing something stupid, so I was wondering if someone could give me a quick example of how this should be done, as I haven't been able to find many examples on the web. (There's nothing like this in NerdDinner for example)
So using an arbitrarily simple model:
Public Class Person
{
int Id { get; set;}
string Name { get; set}
Person Buddy { get; set}
}
Could you give me an example (or link to an example) of the 'Update' Crud view and action(s) in this scenario?
- Don't worry about repository code
- For the sake of comparison with some existing code, it would be helpful if the example used formcollection (I know this is not ideal).
Thank you!