Ejemplo n.º 1
0
        private void fetchData()
        {
            this.txtYeuCauKham.Text = this.hoso.YeuCauKham;
            this.txtChuanDoan.Text  = this.hoso.ChuanDoan;
            this.txtTrieuChung.Text = this.hoso.TrieuChung;
            this.txtPhong.Text      = this.tenPhong;
            this.txtBacSi.Text      = Common.User.SharedInstance.UserName;

            this.patientMainInformation.binding(this.benhNhan);

            if (danhSachThuoc != null)
            {
                var thuocConfirm = new CreatePrescriptionsConfirm(this.danhSachThuoc, true)
                {
                    Dock = DockStyle.Fill
                };

                this.panelResult.Height = this.resultSize.Height;

                this.groupResult.Controls.Clear();
                this.groupResult.Controls.Add(thuocConfirm);
                this.groupResult.Text = "Đơn thuốc";
            }
            else if (danhSachXetNghiem != null)
            {
                var xetNghiemConfirm = new AssignTestsConfirm(this.danhSachXetNghiem, true)
                {
                    Dock = DockStyle.Fill
                };

                this.panelResult.Height = this.resultSize.Height;

                this.groupResult.Controls.Clear();
                this.groupResult.Controls.Add(xetNghiemConfirm);
                this.groupResult.Text = "Danh sách xét nghiệm";
            }
            else
            {
                this.panelResult.Height = 0;
            }
        }
Ejemplo n.º 2
0
        private void btnCreateMedical_Click(object sender, EventArgs e)
        {
            var formContainer = new Form()
            {
                Size          = new Size(850, 600),
                StartPosition = FormStartPosition.CenterParent
            };

            var createPrescriptionControl = new CreatePrescriptions(this.listThuoc)
            {
                Dock = DockStyle.Fill
            };

            createPrescriptionControl.DidCreate += (listThuoc) =>
            {
                formContainer.Close();

                this.btnAssignTests.Enabled = false;

                this.panelResult.Height = this.resultSize.Height;

                this.listThuoc = listThuoc;
                var medicalResult = new CreatePrescriptionsConfirm(listThuoc)
                {
                    Dock = DockStyle.Fill
                };

                medicalResult.ClearEvent += (obj, er) =>
                {
                    this.clearResultGroup();
                };

                this.groupResult.Controls.Clear();
                this.groupResult.Controls.Add(medicalResult);
                this.groupResult.Text = "Đơn thuốc";
            };

            formContainer.Controls.Add(createPrescriptionControl);
            formContainer.ShowDialog();
        }