private void AddBerem_Load(object sender, EventArgs e)
        {
            try
            {
                cbTypeDoc.DataSource = docName;

                if (insert == true)
                {
                    woman = LoadClass.FuncINSRT(client_id);

                    tbLNAME.Text            = woman.Rows[0][0].ToString();
                    tbFNAME.Text            = woman.Rows[0][1].ToString();
                    tbMNAME.Text            = woman.Rows[0][2].ToString();
                    dateBDATE.Value         = DateTime.Parse(woman.Rows[0][3].ToString());
                    tbADDRESS.Text          = woman.Rows[0][4].ToString();
                    tbSNILS.Text            = woman.Rows[0][5].ToString();
                    tbSPOLICY.Text          = woman.Rows[0][6].ToString();
                    tbNPOLICY.Text          = woman.Rows[0][7].ToString();
                    cbTypeDoc.SelectedIndex = int.Parse(woman.Rows[0][8].ToString());
                    tbSDOC.Text             = woman.Rows[0][9].ToString();
                    tbNDOC.Text             = woman.Rows[0][10].ToString();
                    dateDDOC.Value          = DateTime.Parse(woman.Rows[0][11].ToString());
                    tbODOC.Text             = woman.Rows[0][12].ToString();
                    tbSCERTIF.Text          = woman.Rows[0][13].ToString();
                    tbNCERTIF.Text          = woman.Rows[0][14].ToString();
                    dateDCERTIF.Value       = DateTime.Parse(woman.Rows[0][15].ToString());
                    tbSLEAF.Text            = woman.Rows[0][16].ToString();
                    tbNLEAF.Text            = woman.Rows[0][17].ToString();
                    dateDLEAF.Value         = DateTime.Parse(woman.Rows[0][18].ToString());
                }
                else
                {
                    forUpdate = InsertUpdateClass.LoadMotherUPDT_BTAL1(client_id);

                    tbLNAME.Text            = forUpdate.Rows[0][1].ToString();
                    tbFNAME.Text            = forUpdate.Rows[0][2].ToString();
                    tbMNAME.Text            = forUpdate.Rows[0][3].ToString();
                    dateBDATE.Value         = DateTime.Parse(forUpdate.Rows[0][4].ToString());
                    tbADDRESS.Text          = forUpdate.Rows[0][5].ToString();
                    tbSNILS.Text            = forUpdate.Rows[0][6].ToString();
                    tbSPOLICY.Text          = forUpdate.Rows[0][7].ToString();
                    tbNPOLICY.Text          = forUpdate.Rows[0][8].ToString();
                    cbTypeDoc.SelectedIndex = int.Parse(forUpdate.Rows[0][9].ToString());
                    tbSDOC.Text             = forUpdate.Rows[0][10].ToString();
                    tbNDOC.Text             = forUpdate.Rows[0][11].ToString();
                    dateDDOC.Value          = DateTime.Parse(forUpdate.Rows[0][12].ToString());
                    tbODOC.Text             = forUpdate.Rows[0][13].ToString();
                    tbSCERTIF.Text          = forUpdate.Rows[0][14].ToString();
                    tbNCERTIF.Text          = forUpdate.Rows[0][15].ToString();
                    dateDCERTIF.Value       = DateTime.Parse(forUpdate.Rows[0][16].ToString());
                    tbSLEAF.Text            = forUpdate.Rows[0][17].ToString();
                    tbNLEAF.Text            = forUpdate.Rows[0][18].ToString();
                    dateDLEAF.Value         = DateTime.Parse(forUpdate.Rows[0][19].ToString());
                    dateDREG.Value          = DateTime.Parse(forUpdate.Rows[0][21].ToString());
                    tbQTW.Text       = forUpdate.Rows[0][22].ToString();
                    cBMULP.Checked   = (forUpdate.Rows[0][23].ToString() == "1" ? true : false);
                    cBPREM.Checked   = (forUpdate.Rows[0][24].ToString() == "1" ? true : false);
                    PHELP_CB.Checked = (forUpdate.Rows[0][25].ToString() == "1" ? true : false);

                    if (forUpdate.Rows[0][20].ToString() == "1")
                    {
                        if (forUpdate.Rows[0][25].ToString() == "1")
                        {
                            lbCHK.ForeColor = Color.Black;
                            lbCHK.Text      = "4000,00";
                        }
                        else
                        {
                            lbCHK.ForeColor = Color.Black;
                            lbCHK.Text      = "3000,00";
                        }
                    }

                    this.Text = "Редактирование записи";
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error);
                logger.Debug("\n/--------------------------------------------------------------------/\n" + ex.StackTrace + "\n//----------------------------//\n" + ex.Message + "\n\n");
            }
        }
        private void AddPatient_Load(object sender, EventArgs e)
        {
            try
            {
                cbTypeDoc.DataSource = docName;

                dgvCHILD.AutoGenerateColumns = false;
                dgvCHILD.DataSource          = Child;

                if (insert == true)
                {
                    woman = LoadClass.FuncINSRT(client_id);

                    tbLNAME.Text            = woman.Rows[0][0].ToString();
                    tbFNAME.Text            = woman.Rows[0][1].ToString();
                    tbMNAME.Text            = woman.Rows[0][2].ToString();
                    dateBDATE.Value         = DateTime.Parse(woman.Rows[0][3].ToString());
                    tbADDRESS.Text          = woman.Rows[0][4].ToString();
                    tbSNILS.Text            = woman.Rows[0][5].ToString();
                    tbSPOLICY.Text          = woman.Rows[0][6].ToString();
                    tbNPOLICY.Text          = woman.Rows[0][7].ToString();
                    cbTypeDoc.SelectedIndex = int.Parse(woman.Rows[0][8].ToString());
                    tbSDOC.Text             = woman.Rows[0][9].ToString();
                    tbNDOC.Text             = woman.Rows[0][10].ToString();
                    dateDDOC.Value          = DateTime.Parse(woman.Rows[0][11].ToString());
                    tbODOC.Text             = woman.Rows[0][12].ToString();
                    tbSCERTIF.Text          = woman.Rows[0][13].ToString();
                    tbNCERTIF.Text          = woman.Rows[0][14].ToString();
                    dateDCERTIF.Value       = DateTime.Parse(woman.Rows[0][15].ToString());
                    tbSLEAF.Text            = woman.Rows[0][16].ToString();
                    tbNLEAF.Text            = woman.Rows[0][17].ToString();
                    dateDLEAF.Value         = DateTime.Parse(woman.Rows[0][18].ToString());
                }
                else
                {
                    forTableUPD = InsertUpdateClass.FuncMotherUPD(client_id);

                    dateDREG.Value          = DateTime.Parse(forTableUPD.Rows[0][0].ToString());
                    tbDIAG.Text             = forTableUPD.Rows[0][1].ToString();
                    tbBQNT.Text             = forTableUPD.Rows[0][2].ToString();
                    tbLNAME.Text            = forTableUPD.Rows[0][3].ToString();
                    tbFNAME.Text            = forTableUPD.Rows[0][4].ToString();
                    tbMNAME.Text            = forTableUPD.Rows[0][5].ToString();
                    dateBDATE.Value         = DateTime.Parse(forTableUPD.Rows[0][6].ToString());
                    tbADDRESS.Text          = forTableUPD.Rows[0][7].ToString();
                    tbSNILS.Text            = forTableUPD.Rows[0][8].ToString();
                    tbSPOLICY.Text          = forTableUPD.Rows[0][9].ToString();
                    tbNPOLICY.Text          = forTableUPD.Rows[0][10].ToString();
                    cbTypeDoc.SelectedIndex = int.Parse(forTableUPD.Rows[0][11].ToString());
                    tbSDOC.Text             = forTableUPD.Rows[0][12].ToString();
                    tbNDOC.Text             = forTableUPD.Rows[0][13].ToString();
                    dateDDOC.Value          = DateTime.Parse(forTableUPD.Rows[0][14].ToString());
                    tbODOC.Text             = forTableUPD.Rows[0][15].ToString();
                    tbSCERTIF.Text          = forTableUPD.Rows[0][16].ToString();
                    tbNCERTIF.Text          = forTableUPD.Rows[0][17].ToString();
                    dateDCERTIF.Value       = DateTime.Parse(forTableUPD.Rows[0][18].ToString());
                    tbSLEAF.Text            = forTableUPD.Rows[0][19].ToString();
                    tbNLEAF.Text            = forTableUPD.Rows[0][20].ToString();
                    dateDLEAF.Value         = DateTime.Parse(forTableUPD.Rows[0][21].ToString());
                    tbNCARD.Text            = forTableUPD.Rows[0][22].ToString();
                    dateDCARD.Value         = DateTime.Parse(forTableUPD.Rows[0][23].ToString());

                    BQNT  = int.Parse(tbBQNT.Text);
                    Child = InsertUpdateClass.FuncChildUPD(client_id, tbSCERTIF.Text + " " + tbNCERTIF.Text);
                    dgvCHILD.DataSource = Child;

                    AddCNTChild = dgvCHILD.Rows.Count;
                    oldCertif   = $"{tbSCERTIF.Text + " " + tbNCERTIF.Text}";
                    this.Text   = "Редактирование записи";
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.Message, "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error);
                logger.Debug("\n/--------------------------------------------------------------------/\n" + ex.StackTrace + "\n//----------------------------//\n" + ex.Message + "\n\n");
            }
        }