Exemplo n.º 1
0
 public AgreedTermAllFormD(DBCommunication.DBCommunicationAdmin _db, int doctorID)
 {
     InitializeComponent();
     _DB         = _db;
     doctor      = doctorID;
     _patient    = _DB.GetPatient();
     _agreedTerm = _DB.AgreedTemForDoctor(doctor);
     AgreedTermGridControl.DataSource = _agreedTerm;
 }
Exemplo n.º 2
0
 public PatientForm(DBCommunication.DBCommunicationAdmin _db)
 {
     InitializeComponent();
     _DB      = _db;
     _patient = _DB.GetPatient();
     PatientGridControl.DataSource = _patient;
     _doctor = _DB.GetDoctor();
     DoctorLE.Properties.DataSource    = _doctor;
     DoctorLE.Properties.DisplayMember = "Surname";
     DoctorLE.Properties.ValueMember   = "ID";
 }
Exemplo n.º 3
0
        public PatientInfoForm(DBCommunication.DBCommunicationAdmin _db)
        {
            InitializeComponent();
            _DB          = _db;
            _patientInfo = _DB.GetPatientInfo();
            PatientInfoGridControl.DataSource = _patientInfo;

            _patient = _DB.GetPatient();
            PatientLE.Properties.DataSource    = _patient;
            PatientLE.Properties.DisplayMember = "Surname";
            PatientLE.Properties.ValueMember   = "ID";
        }
Exemplo n.º 4
0
 private void NewPatientBarItem_Click(object sender, EventArgs e)
 {
     if (!string.IsNullOrWhiteSpace(NameTE.Text) && !string.IsNullOrWhiteSpace(SurnameTE.Text) && !string.IsNullOrWhiteSpace(EmailTE.Text) && !string.IsNullOrWhiteSpace(ConactTE.Text) && DoctorLE.EditValue != null)
     {
         patient         = new Patient();
         patient.Name    = NameTE.Text;
         patient.Surname = SurnameTE.Text;
         patient.Email   = EmailTE.Text;
         patient.Contact = ConactTE.Text;
         patient.Doctor  = int.Parse(DoctorLE.EditValue.ToString());
         if (!_DB.InsertPatient(patient))
         {
             XtraMessageBox.Show("Element is not added!");
         }
         _patient = _DB.GetPatient();
         PatientGridControl.DataSource = _patient;
         ClearData();
     }
     else
     {
         XtraMessageBox.Show("All fields should be filled!");
     }
 }
Exemplo n.º 5
0
        public PrescriptionFormD(DBCommunication.DBCommunicationAdmin _db, int doctorID, int patientID)
        {
            InitializeComponent();
            _DB           = _db;
            _prescription = _DB.GetPrescriptionForPatient(patientID);
            PresciptionGridControl.DataSource = _prescription;

            _doctor = _DB.GetDoctor();


            _patient = _DB.GetPatient();

            patient = patientID;

            doctor = doctorID;
        }
Exemplo n.º 6
0
        public ReferralFormcs(DBCommunication.DBCommunicationAdmin _db)
        {
            InitializeComponent();

            _DB       = _db;
            _referral = _DB.GetReferral();
            ReferralGridControl.DataSource = _referral;

            _doctor = _DB.GetDoctor();
            DoctorLE.Properties.DataSource = _doctor;

            _patient = _DB.GetPatient();
            PatientLE.Properties.DataSource = _patient;

            DoctorLE.Properties.DisplayMember = "Surname";
            DoctorLE.Properties.ValueMember   = "ID";

            PatientLE.Properties.DisplayMember = "Surname";
            PatientLE.Properties.ValueMember   = "ID";
        }
Exemplo n.º 7
0
        public PrescriptionForm(DBCommunication.DBCommunicationAdmin _db)
        {
            InitializeComponent();
            _DB           = _db;
            _prescription = _DB.GetPrescription();
            PresciptionGridControl.DataSource = _prescription;

            _doctor = _DB.GetDoctor();
            DoctorLE.Properties.DataSource = _doctor;

            _patient = _DB.GetPatient();
            PatientLE.Properties.DataSource = _patient;

            DoctorLE.Properties.DisplayMember = "Surname";
            DoctorLE.Properties.ValueMember   = "ID";

            PatientLE.Properties.DisplayMember = "Surname";
            PatientLE.Properties.ValueMember   = "ID";

            DateTE.DateTime = DateTime.Now;
        }
