From 2fa5ccacd226f928deebc83973121715abf99146 Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 29 May 2020 00:01:40 -0700 Subject: [PATCH 1/4] -- conexion, si es compartida para registrar la bitacora de conexion --- App_Code/ClsAF.vb | 4 +++- App_Code/ClsAcumuladores.vb | 4 +++- App_Code/ClsCompProveedores.vb | 4 +++- App_Code/ClsGPS.vb | 6 ++++-- App_Code/ClsGralFolios.vb | 4 +++- App_Code/ClsOC.vb | 4 +++- App_Code/ClsOIEventos.vb | 5 ++++- App_Code/ClsProductosServicios.vb | 5 +++-- App_Code/ClsSAT.vb | 4 +++- App_Code/ClsVtaVendedores.vb | 4 +++- 10 files changed, 32 insertions(+), 12 deletions(-) diff --git a/App_Code/ClsAF.vb b/App_Code/ClsAF.vb index f08a705e2..ee7e27b43 100644 --- a/App_Code/ClsAF.vb +++ b/App_Code/ClsAF.vb @@ -21,6 +21,7 @@ Public Class ClsAF Private disposedValue As Boolean = False ' Para detectar llamadas redundantes 'REGISTRAR CONEXIÓN Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False #End Region #Region "Propiedades" @@ -95,6 +96,7 @@ Public Class ClsAF Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlAdapter = New SqlDataAdapter("", SqlConexion) @@ -112,7 +114,7 @@ Public Class ClsAF #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try DataAdapter("PA_Sis_RegistrarConexion") With SqlAdapter.SelectCommand.Parameters diff --git a/App_Code/ClsAcumuladores.vb b/App_Code/ClsAcumuladores.vb index e451e5b44..46ca6341d 100644 --- a/App_Code/ClsAcumuladores.vb +++ b/App_Code/ClsAcumuladores.vb @@ -19,6 +19,7 @@ Public Class ClsAcumuladores Private disposedValue As Boolean = False ' Para detectar llamadas redundantes 'REGISTRAR CONEXIÓN Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False Private Sub SqlDataAdapter(StrSQL As String, Optional TipoComando As CommandType = CommandType.StoredProcedure) With SqlAdapter.SelectCommand @@ -62,6 +63,7 @@ Public Class ClsAcumuladores Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlAdapter = New SqlDataAdapter("", SqlConexion) @@ -70,7 +72,7 @@ Public Class ClsAcumuladores #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try SqlDataAdapter("PA_Sis_RegistrarConexion") With SqlAdapter.SelectCommand.Parameters diff --git a/App_Code/ClsCompProveedores.vb b/App_Code/ClsCompProveedores.vb index bbbc1b8f1..813a15016 100644 --- a/App_Code/ClsCompProveedores.vb +++ b/App_Code/ClsCompProveedores.vb @@ -21,6 +21,7 @@ Public Class ClsCompProveedores Private disposedValue As Boolean = False ' Para detectar llamadas redundantes 'REGISTRAR CONEXIÓN Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False #End Region #Region "Propiedades" @@ -170,6 +171,7 @@ Public Class ClsCompProveedores Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlAdapter = New SqlDataAdapter("", SqlConexion) @@ -187,7 +189,7 @@ Public Class ClsCompProveedores #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try DataAdapter("PA_Sis_RegistrarConexion") With SqlAdapter.SelectCommand.Parameters diff --git a/App_Code/ClsGPS.vb b/App_Code/ClsGPS.vb index 622a9de14..1488d68ff 100644 --- a/App_Code/ClsGPS.vb +++ b/App_Code/ClsGPS.vb @@ -22,7 +22,8 @@ Public Class ClsGPS Private disposedValue As Boolean = False ' Para detectar llamadas redundantes 'REGISTRAR CONEXIONES ABIERTAS - Private CveConexion As Integer = 0 + Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False Public ReadOnly Property DtResultados() As DataTable Get @@ -61,6 +62,7 @@ Public Class ClsGPS Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlAdapter = New SqlDataAdapter("", SqlConexion) @@ -78,7 +80,7 @@ Public Class ClsGPS #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try DataAdapter("PA_Sis_RegistrarConexion") With SqlAdapter.SelectCommand.Parameters diff --git a/App_Code/ClsGralFolios.vb b/App_Code/ClsGralFolios.vb index d65f873ba..2705071c7 100644 --- a/App_Code/ClsGralFolios.vb +++ b/App_Code/ClsGralFolios.vb @@ -34,6 +34,7 @@ Public Class ClsGralFolios Private disposedValue As Boolean = False ' Para detectar llamadas redundantes 'REGISTRAR CONEXIONES ABIERTAS Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False #End Region @@ -72,6 +73,7 @@ Public Class ClsGralFolios Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlAdapter = New SqlDataAdapter("", SqlConexion) @@ -90,7 +92,7 @@ Public Class ClsGralFolios #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try DataAdapter("PA_Sis_RegistrarConexion") With SqlAdapter.SelectCommand.Parameters diff --git a/App_Code/ClsOC.vb b/App_Code/ClsOC.vb index ba3ba2c77..cf460fdab 100644 --- a/App_Code/ClsOC.vb +++ b/App_Code/ClsOC.vb @@ -18,6 +18,7 @@ Public Class ClsOC Private disposedValue As Boolean = False 'PARA REGISTRAR CONEXION Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False #End Region @@ -163,6 +164,7 @@ Public Class ClsOC Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlCommand = New SqlCommand("", SqlConexion) @@ -182,7 +184,7 @@ Public Class ClsOC #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then 'DataAdapter(String.Format("INSERT INTO Sis_Conexiones (Clase,Modulo) VALUES ('ClsRH','{0}')", "RH/CatMotivosBaja"), CommandType.Text) ' pendiente de terminar parra registrar el cveconexion, falta el rarámetro de módulo diff --git a/App_Code/ClsOIEventos.vb b/App_Code/ClsOIEventos.vb index d8084033f..551593b30 100644 --- a/App_Code/ClsOIEventos.vb +++ b/App_Code/ClsOIEventos.vb @@ -75,6 +75,8 @@ Public Class ClsOIEventos Private disposedValue As Boolean = False ' Para detectar llamadas redundantes 'PARA REGISTRAR CONEXION Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False + #End Region #Region "Propiedades" @@ -164,6 +166,7 @@ Public Class ClsOIEventos Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlCommand = New SqlCommand("", SqlConexion) @@ -183,7 +186,7 @@ Public Class ClsOIEventos #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then 'DataAdapter(String.Format("INSERT INTO Sis_Conexiones (Clase,Modulo) VALUES ('ClsRH','{0}')", "RH/CatMotivosBaja"), CommandType.Text) ' pendiente de terminar parra registrar el cveconexion, falta el rarámetro de módulo diff --git a/App_Code/ClsProductosServicios.vb b/App_Code/ClsProductosServicios.vb index 16d4ca047..02e26a446 100644 --- a/App_Code/ClsProductosServicios.vb +++ b/App_Code/ClsProductosServicios.vb @@ -20,7 +20,7 @@ Public Class ClsProductosServicios Private disposedValue As Boolean = False 'PARA REGISTRAR CONEXION Private CveConexion As Integer = 0 - + Private EsTransaccionCompartida As Boolean = False #End Region #Region "Propiedades" @@ -152,6 +152,7 @@ Public Class ClsProductosServicios Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlAdapter = New SqlDataAdapter("", SqlConexion) @@ -169,7 +170,7 @@ Public Class ClsProductosServicios #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try diff --git a/App_Code/ClsSAT.vb b/App_Code/ClsSAT.vb index abc93de5a..b5592d9d8 100644 --- a/App_Code/ClsSAT.vb +++ b/App_Code/ClsSAT.vb @@ -32,6 +32,7 @@ Public Class ClsSAT Private ContListado69B As Integer = 0 'PARA REGISTRAR CONEXION Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False #End Region #Region "Propiedades" @@ -76,6 +77,7 @@ Public Class ClsSAT Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlAdapter = New SqlDataAdapter("", SqlConexion) @@ -95,7 +97,7 @@ Public Class ClsSAT #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try 'DataAdapter(String.Format("INSERT INTO Sis_Conexiones (Clase,Modulo) VALUES ('ClsRH','{0}')", "RH/CatMotivosBaja"), CommandType.Text) ' pendiente de terminar parra registrar el cveconexion, falta el rarámetro de módulo diff --git a/App_Code/ClsVtaVendedores.vb b/App_Code/ClsVtaVendedores.vb index e76734c7f..6949554e1 100644 --- a/App_Code/ClsVtaVendedores.vb +++ b/App_Code/ClsVtaVendedores.vb @@ -15,6 +15,7 @@ Public Class ClsVtaVendedores Private disposedValue As Boolean = False ' Para detectar llamadas redundantes 'PARA REGISTRAR CONEXION Private CveConexion As Integer = 0 + Private EsTransaccionCompartida As Boolean = False #End Region #Region "Propiedades" @@ -51,6 +52,7 @@ Public Class ClsVtaVendedores Else SqlConexion = TransaccionCompartida.Connection SqlTransacc = TransaccionCompartida + EsTransaccionCompartida = True End If SqlCommand = New SqlCommand("", SqlConexion) @@ -70,7 +72,7 @@ Public Class ClsVtaVendedores #Region "Conexiones" Private Sub ConexionAdd() - If ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then + If Not EsTransaccionCompartida AndAlso ConfigurationManager.AppSettings("RegistraConexion") IsNot Nothing AndAlso ConfigurationManager.AppSettings("RegistraConexion").ToString() = "1" Then Try DataAdapter("PA_Sis_RegistrarConexion") With SqlAdapter.SelectCommand.Parameters From 310740e2b1b5e8058dce0f8ddd389ae662599666 Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 29 May 2020 00:01:59 -0700 Subject: [PATCH 2/4] -- metodo de contabilizacion SIG, que no se usa --- Bancos/PopIECompras.aspx.vb | 18 +++--------------- Bancos/PopIEVentas.aspx.vb | 13 ------------- Bancos/Transferencias.aspx.vb | 17 ----------------- 3 files changed, 3 insertions(+), 45 deletions(-) diff --git a/Bancos/PopIECompras.aspx.vb b/Bancos/PopIECompras.aspx.vb index e1909a2b2..16c6010ad 100644 --- a/Bancos/PopIECompras.aspx.vb +++ b/Bancos/PopIECompras.aspx.vb @@ -3251,21 +3251,9 @@ Partial Class Bancos_PopIECompras MsgError = ObjMov.MensajePolizaDescuadre GuardaLogAD($"Bancos/PopIECompras | Error:{ObjMov.MensajePolizaDescuadre} Diferencia:{ObjMov.ValorDiferencia} | CvePrePoliza:{CvePrePoliza}", "LogPrePolizas") End If - End If - - If UsuarioActual.Empresa.Funcionalidad(200) = "1" AndAlso MsgError = "" AndAlso UsuarioActual.Empresa.UsaContabilidadSIG Then - If CveCuentaContabilizacion > 0 Then - If ObjMov.ContabilizarPrePolizaSIG(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then - Alert(alertaContabilizacion, ModExtensiones.TipoMensaje.MsgInformacion) - Else - Alert("Ocurrio un error al contabilizar en SIG, pongase en contacto con Soporte Técnico") - End If - Else - Alert(String.Format("No se puede contabilizar la Prepoliza en SIG debido a que las siguientes cuentas son invalidas: {0}", CuentasContablesInvalidasSIG)) - End If - End If - - 'Conta ContPAQ + End If + + 'Conta ContPAQ If UsuarioActual.Empresa.Funcionalidad(200) = "1" AndAlso MsgError = "" Then If idCuentaContabilizacion > 0 Then If ObjMov.ContabilizarPrePoliza(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then diff --git a/Bancos/PopIEVentas.aspx.vb b/Bancos/PopIEVentas.aspx.vb index 587e2dafd..17a1b63e6 100644 --- a/Bancos/PopIEVentas.aspx.vb +++ b/Bancos/PopIEVentas.aspx.vb @@ -3484,19 +3484,6 @@ Partial Class Bancos_PopIEVentas End If End If - 'Conta SIG - If UsuarioActual.Empresa.Funcionalidad(200) = "1" AndAlso MsgError = "" AndAlso UsuarioActual.Empresa.UsaContabilidadSIG Then - If CveCuentaContabilizacion > 0 Then - If ObjMov.ContabilizarPrePolizaSIG(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then - Alert(alertaContabilizacion, ModExtensiones.TipoMensaje.MsgInformacion) - Else - Alert("Ocurrio un error al contabilizar en SIG, pongase en contacto con Soporte Técnico") - End If - Else - Alert(String.Format("No se puede contabilizar la Prepoliza en SIG debido a que las siguientes cuentas son invalidas: {0}", CuentasContablesInvalidasSIG)) - End If - End If - 'Conta ContPAQ If UsuarioActual.Empresa.Funcionalidad(200) = "1" And MsgError = "" Then If idCuentaContabilizacion > 0 Then diff --git a/Bancos/Transferencias.aspx.vb b/Bancos/Transferencias.aspx.vb index 7ccdbb882..826813cd0 100644 --- a/Bancos/Transferencias.aspx.vb +++ b/Bancos/Transferencias.aspx.vb @@ -394,23 +394,6 @@ Partial Class Bancos_Transferencias If MsgError = "" Then - 'Conta SIG - If UsuarioActual.Empresa.Funcionalidad(200) = "1" And MsgError = "" AndAlso UsuarioActual.Empresa.UsaContabilidadSIG Then - If (CveCuentaOrigen > 0 AndAlso CveCuentaDestino > 0) OrElse (CveCuentaDestino > 0 AndAlso Opcion = 1) Then - - If ObjMov.ContabilizarPrePolizaSIG(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa, Fecha:=TxtFechaDocumento.Text) Then - If ObjMov.ContaIdPoliza > 0 Then - AlertaGlobal.AppendFormat("

