This commit is contained in:
HECTOR RODRIGUEZ
2021-06-28 12:16:01 -07:00
26 changed files with 1411 additions and 269 deletions

View File

@@ -1183,7 +1183,7 @@
<asp:CompareValidator ID="CVFechaCancelacionMin" runat="server" ControlToCompare="TxtFechaDocumento" ControlToValidate="TxtFechaCancelacion" Display="None" Operator="GreaterThanEqual" Type="Date" ValidationGroup="GrpCancelarIE" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Cancelación''</b>tiene que ser mayor o igual a la fecha del documento."></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaCancelacionMin" Width="350px"></ajax:ValidatorCalloutExtender>
<asp:RangeValidator ID="RVTxtFechaCancelacion" runat="server" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha de cancelacion debe ser apartir del dia 1 del siguiente mes" MaximumValue="9999/12/31" MinimumValue="1900/01/01" ControlToValidate="TxtFechaCancelacion" Type="Date" ValidationGroup="GrpGuardar"></asp:RangeValidator>
<asp:RangeValidator ID="RVTxtFechaCancelacion" runat="server" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b> <br/> La fecha de cancelacion debe ser apartir del dia 1 del siguiente mes" MaximumValue="9999/12/31" MinimumValue="1900/01/01" ControlToValidate="TxtFechaCancelacion" Type="Date" ValidationGroup="GrpCancelarIE"></asp:RangeValidator>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender7" runat="server" HighlightCssClass="vco" TargetControlID="RVTxtFechaCancelacion" Width="350px"></ajax:ValidatorCalloutExtender>
</div>

View File

