public string GetSignup() { var myFan = new Models.FanSignup(); using (var c = new ArtistListingController()) { c.Gets(); foreach (var rec in c.Recordset) { var n = new Models.FanSignup.EFanToArtist(); PopulateDerivedFromBase(rec, n); myFan.FanToArtists.Add(n); } } using (var c = new AssociationsController()) { c.Gets(); foreach (var rec in c.Recordset) { var n = new Models.FanSignup.EFanToAssociation(); PopulateDerivedFromBase(rec, n); myFan.FanToAssociations.Add(n); } } using (var c = new RegionsController()) { c.Gets(); foreach (var rec in c.Recordset) { var n = new Models.FanSignup.EFanToRegion(); PopulateDerivedFromBase(rec, n); myFan.FanToRegions.Add(n); } } using (var c = new GenresController()) { c.Gets(); foreach (var rec in c.Recordset) { var n = new Models.FanSignup.EFanToGenre(); PopulateDerivedFromBase(rec, n); myFan.FanToGenres.Add(n); } } myFan.Fan = new Fan(); var xx = JsonConvert.SerializeObject(myFan); return(xx); }
static private void SelectAssociation() { var Associations = new AssociationsController(); var SelectedAssociationId = Associations.Select(); var Documents = new DocumentsController(); var menu = new Menu(true); menu.Insert("Edit Association", Associations.Edit); menu.Insert("Delete Association", Associations.Delete); menu.Insert("List documents", Documents.ListAll); menu.Insert("Add document", Documents.Add); menu.Insert("Edit document", Documents.Edit); menu.Insert("Delete document", Documents.Delete); menu.Insert("Select document", SelectDocument); while (menu.SelectAct()) { ; } }
static private void SelectProfile() { var Profiles = new ProfilesController(); var SelectedProfileId = Profiles.Select(); var Associations = new AssociationsController(); var Documents = new DocumentsController(); var menu = new Menu(true); menu.Insert("List Associations", Associations.ListAll); menu.Insert("Add Association", Associations.Add); menu.Insert("Select Association", SelectAssociation); menu.Insert("List documents", Documents.ListAll); menu.Insert("Add document", Documents.Add); menu.Insert("Select document", SelectDocument); while (menu.SelectAct()) { ; } }