Пример #1
0
 /// <summary>
 /// Metodo para Guardar/Modificar una entidad LoteReimplante
 /// </summary>
 /// <param name="info"></param>
 internal int Guardar(LoteReimplanteInfo info)
 {
     try
     {
         Logger.Info();
         var loteReimplanteDAL = new LoteReimplanteDAL();
         int result            = info.LoteReimplanteID;
         if (info.LoteReimplanteID == 0)
         {
             result = loteReimplanteDAL.Crear(info);
         }
         else
         {
             loteReimplanteDAL.Actualizar(info);
         }
         return(result);
     }
     catch (ExcepcionGenerica)
     {
         throw;
     }
     catch (Exception ex)
     {
         Logger.Error(ex);
         throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex);
     }
 }
Пример #2
0
 /// <summary>
 /// Obtiene un lista de LoteReimplante
 /// </summary>
 /// <returns></returns>
 internal IList <LoteReimplanteInfo> ObtenerTodos()
 {
     try
     {
         Logger.Info();
         var loteReimplanteDAL             = new LoteReimplanteDAL();
         IList <LoteReimplanteInfo> result = loteReimplanteDAL.ObtenerTodos();
         return(result);
     }
     catch (ExcepcionGenerica)
     {
         throw;
     }
     catch (Exception ex)
     {
         Logger.Error(ex);
         throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex);
     }
 }
Пример #3
0
 /// <summary>
 /// Obtiene un lista paginada
 /// </summary>
 /// <param name="pagina"></param>
 /// <param name="filtro"></param>
 /// <returns></returns>
 internal ResultadoInfo <LoteReimplanteInfo> ObtenerPorPagina(PaginacionInfo pagina, LoteReimplanteInfo filtro)
 {
     try
     {
         Logger.Info();
         var loteReimplanteDAL = new LoteReimplanteDAL();
         ResultadoInfo <LoteReimplanteInfo> result = loteReimplanteDAL.ObtenerPorPagina(pagina, filtro);
         return(result);
     }
     catch (ExcepcionGenerica)
     {
         throw;
     }
     catch (Exception ex)
     {
         Logger.Error(ex);
         throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex);
     }
 }
Пример #4
0
 /// <summary>
 /// Obtiene una lista de lotes reimplante
 /// </summary>
 /// <param name="organizacionId"> </param>
 /// <param name="lotes"></param>
 /// <returns></returns>
 internal IList <LoteReimplanteInfo> ObtenerPorLoteXML(int organizacionId, IList <LoteInfo> lotes)
 {
     try
     {
         Logger.Info();
         var loteReimplanteDal             = new LoteReimplanteDAL();
         IList <LoteReimplanteInfo> result = loteReimplanteDal.ObtenerPorLoteXML(organizacionId, lotes);
         return(result);
     }
     catch (ExcepcionGenerica)
     {
         throw;
     }
     catch (Exception ex)
     {
         Logger.Error(ex);
         throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex);
     }
 }
Пример #5
0
 /// <summary>
 /// Obtiene lote reimplante de un lote
 /// </summary>
 /// <param name="lote"></param>
 /// <returns></returns>
 public List <LoteReimplanteInfo> ObtenerListaPorLote(LoteInfo lote)
 {
     try
     {
         Logger.Info();
         var loteReimplanteDal = new LoteReimplanteDAL();
         var result            = loteReimplanteDal.ObtenerListaPorLote(lote);
         return(result);
     }
     catch (ExcepcionGenerica)
     {
         throw;
     }
     catch (Exception ex)
     {
         Logger.Error(ex);
         throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex);
     }
 }
Пример #6
0
 /// <summary>
 /// Metodo para Guardar/Modificar una entidad LoteReimplante
 /// </summary>
 /// <param name="listaReimplantes"></param>
 internal int GuardarListaReimplantes(List <LoteReimplanteInfo> listaReimplantes)
 {
     try
     {
         Logger.Info();
         var loteReimplanteDAL = new LoteReimplanteDAL();
         int result            = loteReimplanteDAL.GuardarListaReimplantes(listaReimplantes);
         return(result);
     }
     catch (ExcepcionGenerica)
     {
         throw;
     }
     catch (Exception ex)
     {
         Logger.Error(ex);
         throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex);
     }
 }
Пример #7
0
 /// <summary>
 /// Obtiene una entidad LoteReimplante por su descripcion
 /// </summary>
 /// <param name="descripcion">Obtiene una entidad LoteReimplante por su Id</param>
 /// <returns></returns>
 internal LoteReimplanteInfo ObtenerPorDescripcion(string descripcion)
 {
     try
     {
         Logger.Info();
         var loteReimplanteDAL     = new LoteReimplanteDAL();
         LoteReimplanteInfo result = loteReimplanteDAL.ObtenerPorDescripcion(descripcion);
         return(result);
     }
     catch (ExcepcionGenerica)
     {
         throw;
     }
     catch (Exception ex)
     {
         Logger.Error(ex);
         throw new ExcepcionDesconocida(MethodBase.GetCurrentMethod(), ex);
     }
 }