se quitó referencias a cvecuentas
This commit is contained in:
@@ -767,7 +767,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
Dim ImporteMovimiento = 0.0D
|
Dim ImporteMovimiento = 0.0D
|
||||||
Dim importeMX = 0.0D
|
Dim importeMX = 0.0D
|
||||||
Dim IdCtaContable = 0
|
Dim IdCtaContable = 0
|
||||||
Dim CveCuenta = 0
|
|
||||||
Dim ConceptoMovimiento = ""
|
Dim ConceptoMovimiento = ""
|
||||||
Dim Referencia = ""
|
Dim Referencia = ""
|
||||||
Dim CveSubProyecto = -1
|
Dim CveSubProyecto = -1
|
||||||
@@ -810,7 +809,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
ImporteMovimiento = 0
|
ImporteMovimiento = 0
|
||||||
importeMX = 0
|
importeMX = 0
|
||||||
IdCtaContable = 0
|
IdCtaContable = 0
|
||||||
CveCuenta = 0
|
|
||||||
PorcentajeImpuesto = 0
|
PorcentajeImpuesto = 0
|
||||||
ConceptoMovimiento = ObjConta.ObtenerConceptoEmpresa(UsuarioActual.CveEmpresa, ConceptoContable, LtlCliente.Text, DrPago("Factura").ToString, DrPago("Factura").ToString)
|
ConceptoMovimiento = ObjConta.ObtenerConceptoEmpresa(UsuarioActual.CveEmpresa, ConceptoContable, LtlCliente.Text, DrPago("Factura").ToString, DrPago("Factura").ToString)
|
||||||
'VALORES DE LA VENTA
|
'VALORES DE LA VENTA
|
||||||
@@ -843,14 +841,12 @@ Partial Class Ventas_PortalCliente
|
|||||||
|
|
||||||
If CveMonedaVenta = 1 Then
|
If CveMonedaVenta = 1 Then
|
||||||
IdCtaContable = IdCuentaCliente
|
IdCtaContable = IdCuentaCliente
|
||||||
CveCuenta = CveCuentacliente
|
|
||||||
Else
|
Else
|
||||||
IdCtaContable = IdCtaContMonedaExtranjera
|
IdCtaContable = IdCtaContMonedaExtranjera
|
||||||
CveCuenta = CveCuentaComplementaria
|
|
||||||
ConceptoMovimiento += $" TC:{TCPago} ${ImporteMovimiento.FormatoNumero(2)}"
|
ConceptoMovimiento += $" TC:{TCPago} ${ImporteMovimiento.FormatoNumero(2)}"
|
||||||
|
|
||||||
If ImporteMovimiento <> 0 AndAlso IdCtaContable > 0 Then
|
If ImporteMovimiento <> 0 AndAlso IdCtaContable > 0 Then
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Referencia, 207, ConceptoMovimiento, FechaMovimiento, IdCtaContable, -1, -1, CveVenta, -1, CveSubProyecto, CveCliente, ImporteMX:=(importeMX - ImporteMovimiento).RoundSQL(), ImporteME:=ImporteMovimiento, CveCuenta:=CveCuenta, TipoCambio:=TCVenta) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Referencia, 207, ConceptoMovimiento, FechaMovimiento, IdCtaContable, -1, -1, CveVenta, -1, CveSubProyecto, CveCliente, ImporteMX:=(importeMX - ImporteMovimiento).RoundSQL(), ImporteME:=ImporteMovimiento, TipoCambio:=TCVenta) Then
|
||||||
TieneError = True
|
TieneError = True
|
||||||
MensajeError.Append("No se pudo insertar el detalle de pago de la póliza<br>")
|
MensajeError.Append("No se pudo insertar el detalle de pago de la póliza<br>")
|
||||||
Exit For
|
Exit For
|
||||||
@@ -858,7 +854,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
IdCtaContable = IdCtaContMonedaExtranjera
|
IdCtaContable = IdCtaContMonedaExtranjera
|
||||||
CveCuenta = CveCuentaMonedaExtranjera
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Case 134 'PAGO INTERMEDIARIO
|
Case 134 'PAGO INTERMEDIARIO
|
||||||
@@ -882,7 +877,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
TCGeneral = TCVenta
|
TCGeneral = TCVenta
|
||||||
|
|
||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaIVAxTrasladar
|
IdCtaContable = UsuarioActual.Empresa.IdCuentaIVAxTrasladar
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaIVAxTrasladar
|
|
||||||
If TCVenta > 1 Then ConceptoMovimiento += $" TC:{TCVenta} ${ImporteMovimiento.FormatoNumero(2)}"
|
If TCVenta > 1 Then ConceptoMovimiento += $" TC:{TCVenta} ${ImporteMovimiento.FormatoNumero(2)}"
|
||||||
|
|
||||||
Case 61 'IVA TRASLADADO
|
Case 61 'IVA TRASLADADO
|
||||||
@@ -900,7 +894,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
TCGeneral = TCFluctuacion
|
TCGeneral = TCFluctuacion
|
||||||
|
|
||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaIVATrasladado
|
IdCtaContable = UsuarioActual.Empresa.IdCuentaIVATrasladado
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaIVATrasladado
|
|
||||||
If TCFluctuacion > 1 Then ConceptoMovimiento += $" TC:{TCFluctuacion} ${ImporteMovimiento.FormatoNumero(2)}"
|
If TCFluctuacion > 1 Then ConceptoMovimiento += $" TC:{TCFluctuacion} ${ImporteMovimiento.FormatoNumero(2)}"
|
||||||
|
|
||||||
Case 8 'RETIVA X TRASLADAR
|
Case 8 'RETIVA X TRASLADAR
|
||||||
@@ -928,14 +921,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'Conta SIG
|
|
||||||
If CveCuentaRetIVA <> 0 Then
|
|
||||||
CveCuenta = CveCuentaRetIVA
|
|
||||||
Else
|
|
||||||
If ObjConta.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then
|
|
||||||
CveCuenta = ObjConta.DtResultados.FiltroPrimeroValor("IdCuentaRetIVACirculacionSIG").ToEntero
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
Case 62 'RETIVA TRASLADADO
|
Case 62 'RETIVA TRASLADADO
|
||||||
If CveMonedaVenta = 1 Then
|
If CveMonedaVenta = 1 Then
|
||||||
ImporteMovimiento = RetIVAVenta * PorcentajePago
|
ImporteMovimiento = RetIVAVenta * PorcentajePago
|
||||||
@@ -961,14 +946,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'Conta SIG
|
|
||||||
If CveCuentaRetIVA <> 0 Then
|
|
||||||
CveCuenta = CveCuentaRetIVA
|
|
||||||
Else
|
|
||||||
If ObjConta.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then
|
|
||||||
CveCuenta = ObjConta.DtResultados.FiltroPrimeroValor("IdCuentaRetIVACirculacionSIG").ToEntero
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
Case 9 'RETISR X TRASLADAR
|
Case 9 'RETISR X TRASLADAR
|
||||||
If CveMonedaVenta = 1 Then
|
If CveMonedaVenta = 1 Then
|
||||||
@@ -995,14 +972,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'Conta SIG
|
|
||||||
If CveCuentaRetISR <> 0 Then
|
|
||||||
CveCuenta = CveCuentaRetISR
|
|
||||||
Else
|
|
||||||
If ObjConta.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then
|
|
||||||
CveCuenta = ObjConta.DtResultados.FiltroPrimeroValor("IdCuentaRetISRCirculacionSIG").ToEntero
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
Case 63 'RETISR TRASLADADO
|
Case 63 'RETISR TRASLADADO
|
||||||
If CveMonedaVenta = 1 Then
|
If CveMonedaVenta = 1 Then
|
||||||
@@ -1029,15 +998,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
'Conta SIG
|
|
||||||
If CveCuentaRetISR <> 0 Then
|
|
||||||
CveCuenta = CveCuentaRetISR
|
|
||||||
Else
|
|
||||||
If ObjConta.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then
|
|
||||||
CveCuenta = ObjConta.DtResultados.FiltroPrimeroValor("IdCuentaRetISRCirculacionSIG").ToEntero
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
|
|
||||||
Case 38 'IEPS X TRASLADAR
|
Case 38 'IEPS X TRASLADAR
|
||||||
If CveMonedaVenta = 1 Then
|
If CveMonedaVenta = 1 Then
|
||||||
ImporteMovimiento = IEPSVenta * PorcentajePago
|
ImporteMovimiento = IEPSVenta * PorcentajePago
|
||||||
@@ -1053,7 +1013,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
TCGeneral = TCVenta
|
TCGeneral = TCVenta
|
||||||
|
|
||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaIEPSxTrasladar
|
IdCtaContable = UsuarioActual.Empresa.IdCuentaIEPSxTrasladar
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaIEPSxTrasladar
|
|
||||||
If TCVenta > 1 Then ConceptoMovimiento += $" TC:{TCVenta} ${ImporteMovimiento.FormatoNumero(2)}"
|
If TCVenta > 1 Then ConceptoMovimiento += $" TC:{TCVenta} ${ImporteMovimiento.FormatoNumero(2)}"
|
||||||
|
|
||||||
Case 39 'IEPS TRASLADADO
|
Case 39 'IEPS TRASLADADO
|
||||||
@@ -1071,14 +1030,12 @@ Partial Class Ventas_PortalCliente
|
|||||||
TCGeneral = TCFluctuacion
|
TCGeneral = TCFluctuacion
|
||||||
|
|
||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaIEPSTrasladado
|
IdCtaContable = UsuarioActual.Empresa.IdCuentaIEPSTrasladado
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaIEPSTrasladado
|
|
||||||
If TCFluctuacion > 1 Then ConceptoMovimiento += $" TC:{TCFluctuacion} ${ImporteMovimiento.FormatoNumero(2)}"
|
If TCFluctuacion > 1 Then ConceptoMovimiento += $" TC:{TCFluctuacion} ${ImporteMovimiento.FormatoNumero(2)}"
|
||||||
|
|
||||||
Case 64 'GANANCIA
|
Case 64 'GANANCIA
|
||||||
Continue For 'SKIPEA
|
Continue For 'SKIPEA
|
||||||
If CveMonedaVenta <> 1 Then
|
If CveMonedaVenta <> 1 Then
|
||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaGananciaCambiaria
|
IdCtaContable = UsuarioActual.Empresa.IdCuentaGananciaCambiaria
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaGananciaCambiaria
|
|
||||||
If TCPago > TCVenta AndAlso CveMonedaVenta = 2 Then
|
If TCPago > TCVenta AndAlso CveMonedaVenta = 2 Then
|
||||||
ImporteMovimiento = (ImportePago * TCPago) - (ImportePago * TCVenta)
|
ImporteMovimiento = (ImportePago * TCPago) - (ImportePago * TCVenta)
|
||||||
ImporteMovimiento -= ((IVAVenta * PorcentajePago) * TCFluctuacion) - ((IVAVenta * PorcentajePago) * TCVenta)
|
ImporteMovimiento -= ((IVAVenta * PorcentajePago) * TCFluctuacion) - ((IVAVenta * PorcentajePago) * TCVenta)
|
||||||
@@ -1094,7 +1051,6 @@ Partial Class Ventas_PortalCliente
|
|||||||
Continue For 'SKIPEA
|
Continue For 'SKIPEA
|
||||||
If CveMonedaVenta <> 1 Then
|
If CveMonedaVenta <> 1 Then
|
||||||
IdCtaContable = UsuarioActual.Empresa.IdCuentaPerdidaCambiaria
|
IdCtaContable = UsuarioActual.Empresa.IdCuentaPerdidaCambiaria
|
||||||
CveCuenta = UsuarioActual.Empresa.CveCuentaPerdidaCambiaria
|
|
||||||
If TCPago < TCVenta AndAlso CveMonedaVenta = 2 Then
|
If TCPago < TCVenta AndAlso CveMonedaVenta = 2 Then
|
||||||
ImporteMovimiento = (ImportePago * TCPago) - (ImportePago * TCVenta)
|
ImporteMovimiento = (ImportePago * TCPago) - (ImportePago * TCVenta)
|
||||||
ImporteMovimiento -= ((IVAVenta * PorcentajePago) * TCFluctuacion) - ((IVAVenta * PorcentajePago) * TCVenta)
|
ImporteMovimiento -= ((IVAVenta * PorcentajePago) * TCFluctuacion) - ((IVAVenta * PorcentajePago) * TCVenta)
|
||||||
@@ -1110,7 +1066,7 @@ Partial Class Ventas_PortalCliente
|
|||||||
|
|
||||||
'AGREGA PREPOLIZA DETALLE
|
'AGREGA PREPOLIZA DETALLE
|
||||||
If ImporteMovimiento <> 0 Then
|
If ImporteMovimiento <> 0 Then
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, ImporteMovimiento, Referencia, ConceptoContable, ConceptoMovimiento, FechaMovimiento, IdCtaContable, -1, -1, CveVenta, -1, CveSubProyecto, CveCliente, CveProveedorContabilizar, ImporteMX:=importeMX, CveCuenta:=CveCuenta, TipoCambio:=TCGeneral, PorcentajeImpuesto:=PorcentajeImpuesto) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, ImporteMovimiento, Referencia, ConceptoContable, ConceptoMovimiento, FechaMovimiento, IdCtaContable, -1, -1, CveVenta, -1, CveSubProyecto, CveCliente, CveProveedorContabilizar, ImporteMX:=importeMX, TipoCambio:=TCGeneral, PorcentajeImpuesto:=PorcentajeImpuesto) Then
|
||||||
TieneError = True
|
TieneError = True
|
||||||
MensajeError.Append("No se pudo insertar el detalle de la póliza<br>")
|
MensajeError.Append("No se pudo insertar el detalle de la póliza<br>")
|
||||||
Exit For
|
Exit For
|
||||||
@@ -1954,7 +1910,7 @@ Partial Class Ventas_PortalCliente
|
|||||||
End Select
|
End Select
|
||||||
|
|
||||||
If importeMovimiento <> 0 Then
|
If importeMovimiento <> 0 Then
|
||||||
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento, Concepto, ConceptoContable, Concepto, FechaMovimiento, If(ConceptoContable = 30, ObjFactura.Cliente.IdCtaContClientes, ObjFactura.Cliente.IdCtaContAnticipos), -1, CveIE:=CveIE, CveCompra:=-1, CveProveedor:=-1, CvePersonal:=-1, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=importeMovimiento, ImporteME:=tImporteMonedaExtranjera, TipoCambio:=TxtTipoCambio.Text.ToDecimal, CveCuenta:=If(ConceptoContable = 30, ObjFactura.Cliente.CveCuentaClientes, ObjFactura.Cliente.CveCuentaAnticipos)) Then
|
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento, Concepto, ConceptoContable, Concepto, FechaMovimiento, If(ConceptoContable = 30, ObjFactura.Cliente.IdCtaContClientes, ObjFactura.Cliente.IdCtaContAnticipos), -1, CveIE:=CveIE, CveCompra:=-1, CveProveedor:=-1, CvePersonal:=-1, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=importeMovimiento, ImporteME:=tImporteMonedaExtranjera, TipoCambio:=TxtTipoCambio.Text.ToDecimal) Then
|
||||||
MsgError = "Ocurrió un error al registrar el asiento del ingreso."
|
MsgError = "Ocurrió un error al registrar el asiento del ingreso."
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|||||||
Reference in New Issue
Block a user