private void FillTelephones(IEnumerable <Telephone> telephones) { if (telephones != null) { foreach (var item in telephones) { Telephones.Add(new TelephoneViewModel(item)); } } }
public void AjouterTeleOuMail(Telephone tele, Email mail, bool?a) { // ajout Telephone if (a == true) { Telephones.Add(tele); SaveChanges(); } // ajout email else { Emails.Add(mail); SaveChanges(); } }
public Person(Telephone phone, Adress primaryAdress, string name, string famileName, string middleName, string type, Email mail = null) { PersonType = type; Email = mail; Telephones.Add(phone); AltAdresse PrimaryAdress = new AltAdresse(); PrimaryAdress.TypeOfAdress = "Primary"; PrimaryAdress.AlternativeAdress = primaryAdress; altAdresser.Add(PrimaryAdress); Type = type; GivenName = name; MiddleName = middleName; FamilyName = famileName; }
public void AjouterTelephone(Telephone tele) { Telephones.Add(tele); }