コード例 #1
0
 /// <summary>
 /// Eliminar Usuario
 /// </summary>
 /// <param name="id">Identificador del usuario</param>
 public static void Eliminar(int id)
 {
     try
     {
         VentaDal.Eliminar(id);
     }
     catch (SqlException ex)
     {
         Methods.GenerateLogsRelease("VentaBrl", "Eliminar", string.Format("{0} {1} Error: {2}", DateTime.Now.ToShortDateString(), DateTime.Now.ToShortTimeString(), ex.Message));
         throw ex;
     }
     catch (Exception ex)
     {
         Methods.GenerateLogsRelease("VentaBrl", "Eliminar", string.Format("{0} {1} Error: {2}", DateTime.Now.ToShortDateString(), DateTime.Now.ToShortTimeString(), ex.Message));
         throw ex;
     }
 }
コード例 #2
0
 /// <summary>
 /// Actualiza los datos del paciente en la base de datos
 /// </summary>
 /// <param name="venta"></param>
 public static void Actualizar(Venta venta)
 {
     try
     {
         VentaDal.Actualizar(venta);
     }
     catch (SqlException ex)
     {
         Methods.GenerateLogsRelease("VentaBrl", "Actualizar", string.Format("{0} {1} Error: {2}", DateTime.Now.ToShortDateString(), DateTime.Now.ToShortTimeString(), ex.Message));
         throw ex;
     }
     catch (Exception ex)
     {
         Methods.GenerateLogsRelease("VentaBrl", "Actualizar", string.Format("{0} {1} Error: {2}", DateTime.Now.ToShortDateString(), DateTime.Now.ToShortTimeString(), ex.Message));
         throw ex;
     }
     Methods.GenerateLogsDebug("VentaDal", "Insertar", string.Format("{0} {1} Info: {2}", DateTime.Now.ToShortDateString(), DateTime.Now.ToShortTimeString(), "Termino de ejecutar  el metodo acceso a datos para Actualizar un usuario"));
 }
コード例 #3
0
 public VentaBl()
 {
     _ventaDal          = new VentaDal();
     _cotizacionService = new CotizacionService();
     _vehiculoService   = new VehiculoService();
 }