@@ -2845,7 +2845,7 @@ Partial Class Bancos_IE
'Agregamos el IVA
If DivIvaIxC.Visible AndAlso TxtIvaIxC.Text.ToDecimal <> 0 Then
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, TxtIvaIxC.Text.ToDecimal, Concepto, 61, Concepto, FechaMovimiento, UsuarioActual.Empresa.IdCuentaIVAxTrasladar, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=TxtIvaIxC.Text.ToDecimal, ImporteME:=tImporteMonedaExtranjera, CveCuenta:=UsuarioActual.Empresa.CveCuentaIVAxTrasladar) Then
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, TxtIvaIxC.Text.ToDecimal, Concepto, 61, Concepto, FechaMovimiento, UsuarioActual.Empresa.IdCuentaIVAxTrasladar, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=TxtIvaIxC.Text.ToDecimal, ImporteME:=tImporteMonedaExtranjera) Then
MsgError = "Ocurrió un error al registrar el asiento del ingreso."
End If
End If
@@ -2853,7 +2853,7 @@ Partial Class Bancos_IE
'Agregamos complementaria
Dim TC As Decimal = TxtTipoCambio.Text.ToDecimal
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Concepto, 226, Concepto, FechaMovimiento, IDCtaBeneficiarioComplementaria, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=(importeMovimiento * TC - importeMovimiento).RoundSQL, ImporteME:=importeMovimiento, TipoCambio:=TC, CveCuenta:=0) Then
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Concepto, 226, Concepto, FechaMovimiento, IDCtaBeneficiarioComplementaria, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=(importeMovimiento * TC - importeMovimiento).RoundSQL, ImporteME:=importeMovimiento, TipoCambio:=TC) Then
MsgError = "Ocurrió un error al registrar el asiento del ingreso."
End If
@@ -2869,7 +2869,7 @@ Partial Class Bancos_IE
'Agregamos complementaria
Dim TC As Decimal = TxtTipoCambio.Text.ToDecimal
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Concepto, 204, Concepto, FechaMovimiento, IDCtaContableComplementaria, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=(importeMovimiento * TC - importeMovimiento).RoundSQL, ImporteME:=importeMovimiento, TipoCambio:=TC, CveCuenta:=UsuarioActual.Empresa.CveCuentaIVAxTrasladar) Then
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Concepto, 204, Concepto, FechaMovimiento, IDCtaContableComplementaria, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=(importeMovimiento * TC - importeMovimiento).RoundSQL, ImporteME:=importeMovimiento, TipoCambio:=TC) Then
MsgError = "Ocurrió un error al registrar el asiento del ingreso."
End If
Else
@@ -3561,7 +3561,7 @@ Partial Class Bancos_IE
'Agregamos complementaria
Dim TC As Decimal = TxtTipoCambio.Text.ToDecimal
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Concepto, 204, Concepto, FechaMovimiento, IDCtaContableComplementaria, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=(importeMovimiento * TC - importeMovimiento).RoundSQL, ImporteME:=importeMovimiento, TipoCambio:=TC, CveCuenta:=UsuarioActual.Empresa.CveCuentaIVAxTrasladar) Then
If Not ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, 0, Concepto, 204, Concepto, FechaMovimiento, IDCtaContableComplementaria, -1, CveIE:=CveIE, CveCompra:=CveCompra, CveProveedor:=CveProveedor, CvePersonal:=CvePersonal, CveCreditoDetalle:=CveCreditoDetalle, CveCliente:=CveCliente, ImporteMX:=(importeMovimiento * TC - importeMovimiento).RoundSQL, ImporteME:=importeMovimiento, TipoCambio:=TC) Then
MsgError = "Ocurrió un error al registrar el asiento del ingreso."
End If
End If
@@ -4339,8 +4339,15 @@ Partial Class Bancos_IE
Protected Sub BtnCancelarIE_Click(sender As Object, e As EventArgs)
RegistraScript("$('#DivCancelarIE').modal('hide');")
Dim ExistenComplementosVigentes As Boolean = VerificaComplementos(True)
If Not ExistenComplementosVigentes Then
CancelarIE()
Else
Alert("No se puede cancelar documento con complementos de pago vigentes", TipoMensaje.MsgError)
End If
CancelarIE()
End Sub
Private Sub CancelarIE(Optional CancelarComplemento As Boolean = False)
@@ -4350,8 +4357,8 @@ Partial Class Bancos_IE
Exit Sub
End If
If ChkConciliado.Checked Then
Alert("El documento seleccionado no se puede eliminar porque se encuentra conciliado.", TipoMensaje.MsgError)
If ChkConciliado.Checked AndAlso TxtFechaCancelacion.Text.ToDate < TxtFechaAplicado.Text.ToDate.FirstDayOfMonth.AddMonths(1) Then
Alert("El documento conciliado, no se puede cancelar con la fecha especificada.", TipoMensaje.MsgError)
Exit Sub
End If
@@ -5973,7 +5980,7 @@ Partial Class Bancos_IE
'TxtFechaDesconciliado.Text = Now.ToShortDateString
'UpDesconciliar.Update()
'RegistraScript("$('#DModalDesconciliar').modal()")
Dim fechaCancelacion As String = DateTime.Now.AddMonths(1).FirstDayOfMonth.ToShortDateString
Dim fechaCancelacion As String = TxtFechaAplicado.Text.ToDate.AddMonths(1).FirstDayOfMonth.ToShortDateString
RVTxtFechaCancelacion.MinimumValue = fechaCancelacion
CalendarioCancelacion.StartDate = fechaCancelacion.ToDate
UpEliminarCotizacion.Update()
@@ -6451,13 +6458,12 @@ Partial Class Bancos_IE
Protected Sub LnkCancelarComplemetno_Click(sender As Object, e As EventArgs)
If ChkConciliado.Checked Then
Alert("El documento seleccionado no se puede eliminar porque se encuentra conciliado.", TipoMensaje.MsgAdvertencia)
Alert("El documento se encuentra conciliado, no se puede cancelar.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).BindingContainer, GridViewRow)
CveComplementoPagoCancelar = GvRow.DataKey("CveComplementoPago").ToEntero
FolioFiscalCancelar = GvRow.DataKey("FolioFiscal").ToString
'' Dim RFCEmisor As String = UsuarioActual.Empresa.RFC
@@ -6467,8 +6473,6 @@ Partial Class Bancos_IE
Dim ObjCancelacion As New Timbrado
Dim ObjBanco As New ClsBancos
If EstatusSATCancelado(FolioFiscalCancelar, UsuarioActual.Empresa.RFC, RFCReceptorCancelar) Then
If ObjBanco.UpdateComplementoPago(CveComplementoPagoCancelar, "-1", -1, UsuarioActual.CveEmpresa, 2, CvePACCancelacion, FechaCancelacion:=Date.Now, SelloCancelacion:="") Then

View File

@@ -1538,7 +1538,6 @@ Partial Class Bancos_PopIECompras
Dim ImporteMovimientoNoDeducible As Decimal = 0
Dim ImporteMXNoDeducible As Decimal = 0
Dim IdCtaContable As Integer = 0
Dim CveCuenta As Integer = 0
Dim ConceptoMovimiento = ObjMov.ObtenerConceptoEmpresa(UsuarioActual.CveEmpresa, ConceptoContable, NombreProveedor, TxtObservaciones.Text, TxtFolio.Text.Trim)
Dim FuncionalidadFluctuacionImpuestos As Boolean = If(UsuarioActual.Empresa.Funcionalidad(159) = "1", True, False)
Dim TimpocambioGeneral As Decimal = 1
@@ -1899,8 +1898,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.RetIVA * PorcentajePago)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -1932,8 +1931,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.RetIVA * PorcentajePago)
ImporteMX = ImporteMovimiento * tipoCambioCompra
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = tipoCambioCompra
If tipoCambioCompra > 1 Then ConceptoMovimiento += $" TC:{tipoCambioCompra} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -1966,8 +1965,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.RetIVA * PorcentajePago)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2000,8 +1999,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.RetIVA * PorcentajePago)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2033,9 +2032,9 @@ Partial Class Bancos_PopIECompras
ElseIf CveMoneda = 2 AndAlso CveMonedaCompra = 2 Then
ImporteMovimiento = (MovimientoPagar.RetIVA * PorcentajePago)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
End If
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2069,8 +2068,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.RetIVA * PorcentajePago)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2103,8 +2102,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.RetIVA * PorcentajePago)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2156,17 +2155,7 @@ Partial Class Bancos_PopIECompras
' End If
' End If
' 'Conta SIG
' If CveCuentaRetISR <> 0 Then
' CveCuenta = CveCuentaRetISR
' Else
' If ImporteMovimiento <> 0 AndAlso ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) Then
' If ObjMov.DtResultados.Rows.Count > 0 Then
' CveCuenta = ObjMov.DtResultados.Rows(0)("IdCuentaRetISRCirculacionSIG").ToString.ToEntero
' End If
' End If
' End If
' End If
'Case 23 'Ret ISR Acreditable
' If MovimientoPagar.ConceptoRetISR = 1 Then
' If CveMoneda = 1 AndAlso CveMonedaCompra = 1 Then
@@ -2201,16 +2190,6 @@ Partial Class Bancos_PopIECompras
' End If
' End If
' 'Conta SIG
' If CveCuentaRetISR <> 0 Then
' CveCuenta = CveCuentaRetISR
' Else
' If ImporteMovimiento <> 0 AndAlso ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) Then
' If ObjMov.DtResultados.Rows.Count > 0 Then
' CveCuenta = ObjMov.DtResultados.Rows(0)("IdCuentaRetISRCirculacionSIG").ToString.ToEntero
' End If
' End If
' End If
' End If
'Case 243 'Ret ISR X Acreditar Terceros y Arrendamiento
' If MovimientoPagar.ConceptoRetISR = 2 Then
@@ -2246,16 +2225,7 @@ Partial Class Bancos_PopIECompras
' End If
' End If
' 'Conta SIG
' If CveCuentaRetISR <> 0 Then
' CveCuenta = CveCuentaRetISR
' Else
' If ImporteMovimiento <> 0 AndAlso ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) Then
' If ObjMov.DtResultados.Rows.Count > 0 Then
' CveCuenta = ObjMov.DtResultados.Rows(0)("IdCuentaRetISRCirculacionSIG").ToString.ToEntero
' End If
' End If
' End If
' End If
'Case 244 'Ret ISR Acreditable Terceros y Arrendamiento
' If MovimientoPagar.ConceptoRetISR = 2 Then
@@ -2291,16 +2261,7 @@ Partial Class Bancos_PopIECompras
' End If
' End If
' 'Conta SIG
' If CveCuentaRetISR <> 0 Then
' CveCuenta = CveCuentaRetISR
' Else
' If ImporteMovimiento <> 0 AndAlso ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) Then
' If ObjMov.DtResultados.Rows.Count > 0 Then
' CveCuenta = ObjMov.DtResultados.Rows(0)("IdCuentaRetISRCirculacionSIG").ToString.ToEntero
' End If
' End If
' End If
' End If
Case 14 'Iva por Acreditar
If UsuarioActual.Empresa.Funcionalidad(521) = "1" Then
@@ -2331,8 +2292,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = MovimientoPagar.IVA
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = tipoCambioCompra
If tipoCambioCompra > 1 Then ConceptoMovimiento += $" TC:{tipoCambioCompra} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2355,8 +2316,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.IVAPorPagar * PorcentajePago)
ImporteMX = ImporteMovimiento * tipoCambioCompra
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioCompra > 1 Then ConceptoMovimiento += $" TC:{tipoCambioCompra} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2409,8 +2370,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.IVADeducible)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2433,8 +2394,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.IVADeducible * PorcentajePago)
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioPago > 1 Then ConceptoMovimiento += $" TC:{tipoCambioPago} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2517,7 +2478,6 @@ Partial Class Bancos_PopIECompras
If ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) And Not IdCtaContable > 0 Then
If ObjMov.DtResultados.Rows.Count > 0 Then
IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCuentaIVAAcreditable").ToString.ToEntero
CveCuenta = ObjMov.DtResultados.Rows(0)("IdCuentaIVAAcreditableSIG").ToString.ToEntero
End If
End If
@@ -2559,8 +2519,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = MovimientoPagar.IVA
ImporteMX = ImporteMovimiento * If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = tipoCambioCompra
If tipoCambioCompra > 1 Then ConceptoMovimiento += $" TC:{tipoCambioCompra} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2582,8 +2542,8 @@ Partial Class Bancos_PopIECompras
ImporteMovimiento = (MovimientoPagar.IVA * PorcentajePago)
ImporteMX = ImporteMovimiento * tipoCambioCompra
End If
ImporteMovimiento = Math.Round(ImporteMovimiento, 2)
ImporteMX = Math.Round(ImporteMX, 2)
ImporteMovimiento = ImporteMovimiento.RoundSQL
ImporteMX = ImporteMX.RoundSQL
TimpocambioGeneral = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
If tipoCambioCompra > 1 Then ConceptoMovimiento += $" TC:{tipoCambioCompra} ${ImporteMovimiento.FormatoNumero(2)}"
@@ -2603,7 +2563,6 @@ Partial Class Bancos_PopIECompras
If ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) And Not IdCtaContable > 0 Then
If ObjMov.DtResultados.Rows.Count > 0 Then
IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCtaContable").ToString.ToEntero
CveCuenta = ObjMov.DtResultados.Rows(0)("IdCtaContableSIG").ToString.ToEntero
End If
End If
@@ -2745,7 +2704,6 @@ Partial Class Bancos_PopIECompras
If ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) And Not IdCtaContable > 0 Then
If ObjMov.DtResultados.Rows.Count > 0 Then
IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCtaContable").ToString.ToEntero
CveCuenta = ObjMov.DtResultados.Rows(0)("IdCtaContableSIG").ToString.ToEntero
End If
End If
@@ -2828,7 +2786,6 @@ Partial Class Bancos_PopIECompras
' If ObjMov.GetRetCuenta(ConceptoContable, UsuarioActual.CveEmpresa) And Not IdCtaContable > 0 Then
' If ObjMov.DtResultados.Rows.Count > 0 Then
' IdCtaContable = ObjMov.DtResultados.Rows(0)("IdCuentaIVAAcreditable").ToString.ToEntero
' CveCuenta = ObjMov.DtResultados.Rows(0)("IdCuentaIVAAcreditableSIG").ToString.ToEntero
' End If
' End If
Case 25 'IEPS por Acreditar
@@ -2888,7 +2845,6 @@ Partial Class Bancos_PopIECompras
If CveMoneda <> 1 OrElse CveMonedaCompra <> 1 Then
IdCtaContable = UsuarioActual.Empresa.IdCuentaGananciaCambiaria
CveCuenta = UsuarioActual.Empresa.CveCuentaGananciaCambiaria
Dim TCImpuestos As Decimal = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
TimpocambioGeneral = TCImpuestos
'' si tiene funcionalidad de flucturación con ivas, tomar tipocambioCompra
@@ -2914,7 +2870,6 @@ Partial Class Bancos_PopIECompras
If CveMoneda <> 1 OrElse CveMonedaCompra <> 1 Then
IdCtaContable = UsuarioActual.Empresa.IdCuentaPerdidaCambiaria
CveCuenta = UsuarioActual.Empresa.CveCuentaPerdidaCambiaria
Dim TCImpuestos As Decimal = If(FuncionalidadFluctuacionImpuestos, tipoCambioPago, tipoCambioCompra)
'' si tiene funcionalidad de flucturación con ivas, tomar tipocambioCompra
If tipoCambioPago > tipoCambioCompra AndAlso CveMonedaCompra = 2 Then