Ejemplo n.º 1
0
 public List<PatientViewModel> GetAllPatients()
 {
     using (var patientrepo = new PatientRepository())
     {
         return patientrepo.GetAll().Select(x => new PatientViewModel() { PatientId = x.PatientId, FirstName = x.FirstName, LastName = x.LastName, IdentificationNumber = x.IdentificationNumber, Cellphone = x.Cellphone, Email = x.Email, Occupation = x.Occupation,SecurityAnswer = x.SecurityAnswer,Address = x.Address,Telephone = x.Telephone,City = x.City,State = x.State,Country = x.Country,ZipCode = x.ZipCode}).ToList();
     }
 }