/// <summary>
        /// Procedura actualizeaza un interval de absenta
        /// </summary>
        /// <param name="IntervalAbsentaID">Id-ul intervalului de absenta</param>
        /// <param name="TipAbsentaID">Id-ul tipului de absenta</param>
        /// <param name="DataStart">Data se inceput</param>
        /// <param name="DataEnd">Data de sfarsit</param>
        /// <param name="Observatii">Observatii</param>
        /// <param name="boalaID">Id-ul bolii</param>
        /// <param name="continuareAbsenta">Continuare absenta sau nu</param>
        /// <param name="medieZilnica">Media zilnica asociata</param>
        /// <param name="serie">Seriea</param>
        /// <param name="numar">Numarul</param>
        public void UpdateIntervalAbsenteAngajat(int IntervalAbsentaID, int TipAbsentaID, DateTime DataStart, DateTime DataEnd, string Observatii, int BoalaID, bool continuareAbsenta, double medieZilnica, string serie, string numar, bool certificatInitial, string serieCertificat, string numarCertificat, DateTime dataAcordarii, string cnpCopil, string locPrescriere, string codUrgenta, string nrAvizMedical)
        {
            try
            {
                //Oprescu Claudia
                //se verifica daca nu este continuare de concediu medical. Daca este atunci se copiaza seria si numarul de la concediu medical altfel se adauga null
                string SerieCertificatInitial = null, NumarCertificatInitial = null;

                UtilitiesDb ut = new UtilitiesDb(settings.ConnectionString);
                if (TipAbsentaID == ut.GetContinuareConcediuMedicalID())
                {
                    //se apeleaza procedura stocata pentru a se afla seria si numarul pentru concediul medical asociat
                    SqlCommand cmd = new SqlCommand("tm_IntervaleAbsentaContinuareConcediuMedical", m_con);
                    cmd.CommandType = CommandType.StoredProcedure;
                    cmd.Parameters.Add(UtilitiesDb.AddInputParameter("@AngajatID", SqlDbType.Int, 4, this.AngajatID));
                    cmd.Parameters.Add(UtilitiesDb.AddOutputParameter("@SerieCertificatInitial", SqlDbType.NVarChar, 10, ""));
                    cmd.Parameters.Add(UtilitiesDb.AddOutputParameter("@NumarCertificatInitial", SqlDbType.NVarChar, 50, ""));

                    m_con.Open();
                    cmd.ExecuteNonQuery();
                    m_con.Close();

                    SerieCertificatInitial = cmd.Parameters[1].Value.ToString().TrimEnd();
                    NumarCertificatInitial = cmd.Parameters[2].Value.ToString().TrimEnd();
                }

                SqlCommand myCommand = new SqlCommand("tm_InsertUpdateDeleteIntervalAbsenta", m_con);
                myCommand.CommandType = CommandType.StoredProcedure;

                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@tip_actiune", SqlDbType.Int, 4, 1));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@IntervalAbsentaID", SqlDbType.Int, 4, IntervalAbsentaID));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@TipAbsentaID", SqlDbType.Int, 4, TipAbsentaID));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@DataStart", SqlDbType.DateTime, 8, DataStart));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@DataEnd", SqlDbType.DateTime, 8, DataEnd));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@AngajatID", SqlDbType.Int, 4, this.AngajatID));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@Observatii", SqlDbType.NText, 16, Observatii));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@BoalaID", SqlDbType.Int, 4, BoalaID));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@Serie", SqlDbType.NVarChar, 10, serie));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@Numar", SqlDbType.NVarChar, 50, numar));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@SerieCertificatInitial", SqlDbType.NVarChar, 10, serieCertificat));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@NumarCertificatInitial", SqlDbType.NVarChar, 50, numarCertificat));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@ContinuareAbsenta", SqlDbType.Bit, 1, continuareAbsenta));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@MedieZilnica", SqlDbType.Real, 4, medieZilnica));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@EsteCertificat", SqlDbType.Bit, 1, certificatInitial));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@DataAcordariiCertificat", SqlDbType.DateTime, 8, dataAcordarii));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@CnpCopil", SqlDbType.NVarChar, 13, cnpCopil));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@LocPrescriereCertificat", SqlDbType.NVarChar, 50, locPrescriere));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@CodUrgenta", SqlDbType.NVarChar, 50, codUrgenta));
                myCommand.Parameters.Add(UtilitiesDb.AddInputParameter("@NrAvizMedicExpert", SqlDbType.NVarChar, 50, nrAvizMedical));

                m_con.Open();
                myCommand.ExecuteNonQuery();
                m_con.Close();
            }
            catch (Exception e)
            {
                string x = e.Message;
            }
        }