public List <PatientPathology> getPatientPathology(bool currentOnly)
 {
     if (currentOnly)
     {
         return(database.getPatientPathology(patient).Where(pp => pp.End_Date.Equals(DateTime.Parse("12/31/9999"))).ToList());
     }
     else
     {
         return(database.getPatientPathology(patient));
     }
 }
 private void DisplayPathology()
 {
     dgvPatientProperties.Columns.Add("cName", "Name");
     patientPathology = database.getPatientPathology(patient);
     patientPathology.ForEach(pp => dgvPatientProperties.Rows.Add(pp.Pathology.Name));
     btnViewDetails.Text = "View Pathology Details";
 }
        private void loadPathology(TreeView tvMedicalData)
        {
            tvMedicalData.Nodes.Add("Pathology");
            tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].ImageIndex         = 2;
            tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].SelectedImageIndex = 2;

            List <PatientPathology> patientPathology = database.getPatientPathology(patient);

            foreach (PatientPathology pp in patientPathology)
            {
                tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].Nodes.Add(
                    pp.Pathology.Name);
                tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].LastNode.ImageIndex         = 2;
                tvMedicalData.Nodes[tvMedicalData.Nodes.Count - 1].LastNode.SelectedImageIndex = 2;
            }
        }