Пример #1
0
 protected IList <T> RetornaListaDados <T>(string Procedure, List <SqlParameter> Par)
 {
     try
     {
         ExecCommands con = new ExecCommands();
         return(con.RetornaLista <T>(Procedure, Par));
     }
     catch (Exception ex)
     {
         Common.TratarLogErro(ex);
         return(null);
     }
 }
Пример #2
0
 protected IList <T> RetornaListaDados <T>(object obj = null)
 {
     try
     {
         if (obj != null)
         {
             AdicionaParametro(obj);
         }
         ExecCommands con = new ExecCommands();
         return(con.RetornaLista <T>(procedure, parametros));
     }
     catch (Exception ex)
     {
         Common.TratarLogErro(ex);
         return(null);
     }
 }
Пример #3
0
 protected int?ExecutaItem(object obj = null)
 {
     try
     {
         if (obj != null)
         {
             AdicionaParametro(obj);
         }
         ExecCommands con     = new ExecCommands();
         var          retorno = con.ExecutaItem(procedure, parametros);
         return(Convert.ToInt32(retorno));
     }
     catch (Exception ex)
     {
         Common.TratarLogErro(ex);
         return(null);
     }
 }