validacionesprepolizas
This commit is contained in:
@@ -347,7 +347,7 @@ Partial Class Bancos_DepositosCaja
|
|||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not OcurrioError AndAlso ObjConta.ValidacionPrePolizaCuadre(NuevaCvePrePoliza, 1) Then
|
If Not OcurrioError AndAlso ObjConta.ValidacionesPrePoliza(NuevaCvePrePoliza, UsuarioActual, Opcion:=1) Then
|
||||||
If ObjConta.ValorPolizaDescuadre > 0 Then
|
If ObjConta.ValorPolizaDescuadre > 0 Then
|
||||||
GuardaLogAD($"Bancos/DepositoCaja | Error{ObjConta.MensajePolizaDescuadre} Diferencia{ObjConta.ValorDiferencia} | CvePrePoliza:{NuevaCvePrePoliza}", "LogPrePolizas")
|
GuardaLogAD($"Bancos/DepositoCaja | Error{ObjConta.MensajePolizaDescuadre} Diferencia{ObjConta.ValorDiferencia} | CvePrePoliza:{NuevaCvePrePoliza}", "LogPrePolizas")
|
||||||
OcurrioError = True
|
OcurrioError = True
|
||||||
|
|||||||
@@ -852,7 +852,7 @@ Partial Class Bancos_PolizaCheque
|
|||||||
End Try
|
End Try
|
||||||
|
|
||||||
If MsgError = "" Then
|
If MsgError = "" Then
|
||||||
If ObjMov.ValidacionPrePolizaCuadre(CvePrePoliza, -1) Then
|
If ObjMov.ValidacionesPrePoliza(CvePrePoliza, UsuarioActual) Then
|
||||||
If ObjMov.ValorPolizaDescuadre > 0 Then
|
If ObjMov.ValorPolizaDescuadre > 0 Then
|
||||||
GuardaLogAD($"PolizaCheque/Guardar Error:{ObjMov.MensajePolizaDescuadre} Diferencia:{ObjMov.ValorDiferencia} | CvePrePoliza:{CvePrePoliza}", "LogPrePolizas")
|
GuardaLogAD($"PolizaCheque/Guardar Error:{ObjMov.MensajePolizaDescuadre} Diferencia:{ObjMov.ValorDiferencia} | CvePrePoliza:{CvePrePoliza}", "LogPrePolizas")
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -1320,7 +1320,7 @@ Partial Class Bancos_PopIEVentas
|
|||||||
|
|
||||||
If MsgError = "" Then
|
If MsgError = "" Then
|
||||||
|
|
||||||
If MsgError = "" AndAlso ObjMov.ValidacionPrePolizaCuadre(CvePrePoliza, 3) Then
|
If MsgError = "" AndAlso ObjMov.ValidacionesPrePoliza(CvePrePoliza, UsuarioActual, Opcion:=3) Then
|
||||||
If ObjMov.ValorPolizaDescuadre > 0 Then
|
If ObjMov.ValorPolizaDescuadre > 0 Then
|
||||||
MsgError = ObjMov.MensajePolizaDescuadre
|
MsgError = ObjMov.MensajePolizaDescuadre
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -74,7 +74,7 @@ Partial Class Bancos_PopUpBuscarIE
|
|||||||
|
|
||||||
Dim ObjBancosIE As New ClsBancos
|
Dim ObjBancosIE As New ClsBancos
|
||||||
If ObjBancosIE.GetBancosRepIE(-1, DdlCuenta.SelectedValue.ToEntero, "-1", -1, Folio, "-1", -1, -1, -1, -1, -1, txtFechaI.Text.ToDate,
|
If ObjBancosIE.GetBancosRepIE(-1, DdlCuenta.SelectedValue.ToEntero, "-1", -1, Folio, "-1", -1, -1, -1, -1, -1, txtFechaI.Text.ToDate,
|
||||||
MaxFecha.ToShortDateString.ToDate, MinFecha, MaxFecha, MinFecha, MaxFecha, -1, -1, UsuarioActual.CveEmpresa, TopSelect:=100) Then
|
MaxFecha.ToShortDateString.ToDate, MinFecha, MaxFecha, MinFecha, MaxFecha, -1, -1, -1, UsuarioActual.CveEmpresa, TopSelect:=100) Then
|
||||||
DtDatos = ObjBancosIE.DtResultados 'If(TxtFolio.Text <> "", ObjBancosIE.DtResultados.FiltraParametros(String.Format("Folio Like '{0}'", TxtFolio.Text)), ObjBancosIE.DtResultados)
|
DtDatos = ObjBancosIE.DtResultados 'If(TxtFolio.Text <> "", ObjBancosIE.DtResultados.FiltraParametros(String.Format("Folio Like '{0}'", TxtFolio.Text)), ObjBancosIE.DtResultados)
|
||||||
Else
|
Else
|
||||||
Alert("Ocurrió un error al consultar bancos", TipoMensaje.MsgError)
|
Alert("Ocurrió un error al consultar bancos", TipoMensaje.MsgError)
|
||||||
|
|||||||
@@ -296,14 +296,14 @@ Partial Class Bancos_ProductosFinancieros
|
|||||||
'Variables de controles
|
'Variables de controles
|
||||||
Dim Importe As Double = TxtImporte.Text.ToDouble
|
Dim Importe As Double = TxtImporte.Text.ToDouble
|
||||||
Dim CveMoneda As Integer = GlobalDTBancosCuentas(UsuarioActual.CveUsuario, CveEmpresa:=UsuarioActual.CveEmpresa).FiltroPrimero(String.Format("CveCuenta = {0}", DdlCuentas.SelectedValue))("CveMoneda").ToString.ToEntero()
|
Dim CveMoneda As Integer = GlobalDTBancosCuentas(UsuarioActual.CveUsuario, CveEmpresa:=UsuarioActual.CveEmpresa).FiltroPrimero(String.Format("CveCuenta = {0}", DdlCuentas.SelectedValue))("CveMoneda").ToString.ToEntero()
|
||||||
Dim Fecha = TxtFecha.Text.ToDate
|
Dim Fecha As Date = TxtFecha.Text.ToDate
|
||||||
|
|
||||||
'Variables de error
|
'Variables de error
|
||||||
Dim ErrorTransaccion = False
|
Dim ErrorTransaccion As Boolean = False
|
||||||
Dim ErrorAC = False
|
Dim ErrorAC As Boolean = False
|
||||||
|
|
||||||
Dim CvePrePoliza = -1
|
Dim CvePrePoliza As Integer = -1
|
||||||
Dim IdPoliza = -1
|
Dim IdPoliza As Integer = -1
|
||||||
Dim FolioPoliza As Integer = -1
|
Dim FolioPoliza As Integer = -1
|
||||||
Dim CveIE As Integer = -1
|
Dim CveIE As Integer = -1
|
||||||
|
|
||||||
@@ -313,8 +313,8 @@ Partial Class Bancos_ProductosFinancieros
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
'OBTIENE LA CUENTA CONTABLE DEL BANCO
|
'OBTIENE LA CUENTA CONTABLE DEL BANCO
|
||||||
Dim DtCuentas = GlobalDTBancosCuentas(-1, DdlCuentas.SelectedValue.ToEntero, CveEmpresa:=UsuarioActual.CveEmpresa).FiltraParametros("", "", {"CveCuenta", "IdCtaContable"})
|
Dim DtCuentas As DataTable = GlobalDTBancosCuentas(-1, DdlCuentas.SelectedValue.ToEntero, CveEmpresa:=UsuarioActual.CveEmpresa).FiltraParametros("", "", {"CveCuenta", "IdCtaContable"})
|
||||||
Dim CtaCuenta = -1
|
Dim CtaCuenta As Integer = -1
|
||||||
|
|
||||||
If DtCuentas.Rows.Count = 1 Then
|
If DtCuentas.Rows.Count = 1 Then
|
||||||
CtaCuenta = DtCuentas.Rows(0)("Id0CtaContable").ToString.ToEntero
|
CtaCuenta = DtCuentas.Rows(0)("Id0CtaContable").ToString.ToEntero
|
||||||
@@ -324,7 +324,7 @@ Partial Class Bancos_ProductosFinancieros
|
|||||||
|
|
||||||
If CveIE > 0 OrElse (DdlTarjeta.Visible AndAlso DdlTarjeta.SelectedValue.ToEntero > 0) Then
|
If CveIE > 0 OrElse (DdlTarjeta.Visible AndAlso DdlTarjeta.SelectedValue.ToEntero > 0) Then
|
||||||
|
|
||||||
Dim CvePlantilaPoliza = DdlTipoMovimiento.SelectedValue.ToString.ToEntero
|
Dim CvePlantilaPoliza As Integer = DdlTipoMovimiento.SelectedValue.ToString.ToEntero
|
||||||
Dim idCuentaContabilizacion As Long = 1
|
Dim idCuentaContabilizacion As Long = 1
|
||||||
Dim alertaContabilizacion As String = "Se enviaron correctamente las siguientes pólizas:<br><br>"
|
Dim alertaContabilizacion As String = "Se enviaron correctamente las siguientes pólizas:<br><br>"
|
||||||
Dim CuentasContablesInvalidas As New StringBuilder
|
Dim CuentasContablesInvalidas As New StringBuilder
|
||||||
@@ -332,7 +332,7 @@ Partial Class Bancos_ProductosFinancieros
|
|||||||
If ObjMov.GetPlantillaConceptos(UsuarioActual.CveEmpresa, CvePlantilaPoliza) Then
|
If ObjMov.GetPlantillaConceptos(UsuarioActual.CveEmpresa, CvePlantilaPoliza) Then
|
||||||
For Each Row As DataRow In ObjMov.DtResultados.Rows
|
For Each Row As DataRow In ObjMov.DtResultados.Rows
|
||||||
|
|
||||||
Dim ConceptoContable = Row("CveConcepto").ToString.ToEntero
|
Dim ConceptoContable As Integer = Row("CveConcepto").ToString.ToEntero
|
||||||
Dim TipoMovimiento As Boolean = If(Row("TipoMovto").ToString = "True", True, False)
|
Dim TipoMovimiento As Boolean = If(Row("TipoMovto").ToString = "True", True, False)
|
||||||
Dim importeMovimiento As Decimal = 0
|
Dim importeMovimiento As Decimal = 0
|
||||||
Dim FechaMovimiento As Date = Now
|
Dim FechaMovimiento As Date = Now
|
||||||
@@ -363,7 +363,7 @@ Partial Class Bancos_ProductosFinancieros
|
|||||||
|
|
||||||
Next
|
Next
|
||||||
|
|
||||||
If Not ObjMov.ValidacionPrePolizaCuadre(CvePrePoliza, 4) Then
|
If Not ObjMov.ValidacionesPrePoliza(CvePrePoliza, UsuarioActual, Opcion:=4) Then
|
||||||
ErrorTransaccion = True
|
ErrorTransaccion = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -177,7 +177,7 @@ Partial Class Bancos_PagosIntermediarios
|
|||||||
MsgError = "No se pudo insertar la póliza"
|
MsgError = "No se pudo insertar la póliza"
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If ObjMov.ValidacionPrePolizaCuadre(CvePrePoliza, -1) Then
|
If ObjMov.ValidacionesPrePoliza(CvePrePoliza, UsuarioActual) Then
|
||||||
If ObjMov.ValorPolizaDescuadre > 0 Then
|
If ObjMov.ValorPolizaDescuadre > 0 Then
|
||||||
MsgError = "La suma de los importes no coinciden"
|
MsgError = "La suma de los importes no coinciden"
|
||||||
End If
|
End If
|
||||||
|
|||||||
Reference in New Issue
Block a user