Exemple #1
0
        public VisitViewercs(int ID, TextBox text) : this()
        {
            listView1.FullRowSelect = true;
            listView1.GridLines     = true;
            patid = ID;
            textb = text;
            var res = SQLLab.GetPatientData(patid);

            foreach (var order in res)
            {
                textBox1.Text = order.PESEL;
            }

            docs = SQLAdm.GetStaff("", "", "", "doc");
            foreach (var order in docs)
            {
                comboBox3.Items.Add(order.Surname);
            }

            listView1.Items.Clear();

            var temp = SQLRec.GetApo(patid);

            foreach (var order in temp)
            {
                ListViewItem lvi  = new ListViewItem(order.Id_Appointment.ToString());
                var          tmp  = SQLRec.GetDocData(order.Id_Doctor);
                string       name = tmp.FirstOrDefault().Name + " " + tmp.FirstOrDefault().Surname;
                lvi.SubItems.Add(name);
                lvi.SubItems.Add(order.Date_Appointment.ToString());
                lvi.SubItems.Add(SQLRec.translateRolePL(order.State.ToString()));

                listView1.Items.Add(lvi);
            }
        }
Exemple #2
0
        public Edit(string role, int t, TextBox textb) : this()
        {
            text   = textb;
            idappo = t;
            var temp = SQLLab.GetExamination_Laboratories_ID(t);

            textBox6.Text = temp.First().Table2.Name.ToString();
            textBox4.Text = temp.First().Table2.Exam_Code.ToString();

            textBox5.Text = temp.First().Table1.Result;
            textBox9.Text = temp.First().Table1.Comments_Doctor.ToString();
            textBox7.Text = temp.First().Table1.Comments_Man_Lab;
            var temp2 = SQLLab.GetPacjentID(temp.First().Table1.Id_Appointment);
            var temp3 = SQLLab.GetPatientData(temp2.First().Id_Patient);

            textBox1.Text  = temp3.First().Name.ToString();
            textBox2.Text  = temp3.First().Surname.ToString();
            textBox3.Text  = temp3.First().PESEL.ToString();
            textBox10.Text = SQLLab.translateRolePL(temp.First().Table1.State.ToString());
            roll           = role;
            if (role == "Lab")
            {
                textBox7.Enabled = false;
                button4.Enabled  = false;
            }
            if (role == "MLab")
            {
                button3.Enabled = false;
            }
        }
Exemple #3
0
        public Edit(int ID, TextBox text) : this()
        {
            apoid = ID;
            textb = text;

            var a = SQLRec.GetApoSE(apoid);
            //comboBox4.drop

            var res = SQLLab.GetPatientData(a.First().Id_Patient);

            foreach (var order in res)
            {
                textBox1.Text = order.Name;
                textBox2.Text = order.Surname;
                textBox3.Text = order.PESEL;
            }
            docs = SQLAdm.GetStaff("", "", "", "doc");
            foreach (var order in docs)
            {
                comboBox1.Items.Add(order.Surname);
            }

            var doc = SQLAdm.GetStaff(a.First().Id_Doctor);

            comboBox1.Text = doc.First().Name.ToString();                        //lekarz
            monthCalendar1.SetDate(a.First().Date_Appointment);                  //data
            comboBox3.Text = SQLRec.translateRolePL(a.First().State.ToString()); //stan
            //string time = a.First().Date_Appointment.Hour.ToString()+":" + a.First().Date_Appointment.Minute.ToString();
            string time = a.First().Date_Appointment.ToString("HH:mm");

            comboBox2.Text = time;//godzina

            // comboBox4.DropDownStyle = ComboBoxStyle.DropDownList;
            // comboBox2.Text = a.First().Date_Appointment.TimeOfDay.ToString();
        }
Exemple #4
0
        public PatientEdit(int patid, TextBox text) : this()
        {
            textb = text;
            id    = patid;
            var res = SQLLab.GetPatientData(patid);

            textBox1.Text = res.First().Name.ToString();
            textBox2.Text = res.First().Surname.ToString();
            textBox3.Text = res.First().PESEL.ToString();
        }
        public VisitRegistration(int ID, TextBox text, int whoami) : this()
        {
            patid = ID;
            textb = text;
            idrec = whoami;
            var res = SQLLab.GetPatientData(patid);

            foreach (var order in res)
            {
                textBox1.Text = order.Name;
                textBox2.Text = order.Surname;
                textBox3.Text = order.PESEL;
            }
            docs = SQLAdm.GetStaff("", "", "", "doc");
            foreach (var order in docs)
            {
                comboBox1.Items.Add(order.Surname);
            }
        }
Exemple #6
0
        public Show(int t, TextBox textb) : this()
        {
            text = textb;

            var temp = SQLLab.GetExamination_Laboratories_ID(t);

            textBox6.Text = temp.First().Table2.Name.ToString();
            textBox4.Text = temp.First().Table2.Exam_Code.ToString();
            textBox8.Text = SQLLab.translateRolePL(temp.First().Table1.State.ToString());

            textBox5.Text = temp.First().Table1.Result;
            textBox9.Text = temp.First().Table1.Comments_Doctor;
            textBox7.Text = temp.First().Table1.Comments_Man_Lab;
            var temp2 = SQLLab.GetPacjentID(temp.First().Table1.Id_Appointment);
            var temp3 = SQLLab.GetPatientData(temp2.First().Id_Patient);

            textBox1.Text = temp3.First().Name.ToString();
            textBox2.Text = temp3.First().Surname.ToString();
            textBox3.Text = temp3.First().PESEL.ToString();
        }
Exemple #7
0
        public Show(int ID, TextBox text) : this()
        {
            apoid = ID;
            textb = text;

            var a = SQLRec.GetApoSE(apoid);


            var res = SQLLab.GetPatientData(a.First().Id_Patient);

            foreach (var order in res)
            {
                textBox1.Text = order.Name;
                textBox2.Text = order.Surname;
                textBox3.Text = order.PESEL;
            }
            var doc = SQLAdm.GetStaff(a.First().Id_Doctor);

            textBox4.Text = doc.First().Name.ToString();                        //lekarz

            textBox7.Text = a.First().Date_Appointment.ToString();              //data
            textBox6.Text = SQLRec.translateRolePL(a.First().State.ToString()); //stan
            string time = a.First().Date_Appointment.TimeOfDay.ToString();
        }