Exemplo n.º 8
0
        public AgreedTermForm(DBCommunication.DBCommunicationAdmin _db)
        {
            InitializeComponent();
            HideShowElement(false);
            _termAM = new List <Term>();
            _termAM.Add(new Term {
                Time = "08:00:00"
            }); _termAM.Add(new Term {
                Time = "08:15:00"
            }); _termAM.Add(new Term {
                Time = "08:30:00"
            }); _termAM.Add(new Term {
                Time = "08:45:00"
            });
            _termAM.Add(new Term {
                Time = "09:00:00"
            }); _termAM.Add(new Term {
                Time = "09:15:00"
            }); _termAM.Add(new Term {
                Time = "09:30:00"
            }); _termAM.Add(new Term {
                Time = "09:45:00"
            });
            _termAM.Add(new Term {
                Time = "10:00:00"
            }); _termAM.Add(new Term {
                Time = "10:15:00"
            }); _termAM.Add(new Term {
                Time = "10:30:00"
            }); _termAM.Add(new Term {
                Time = "10:45:00"
            });
            _termAM.Add(new Term {
                Time = "11:00:00"
            }); _termAM.Add(new Term {
                Time = "11:15:00"
            }); _termAM.Add(new Term {
                Time = "11:30:00"
            }); _termAM.Add(new Term {
                Time = "11:45:00"
            });
            _termAM.Add(new Term {
                Time = "12:00:00"
            }); _termAM.Add(new Term {
                Time = "12:15:00"
            }); _termAM.Add(new Term {
                Time = "12:30:00"
            }); _termAM.Add(new Term {
                Time = "12:45:00"
            });
            _termAM.Add(new Term {
                Time = "13:00:00"
            }); _termAM.Add(new Term {
                Time = "13:15:00"
            }); _termAM.Add(new Term {
                Time = "13:30:00"
            }); _termAM.Add(new Term {
                Time = "13:45:00"
            });

            _termPM = new List <Term>();
            _termPM.Add(new Term {
                Time = "14:00:00"
            }); _termPM.Add(new Term {
                Time = "14:15:00"
            }); _termPM.Add(new Term {
                Time = "14:30:00"
            }); _termPM.Add(new Term {
                Time = "14:45:00"
            });
            _termPM.Add(new Term {
                Time = "15:00:00"
            }); _termPM.Add(new Term {
                Time = "15:15:00"
            }); _termPM.Add(new Term {
                Time = "15:30:00"
            }); _termPM.Add(new Term {
                Time = "15:45:00"
            });
            _termPM.Add(new Term {
                Time = "16:00:00"
            }); _termPM.Add(new Term {
                Time = "16:15:00"
            }); _termPM.Add(new Term {
                Time = "16:30:00"
            }); _termPM.Add(new Term {
                Time = "16:45:00"
            });
            _termPM.Add(new Term {
                Time = "17:00:00"
            }); _termPM.Add(new Term {
                Time = "17:15:00"
            }); _termPM.Add(new Term {
                Time = "17:30:00"
            }); _termPM.Add(new Term {
                Time = "17:45:00"
            });
            _termPM.Add(new Term {
                Time = "18:00:00"
            }); _termPM.Add(new Term {
                Time = "18:15:00"
            }); _termPM.Add(new Term {
                Time = "18:30:00"
            }); _termPM.Add(new Term {
                Time = "18:45:00"
            });
            _termPM.Add(new Term {
                Time = "19:00:00"
            }); _termPM.Add(new Term {
                Time = "19:15:00"
            }); _termPM.Add(new Term {
                Time = "19:30:00"
            }); _termPM.Add(new Term {
                Time = "19:45:00"
            });


            agreedTerm  = new AgreedTerm();
            _DB         = _db;
            _agreedTerm = _DB.GetAgreedTerm();
            AgreedTermGridControl.DataSource = _agreedTerm;

            _patient = _DB.GetPatient();

            PatientLE.Properties.DataSource    = _patient;
            PatientLE.Properties.DisplayMember = "Name";
            PatientLE.Properties.ValueMember   = "ID";

            _doctor = _DB.GetDoctor();
            DoctorLE.Properties.DataSource    = _doctor;
            DoctorLE.Properties.DisplayMember = "Name";
            DoctorLE.Properties.ValueMember   = "ID";
        }