示例#1
0
        public List <fa_liquidaciones_tipo_proceso_Info> Get_List_Liqui_Tipo_Proceso(ref string mensaje)
        {
            try
            {
                List <fa_liquidaciones_tipo_proceso_Info> Lista = new List <fa_liquidaciones_tipo_proceso_Info>();

                using (Entity_Facturacion_FJ Context = new Entity_Facturacion_FJ())
                {
                    var select = from q in Context.fa_liquidaciones_tipo_proceso
                                 select q;

                    foreach (var item in select)
                    {
                        fa_liquidaciones_tipo_proceso_Info contact = new fa_liquidaciones_tipo_proceso_Info();

                        contact.IdTipo_Proceso             = item.IdTipo_Proceso;
                        contact.nom_IdTipo_Proceso_x_Liqui = item.nom_IdTipo_Proceso_x_Liqui;
                        contact.IdProducto_Liqui_x_defecto = item.IdProducto_Liqui_x_defecto;
                        Lista.Add(contact);
                    }
                }
                return(Lista);
            }
            catch (Exception ex)
            {
                string arreglo = ToString();
                tb_sis_Log_Error_Vzen_Data oDataLog      = new tb_sis_Log_Error_Vzen_Data();
                tb_sis_Log_Error_Vzen_Info Log_Error_sis = new tb_sis_Log_Error_Vzen_Info(ex.ToString(), "", arreglo, "", "", "", "", "", DateTime.Now);
                oDataLog.Guardar_Log_Error(Log_Error_sis, ref mensaje);
                mensaje = ex.ToString();
                throw new Exception(ex.ToString());
            }
        }
示例#2
0
        public bool ModificiarDB(fa_liquidaciones_tipo_proceso_Info Info, ref string mensaje)
        {
            try
            {
                using (Entity_Facturacion_FJ Context = new Entity_Facturacion_FJ())
                {
                    fa_liquidaciones_tipo_proceso contact = Context.fa_liquidaciones_tipo_proceso.FirstOrDefault(v => v.IdTipo_Proceso == Info.IdTipo_Proceso);

                    if (contact != null)
                    {
                        contact.IdProducto_Liqui_x_defecto = Info.IdProducto_Liqui_x_defecto;
                        contact.IdTipo_Proceso             = Info.IdTipo_Proceso;
                        contact.nom_IdTipo_Proceso_x_Liqui = Info.nom_IdTipo_Proceso_x_Liqui;
                        Context.SaveChanges();
                    }
                }
                return(true);
            }
            catch (Exception ex)
            {
                string arreglo = ToString();
                tb_sis_Log_Error_Vzen_Data oDataLog      = new tb_sis_Log_Error_Vzen_Data();
                tb_sis_Log_Error_Vzen_Info Log_Error_sis = new tb_sis_Log_Error_Vzen_Info(ex.ToString(), "", arreglo, "", "", "", "", "", DateTime.Now);
                oDataLog.Guardar_Log_Error(Log_Error_sis, ref mensaje);
                mensaje = ex.ToString();
                throw new Exception(ex.ToString());
            }
        }
示例#3
0
 private void gw_Liqui_tipo_proc_FocusedRowChanged(object sender, DevExpress.XtraGrid.Views.Base.FocusedRowChangedEventArgs e)
 {
     try
     {
         Info_Tipo_Proc = gw_Liqui_tipo_proc.GetRow(e.FocusedRowHandle) as fa_liquidaciones_tipo_proceso_Info;
     }
     catch (Exception ex)
     {
         string NameMetodo = System.Reflection.MethodBase.GetCurrentMethod().Name;
         MessageBox.Show(param.Get_Mensaje_sys(enum_Mensajes_sys.Error_comunicarse_con_sistemas) + ex.Message + " ", param.Nombre_sistema, MessageBoxButtons.OK, MessageBoxIcon.Error);
         Log_Error_bus.Log_Error(NameMetodo + " - " + ex.ToString());
     }
 }
示例#4
0
 public bool ModificiarDB(fa_liquidaciones_tipo_proceso_Info Info, ref string mensaje)
 {
     try
     {
         return(oData.ModificiarDB(Info, ref mensaje));
     }
     catch (Exception ex)
     {
         Core.Erp.Info.Log_Exception.LoggingManager.Logger.Log(Core.Erp.Info.Log_Exception.LoggingCategory.Error, ex.Message);
         throw new Core.Erp.Info.Log_Exception.DalException(string.Format("", "ModificarDB", ex.Message), ex)
               {
                   EntityType = typeof(fa_liquidaciones_tipo_proceso_Bus)
               };
     }
 }
示例#5
0
 public void SetInfo(fa_liquidaciones_tipo_proceso_Info _Info)
 {
     try
     {
         Info_TipoPro = _Info;
     }
     catch (Exception ex)
     {
         string NameMetodo = System.Reflection.MethodBase.GetCurrentMethod().Name;
         NameMetodo = NameMetodo + " - " + ex.ToString();
         MessageBox.Show(NameMetodo + " " + param.Get_Mensaje_sys(enum_Mensajes_sys.Error_comunicarse_con_sistemas)
                         , param.Nombre_sistema, MessageBoxButtons.OK, MessageBoxIcon.Error);
         Log_Error_bus.Log_Error(NameMetodo + " - " + ex.ToString());
     }
 }
示例#6
0
 private void Get()
 {
     try
     {
         Info_TipoPro = new fa_liquidaciones_tipo_proceso_Info();
         Info_TipoPro.IdTipo_Proceso             = txtIdTipoProceso.Text;
         Info_TipoPro.nom_IdTipo_Proceso_x_Liqui = txtNombreTipoProceso.Text;
         Info_TipoPro.IdProducto_Liqui_x_defecto = Convert.ToInt32(sealupProductoLiqui.EditValue);
     }
     catch (Exception ex)
     {
         string NameMetodo = System.Reflection.MethodBase.GetCurrentMethod().Name;
         NameMetodo = NameMetodo + " - " + ex.ToString();
         MessageBox.Show(NameMetodo + " " + param.Get_Mensaje_sys(enum_Mensajes_sys.Error_comunicarse_con_sistemas)
                         , param.Nombre_sistema, MessageBoxButtons.OK, MessageBoxIcon.Error);
         Log_Error_bus.Log_Error(NameMetodo + " - " + ex.ToString());
     }
 }
示例#7
0
 void ucGe_Menu_Mantenimiento_x_usuario1_event_btnconsultar_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
 {
     try
     {
         Info_TipoPro = (fa_liquidaciones_tipo_proceso_Info)this.gridViewLiquiTipoPro.GetFocusedRow();
         if (Info_TipoPro != null)
         {
             llama_frm(Cl_Enumeradores.eTipo_action.consultar);
         }
         else
         {
             MessageBox.Show(param.Get_Mensaje_sys(enum_Mensajes_sys.Por_favor_seleccione_item_a_consul), param.Nombre_sistema, MessageBoxButtons.OK, MessageBoxIcon.Exclamation);
         }
     }
     catch (Exception ex)
     {
         string NameMetodo = System.Reflection.MethodBase.GetCurrentMethod().Name;
         NameMetodo = NameMetodo + " - " + ex.ToString();
         MessageBox.Show(NameMetodo + " " + param.Get_Mensaje_sys(enum_Mensajes_sys.Error_comunicarse_con_sistemas)
                         , param.Nombre_sistema, MessageBoxButtons.OK, MessageBoxIcon.Error);
         Log_Error_bus.Log_Error(NameMetodo + " - " + ex.ToString());
     }
 }