private void PopulateDoctors(MRSSAppContext context) { Doctors.Add(new KeyValuePair<string, string>("", string.Empty)); var doctors = context.Doctors.ToList(); foreach (var doctor in doctors) { Doctors.Add(new KeyValuePair<string, string>(doctor.UserName, doctor.FirstName + " " + doctor.LastName)); } }
public DoctorsHelper(MRSSAppContext context) { Doctors = new List<KeyValuePair<string, string>>(); PopulateDoctors(context); }