Cambiar cargar conciliaciones a gembox.
Soporte en compras para actualizar contabilizados. Cambiar cargar contratos a gem box. Soporte en Ventas que no se pueda ingresar productos de diferente moneda.
This commit is contained in:
@@ -8829,6 +8829,16 @@ Partial Class Compras_Compras
|
||||
'Revisamos que los cambios hechos mantengan la interidad de los numeros
|
||||
If HFDiferenciaCompra.Value = TxtTotal.Text Or CveFactura < 1 Or CveCompra < 1 Then
|
||||
|
||||
If IdPoliza > 0 Then
|
||||
If Not ObjContabilidad.UpdatePrePolizasDetalleBloquear(CvePrePoliza, False) Then
|
||||
Retorno = False
|
||||
End If
|
||||
|
||||
If Not ObjContabilidad.UpdatePrePoliza(MinFecha, -1, -1, Nothing, CvePrePoliza, UsuarioActual.CveEmpresa) Then
|
||||
Retorno = False
|
||||
End If
|
||||
End If
|
||||
|
||||
'PORCENTAJE IVA
|
||||
Dim PorcentajeIVA As Decimal = TmpDT.MAX("IVAPorcentaje").ToDecimal
|
||||
|
||||
@@ -8846,11 +8856,7 @@ Partial Class Compras_Compras
|
||||
' End If
|
||||
'End If
|
||||
|
||||
If IdPoliza > 0 Then
|
||||
If Not ObjContabilidad.UpdatePrePolizasDetalleBloquear(CvePrePoliza, False) Then
|
||||
Retorno = False
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
'If UsuarioActual.Empresa.Funcionalidad(207) = "1" Then
|
||||
If Not ActualizarPrePoliza(ObjContabilidad, ObjCompra) Then
|
||||
@@ -8859,7 +8865,7 @@ Partial Class Compras_Compras
|
||||
'End If
|
||||
|
||||
''EMPIEZA: SI USA AC
|
||||
If (UsuarioActual.Empresa.UsaAC Or UsuarioActual.Empresa.Funcionalidad(200).ToString = "1") AndAlso IdPoliza > 0 Then
|
||||
If UsuarioActual.Empresa.UsaAC AndAlso IdPoliza > 0 Then
|
||||
ObjContaAC = New ClsContPAQi(UsuarioActual.Empresa)
|
||||
ObjContaAC.IniciaTransacSQL()
|
||||
|
||||
@@ -9242,9 +9248,11 @@ Partial Class Compras_Compras
|
||||
Next
|
||||
|
||||
If Retorno Then
|
||||
If ViewState("IdPoliza").ToString.ToEntero > 0 Then
|
||||
ObjContaAC = New ClsContPAQi(UsuarioActual.Empresa)
|
||||
ObjContaAC.IniciaTransacSQL()
|
||||
If (UsuarioActual.Empresa.UsaAC Or UsuarioActual.Empresa.Funcionalidad(200).ToString = "1") AndAlso IdPoliza > 0 Then
|
||||
If ObjContaAC Is Nothing Then
|
||||
ObjContaAC = New ClsContPAQi(UsuarioActual.Empresa)
|
||||
ObjContaAC.IniciaTransacSQL()
|
||||
End If
|
||||
|
||||
If Not ObjContabilidad.ContabilizarPrePoliza(CvePrePoliza, UsuarioActual.CveEmpresa, UsuarioActual.Empresa, MinFecha, String.Format("{0}-{1}", Serie, Folio), ObjContaAC, pIDPoliza:=ViewState("IdPoliza").ToString.ToEntero) Then
|
||||
Retorno = False
|
||||
@@ -9261,6 +9269,18 @@ Partial Class Compras_Compras
|
||||
|
||||
'Retorno = True
|
||||
'Alert("La Compra se actualizó correctamente.")
|
||||
Else
|
||||
|
||||
If IdPoliza > 0 Then
|
||||
If Not ObjContabilidad.UpdatePrePolizasDetalleBloquear(CvePrePoliza, True) Then
|
||||
Retorno = False
|
||||
End If
|
||||
|
||||
If Not ObjContabilidad.UpdatePrePoliza(MinFecha, -1, -1, IdPoliza, CvePrePoliza, UsuarioActual.CveEmpresa) Then
|
||||
Retorno = False
|
||||
End If
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
Else
|
||||
@@ -9275,7 +9295,7 @@ Partial Class Compras_Compras
|
||||
Catch ex As Exception
|
||||
Alert("Ocurrió un error al actualizar la compra", TipoMensaje.MsgError)
|
||||
ObjCompra.RollBack()
|
||||
ObjContaAC.RollBack()
|
||||
If ObjContaAC IsNot Nothing Then ObjContaAC.RollBack()
|
||||
|
||||
Finally
|
||||
If Retorno Then
|
||||
|
||||
Reference in New Issue
Block a user