Ver Póliza", ObjMov.ContaIdPoliza) - End If - - Else - MsgError = "Ocurrio un error al contabilizar en SIG, pongase en contacto con Soporte Técnico" - End If - Else - MsgError = String.Format("No se puede contabilizar la Prepoliza en SIG debido a que las siguientes cuentas son invalidas: {0}", CuentasContablesInvalidasSIG) - End If - End If - 'Conta ContPAQ If UsuarioActual.Empresa.Funcionalidad(200) = "1" And MsgError = "" Then If (IdCtaContableOrigen > 0 AndAlso IdCtaContableDestino > 0) OrElse (IdCtaContableDestino > 0 AndAlso Opcion = 1) Then From 9e01a2067f577b47599a26cbedacd9c52e344713 Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 29 May 2020 00:02:18 -0700 Subject: [PATCH 3/4] -- cambios de serie,lote --- Compras/Compras.aspx | 6 +++--- Compras/Compras.aspx.vb | 7 ++++++- Compras/ReembolsosComprobaciones.aspx.vb | 10 ++-------- Inventarios/EntregaAlmacen.aspx | 2 +- Inventarios/EntregaAlmacen.aspx.vb | 11 +++++++---- Inventarios/RepApartados2.aspx | 2 +- Sistemas/CatSesiones.aspx.vb | 2 +- 7 files changed, 21 insertions(+), 19 deletions(-) diff --git a/Compras/Compras.aspx b/Compras/Compras.aspx index 12f49a6e8..7c5b5214e 100644 --- a/Compras/Compras.aspx +++ b/Compras/Compras.aspx @@ -1225,9 +1225,9 @@ - + - + @@ -2554,7 +2554,7 @@ - +

diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb index 774fefb2c..9502c2b01 100644 --- a/Compras/Compras.aspx.vb +++ b/Compras/Compras.aspx.vb @@ -6543,6 +6543,7 @@ Partial Class Compras_Compras Case 176 Dim SumatoriaOCINV = 0.0D, Importe176 = 0.0D, ImporteME176 = 0.0D, ImporteMN176 = 0.0D, Importe228 = 0.0D, ImporteME228 = 0.0D, ImporteMN228 = 0.0D, Importe229 = 0.0D, ImporteME229 = 0.0D, ImporteMN229 = 0.0D, ImporteCI176 = 0.0D Dim SumatoriaInventario As Decimal = 0 + Dim TCO As Decimal = 1 For Each Dr As DataRow In TmpDT.FiltraParametros("ISNULL(TipoAF,0) <> 2 And ISNULL(CveAlmacen,0) = 0 And ISNULL(AplicaCostoIndirecto,0) <> 1 And ISNULL(CveTipoPS,0) = 2").Rows If ObjOC.OrdenesCompraDetalleCostoPP(Dr("CveOrdenCompraDetalle").ToString.ToEntero) AndAlso ObjOC.DtResultados.Rows.Count >= 1 Then Concepto = $"{NombreProveedor} {TxtSerie.Text} - {TxtFolio.Text} OC {ObjOC.DtResultados.FiltroPrimeroValor("Folio").ToString} Inv{ObjOC.DtResultados.FiltroPrimeroValor("FolioAlmacen").ToString}" @@ -6554,6 +6555,7 @@ Partial Class Compras_Compras Dim TCAjuste As Decimal = ObjOC.DtResultados.FiltroPrimeroValor("TipoCambioAjuste").ToDecimal 'RMF. falta verificar el costo indirecto de la OC If DdlMoneda.SelectedValue.ToEntero <> 1 And UsuarioActual.CveEmpresa.Contiene(119) Then + TCO = TxtTC.Text.ToDecimal ImporteCI176 = ObjOC.DtResultados.FiltroPrimeroValor("ImporteCI228").ToDecimal CostoIndirectoAcum176 += ImporteCI176 SumatoriaInventario += Importe228 + Importe229 @@ -6586,7 +6588,7 @@ Partial Class Compras_Compras Next 'calcula la diferencia entre lo recibido por la OC, considerando costos indirectos y lo que se ingresaria en la compra - SumatoriaOCINV = SumatoriaInventario - TmpDT.SUMD("Total") 'sumatoria de la factura + SumatoriaOCINV = SumatoriaInventario - (TmpDT.SUMD("Total") * 1).RoundSQL 'sumatoria de la factura If SumatoriaOCINV.RoundSQL <> 0 Then ' se abona el costo, cambiamos su naturaleza 'SumatoriaOCINV = -SumatoriaOCINV @@ -18529,6 +18531,9 @@ Partial Class Compras_Compras If ObjVentas.GetInv_ComprasMov(CveCompra, UsuarioActual.CveEmpresa) Then If ObjVentas.DtResultados.Rows.Count > 0 Then GvInvMov.DataSource = ObjVentas.DtResultados + GvInvMov.Columns(3).Visible = ObjVentas.DtResultados.MAX("Serie", "Serie <> ''") <> "" + 'GvInvMov.Columns(5).Visible = DtTemporal.MAX("Lote", "Lote <> ''") <> "" + 'GvInvMov.Columns(6).Visible = DtTemporal.MAX("FechaCaducidad").ToDate > MinFecha End If End If GvInvMov.DataBind() diff --git a/Compras/ReembolsosComprobaciones.aspx.vb b/Compras/ReembolsosComprobaciones.aspx.vb index 518d6a1aa..6b3f13f29 100644 --- a/Compras/ReembolsosComprobaciones.aspx.vb +++ b/Compras/ReembolsosComprobaciones.aspx.vb @@ -1316,10 +1316,7 @@ Partial Class Compras_ReembolsosComprobaciones If UsuarioActual.Empresa.UsaContabilidadSIG AndAlso CveCuentaProveedor > 0 Then If UsuarioActual.Empresa.UsaContabilidadSIG AndAlso CveCuentaIVAxAcreditar > 0 Then If UsuarioActual.Empresa.UsaContabilidadSIG AndAlso CveCuentaIVAAcreditable > 0 Then - If ObjMov.ContabilizarPrePolizaSIG(CvePrePolizaIERegistrado, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then - Else - MsgError = "Ocurrio un Error al contabilizar en SIG, pongase en contacto con Soporte Técnico" - End If + Else MsgError = "No tiene cuenta contable SIG IVA Acreditable" End If @@ -1341,10 +1338,7 @@ Partial Class Compras_ReembolsosComprobaciones If UsuarioActual.Empresa.UsaContabilidadSIG AndAlso CveCuentaIVAAcreditable > 0 Then If UsuarioActual.Empresa.UsaContabilidadSIG AndAlso CveCuentaRetIVA > 0 Then If UsuarioActual.Empresa.UsaContabilidadSIG AndAlso CveCuentaRetISR > 0 Then - If ObjMov.ContabilizarPrePolizaSIG(CvePrePolizaExcedente, UsuarioActual.CveUsuario, UsuarioActual.Empresa) Then - Else - MsgError = "Ocurrio un Error al contabilizar en SIG, pongase en contacto con Soporte Técnico" - End If + Else MsgError = "No tiene cuenta contable SIG Ret ISR" End If diff --git a/Inventarios/EntregaAlmacen.aspx b/Inventarios/EntregaAlmacen.aspx index 7928e67d6..70313db73 100644 --- a/Inventarios/EntregaAlmacen.aspx +++ b/Inventarios/EntregaAlmacen.aspx @@ -238,7 +238,7 @@ -
+
diff --git a/Inventarios/EntregaAlmacen.aspx.vb b/Inventarios/EntregaAlmacen.aspx.vb index 251fa5deb..4777d29aa 100644 --- a/Inventarios/EntregaAlmacen.aspx.vb +++ b/Inventarios/EntregaAlmacen.aspx.vb @@ -790,7 +790,7 @@ Partial Class Inventarios_EntregaAlmacen 'CARGA LO PRECARGADO CON SERIE Dim Contador = 0 For Each Gvr As GridViewRow In GvDatos.Rows - If Gvr.DataKey("CvePS").ToEntero = CvePSSerie Then + If Gvr.DataKey("CvePS").ToEntero = CvePSSerie AndAlso DtDatosDetalle IsNot Nothing Then Contador = DtDatosDetalle.FiltraParametros(String.Format("ConsecId = {0}", Gvr.DataKey("Consec"))).Rows.Count Gvr.FCCheckBox("cbInv").Enabled = False Gvr.FCCheckBox("cbInv").Checked = True @@ -809,9 +809,12 @@ Partial Class Inventarios_EntregaAlmacen e.Row.FCButton("BtnSerie").CommandArgument = String.Format("{0}°{1}°{2}°{3}°{4}°{5}", e.Row.DBCampo("CvePS"), e.Row.DBCampo("CveUM"), e.Row.DBCampo("PS"), e.Row.DBCampo("CantidadF"), e.Row.DBCampo("Consec"), e.Row.DBCampo("Inv_CveMetodoInventario")) e.Row.FCTextBox("TbCantidadF").Enabled = False e.Row.FCCheckBox("cbInv").Enabled = False - Dim Contador = DtDatosDetalle.FiltraParametros(String.Format("ConsecId = {0}", e.Row.DBCampo("Consec"))).Rows.Count - e.Row.FCTextBox("TbCantidadF").Text = Contador.ToString - 'e.Row.FCTextBox("TbCantidadF").Text = "0" + If e.Row.DBCampo("Consec") <> "" AndAlso DtDatosDetalle IsNot Nothing Then + Dim Contador = DtDatosDetalle.FiltraParametros(String.Format("ConsecId = {0}", e.Row.DBCampo("Consec"))).Rows.Count + e.Row.FCTextBox("TbCantidadF").Text = Contador.ToString + 'e.Row.FCTextBox("TbCantidadF").Text = "0" + End If + If TipoDocto = "DPe" Then CveConsecSerie = e.Row.DBCampo("Consec").ToString.ToEntero diff --git a/Inventarios/RepApartados2.aspx b/Inventarios/RepApartados2.aspx index aecae7b73..f40374908 100644 --- a/Inventarios/RepApartados2.aspx +++ b/Inventarios/RepApartados2.aspx @@ -110,7 +110,7 @@ <%----%> <%-- - %> + --%> diff --git a/Sistemas/CatSesiones.aspx.vb b/Sistemas/CatSesiones.aspx.vb index f363c3e59..046bd3751 100644 --- a/Sistemas/CatSesiones.aspx.vb +++ b/Sistemas/CatSesiones.aspx.vb @@ -168,7 +168,7 @@ Partial Class Sistemas_CatSesiones Private Sub CargaAlmacen() Dim Objinventarios As New ClsInventarios If Objinventarios.GetAlmacenes(-1, -1, -1, -1) Then Application("GlobalDTAlmacen") = Objinventarios.DtResultados Else Application("GlobalDTAlmacen") = Nothing - If Objinventarios.GetSeccionesAlmacenes(-1) Then Application("GlobalDTSeccionAlmacen") = Objinventarios.DtResultados Else Application("GlobalDTSeccionAlmacen") = Nothing + If Objinventarios.GetSeccionesAlmacenes(-1, -1) Then Application("GlobalDTSeccionAlmacen") = Objinventarios.DtResultados Else Application("GlobalDTSeccionAlmacen") = Nothing If Objinventarios.GetTiposAlmacenes Then Application("GlobalDTTipoAlmacen") = Objinventarios.DtResultados Else Application("GlobalDTTipoAlmacen") = Nothing If Objinventarios.GetConceptos Then Application("GlobalDTInvConceptos") = Objinventarios.DtResultados Else Application("GlobalDTInvConceptos") = Nothing Objinventarios.Dispose() From 0e0be565c8dbdaf5f83aaf1b48e9e4bbf8989c38 Mon Sep 17 00:00:00 2001 From: Rakcsle Supertramp Date: Fri, 29 May 2020 09:23:05 -0700 Subject: [PATCH 4/4] Compras habilitar viaticos cuanesta seleccionado reembolso en codiciones de pago --- Compras/Compras.aspx.vb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb index 774fefb2c..2f4445412 100644 --- a/Compras/Compras.aspx.vb +++ b/Compras/Compras.aspx.vb @@ -12724,7 +12724,7 @@ Partial Class Compras_Compras RBLContado.Items(0).Enabled = False RBLContado.Items(3).Enabled = True - RBLContado.Items(4).Enabled = False + RBLContado.Items(4).Enabled = True RBLContado.Items(5).Enabled = False