-- genera cuenta desglosada
This commit is contained in:
@@ -1548,26 +1548,51 @@ Public Class ClsContabilidad
|
|||||||
Return Retorno
|
Return Retorno
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Function GetCuentaDobleConta(IdCtaContable As Integer, CveEmpresa As Integer) As Boolean
|
'Public Function GetCuentaDobleConta(IdCtaContable As Integer, CveEmpresa As Integer) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
' Dim Retorno As Boolean = False
|
||||||
|
|
||||||
DataAdapter("PA_Conta_CuentaDobleContaGet")
|
' DataAdapter("PA_Conta_CuentaDobleContaGet")
|
||||||
|
|
||||||
|
' With SqlAdapter.SelectCommand.Parameters
|
||||||
|
' .Add("@IdCtaContable", SqlDbType.Int).Value = IdCtaContable
|
||||||
|
' .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
|
' End With
|
||||||
|
|
||||||
|
' Try
|
||||||
|
' SqlAdapter.Fill(Data)
|
||||||
|
' Retorno = True
|
||||||
|
' Catch ex As Exception
|
||||||
|
' OnError("Ocurrió un error al obtener la cuenta doble.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
|
' End Try
|
||||||
|
|
||||||
|
' Return Retorno
|
||||||
|
'End Function
|
||||||
|
|
||||||
|
Public Function GeneraCuentaDesglose(CveConceptoUnico As Integer, CveTipoSaldo As Integer, CveCuentaPadre As Integer, CveGeneral As Integer, CveUsuario As Integer, CveEmpresa As Integer) As Integer
|
||||||
|
Dim Retorno As Integer = -1
|
||||||
|
DataAdapter("PA_Conta_CuentasGeneraDesglose")
|
||||||
With SqlAdapter.SelectCommand.Parameters
|
With SqlAdapter.SelectCommand.Parameters
|
||||||
.Add("@IdCtaContable", SqlDbType.Int).Value = IdCtaContable
|
.Add("@CveConceptoContableUnico", SqlDbType.Int).Value = CveConceptoUnico
|
||||||
|
.Add("@CveTipoSaldo", SqlDbType.Int).Value = CveTipoSaldo
|
||||||
|
.Add("@CveGeneral", SqlDbType.Int).Value = CveGeneral
|
||||||
|
.Add("@CveCuentaPadre", SqlDbType.Int).Value = CveCuentaPadre
|
||||||
|
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
||||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
|
.Add("@CveCuentaGenerada", SqlDbType.Int).Direction = ParameterDirection.Output
|
||||||
End With
|
End With
|
||||||
|
|
||||||
Try
|
Try
|
||||||
SqlAdapter.Fill(Data)
|
SqlAdapter.Fill(Data)
|
||||||
Retorno = True
|
Retorno = SqlAdapter.SelectCommand.Parameters("@CveCuentaGenerada").Value.ToString.ToEntero
|
||||||
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
OnError("Ocurrió un error al obtener la cuenta doble.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
OnError("Ocurrió un error al obtener Movimientos Prepolizas.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||||
End Try
|
End Try
|
||||||
|
|
||||||
Return Retorno
|
Return Retorno
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
|
|
||||||
Public Function DesAplicarPago(CvePrePoliza As Integer, CveConcepto As Integer, CveVenta As Integer, CveVentaAmortizacion As Integer) As Boolean
|
Public Function DesAplicarPago(CvePrePoliza As Integer, CveConcepto As Integer, CveVenta As Integer, CveVentaAmortizacion As Integer) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
DataAdapter("PA_Conta_DesAplicarMovimiento")
|
DataAdapter("PA_Conta_DesAplicarMovimiento")
|
||||||
@@ -6047,36 +6072,39 @@ Public Class ClsContabilidad
|
|||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
#Region "VALIDACION POLIZA DESCUADRADA"
|
#Region "VALIDACION POLIZA DESCUADRADA"
|
||||||
Public Function ValidacionPrePolizaCuadre(CvePrePoliza As Integer, Opcion As Integer, Optional CveVenta As Integer = -1, Optional AutoConta As Boolean = True) As Boolean
|
'Public Function ValidacionPrePolizaCuadre(CvePrePoliza As Integer, Opcion As Integer, Optional CveVenta As Integer = -1, Optional AutoConta As Boolean = True) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
' Dim Retorno As Boolean = False
|
||||||
|
|
||||||
DataAdapter("PA_Conta_PrePolizasValidacion")
|
' DataAdapter("PA_Conta_PrePolizasValidacion")
|
||||||
With SqlAdapter.SelectCommand.Parameters
|
' With SqlAdapter.SelectCommand.Parameters
|
||||||
.Add("@CvePrePoliza", SqlDbType.Int).Value = CvePrePoliza
|
' .Add("@CvePrePoliza", SqlDbType.Int).Value = CvePrePoliza
|
||||||
.Add("@Opcion", SqlDbType.Int).Value = Opcion
|
' .Add("@Opcion", SqlDbType.Int).Value = Opcion
|
||||||
' .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
' ' .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
.Add("@CveVenta", SqlDbType.Int).Value = CveVenta
|
' .Add("@CveVenta", SqlDbType.Int).Value = CveVenta
|
||||||
.Add("@AutoConta", SqlDbType.Int).Value = If(AutoConta, 1, 0)
|
' .Add("@AutoConta", SqlDbType.Int).Value = If(AutoConta, 1, 0)
|
||||||
.Add("@Valor", SqlDbType.Int).Direction = ParameterDirection.Output
|
' .Add("@Valor", SqlDbType.Int).Direction = ParameterDirection.Output
|
||||||
.Add("@MsgSalida", SqlDbType.VarChar, 100).Direction = ParameterDirection.Output
|
' .Add("@MsgSalida", SqlDbType.VarChar, 100).Direction = ParameterDirection.Output
|
||||||
.Add("@MsgPrePolizaSalida", SqlDbType.VarChar, 8000).Direction = ParameterDirection.Output
|
' .Add("@MsgPrePolizaSalida", SqlDbType.VarChar, 8000).Direction = ParameterDirection.Output
|
||||||
.Add("@Diferencia", SqlDbType.Float).Direction = ParameterDirection.Output
|
' .Add("@Diferencia", SqlDbType.Float).Direction = ParameterDirection.Output
|
||||||
End With
|
' .Add("@FolioPoliza", SqlDbType.Int).Direction = ParameterDirection.Output
|
||||||
|
' End With
|
||||||
|
|
||||||
Try
|
' Try
|
||||||
SqlAdapter.Fill(Data)
|
' SqlAdapter.Fill(Data)
|
||||||
Retorno = True
|
' Retorno = True
|
||||||
ValorPolizaDescuadre = SqlAdapter.SelectCommand.Parameters("@Valor").Value.ToString.ToEntero
|
' ValorPolizaDescuadre = SqlAdapter.SelectCommand.Parameters("@Valor").Value.ToString.ToEntero
|
||||||
MensajePolizaDescuadre = SqlAdapter.SelectCommand.Parameters("@MsgSalida").Value.ToString
|
' MensajePolizaDescuadre = SqlAdapter.SelectCommand.Parameters("@MsgSalida").Value.ToString
|
||||||
ValorDiferencia = SqlAdapter.SelectCommand.Parameters("@Diferencia").Value.ToString
|
' ValorDiferencia = SqlAdapter.SelectCommand.Parameters("@Diferencia").Value.ToString
|
||||||
Dim MsgPrePoliza As String = SqlAdapter.SelectCommand.Parameters("@MsgPrePolizaSalida").Value.ToString
|
' Dim MsgPrePoliza As String = SqlAdapter.SelectCommand.Parameters("@MsgPrePolizaSalida").Value.ToString
|
||||||
If MsgPrePoliza <> "" Then MsgPrePoliza.GuardaLogAD("LogPrePoliza")
|
' ContaFolio = SqlAdapter.SelectCommand.Parameters("@FolioPoliza").Value.ToString.ToEntero
|
||||||
Catch ex As Exception
|
' If MsgPrePoliza <> "" Then MsgPrePoliza.GuardaLogAD("LogPrePoliza")
|
||||||
OnError("Ocurrió un error al validar la PrePoliza.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
|
||||||
End Try
|
|
||||||
|
|
||||||
Return Retorno
|
' Catch ex As Exception
|
||||||
End Function
|
' OnError("Ocurrió un error al validar la PrePoliza.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
|
' End Try
|
||||||
|
|
||||||
|
' Return Retorno
|
||||||
|
'End Function
|
||||||
|
|
||||||
Public Function ValidacionesPrePoliza(CvePrePoliza As Integer, ByRef UsuarioActual As Usuario, Optional Opcion As Integer = 1,
|
Public Function ValidacionesPrePoliza(CvePrePoliza As Integer, ByRef UsuarioActual As Usuario, Optional Opcion As Integer = 1,
|
||||||
Optional CveVenta As Integer = -1, Optional AutoConta As Boolean = True,
|
Optional CveVenta As Integer = -1, Optional AutoConta As Boolean = True,
|
||||||
|
|||||||
Reference in New Issue
Block a user