This commit is contained in:
Oscar Irigoyen
2022-09-20 12:07:13 -07:00
3 changed files with 10 additions and 16 deletions

View File

@@ -10101,7 +10101,7 @@ Public Class ClsPaginas
'concepto pago 'concepto pago
Concepto = String.Format("{0} NC:{1}", VentaActual.ClienteNombre, Pago.Referencia) Concepto = String.Format("{0} NC:{1}", VentaActual.ClienteNombre, Pago.Referencia)
If Pago.TipoPago = "A" AndAlso Not ErrorMovtos Then 'A N T I C I P O If Pago.TipoPago = "A" AndAlso Not ErrorMovtos Then ' A N T I C I P O
Dim Ret As New ConceptosRetenciones Dim Ret As New ConceptosRetenciones
If Pago.CveMonedaPago > 1 Then If Pago.CveMonedaPago > 1 Then
'Agregamos la Extranjera 'Agregamos la Extranjera
@@ -10117,14 +10117,14 @@ Public Class ClsPaginas
End If End If
If Pago.TipoPago = "NC" AndAlso Not ErrorMovtos Then ' N O T A D E C R E D I T O If Pago.TipoPago = "NC" AndAlso Not ErrorMovtos Then ' N O T A D E C R E D I T O
Dim Ret As New ConceptosRetenciones Dim Ret As New ConceptosRetenciones
If Pago.CveMonedaPago > 1 Then If Pago.CveMonedaPago > 1 Then
'Agregamos la Extranjera 'Agregamos la Extranjera
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, Pago.ImportePago, Pago.ImportePago, 91, Pago.Referencia, Concepto, VentaActual.IdCtaContableCliente, CveVenta:=Pago.CveVentaAmortizacion, CveVentaAmortizacion:=VentaActual.CveVenta, CveCliente:=VentaActual.CveCliente, CveIE:=Pago.CveIE, ImporteME:=Pago.ImportePago, TipoCambio:=TCValuacionPago, CveSubProyecto:=VentaActual.CveSubProyecto) Then ErrorMovtos = True If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, Pago.ImportePago, Pago.ImportePago, 294, Pago.Referencia, Concepto, VentaActual.IdCtaContableCliente, CveVenta:=Pago.CveVentaAmortizacion, CveVentaAmortizacion:=VentaActual.CveVenta, CveCliente:=VentaActual.CveCliente, CveIE:=Pago.CveIE, ImporteME:=Pago.ImportePago, TipoCambio:=TCValuacionPago, CveSubProyecto:=VentaActual.CveSubProyecto) Then ErrorMovtos = True
ImporteMN = (Pago.ImportePago * TCValuacionPago - Pago.ImportePago).RoundSQL ImporteMN = (Pago.ImportePago * TCValuacionPago - Pago.ImportePago).RoundSQL
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, Pago.ImportePago, ImporteMN, 203, Pago.Referencia, Concepto, VentaActual.IdCtaContableClienteComplementaria, CveVenta:=Pago.CveVentaAmortizacion, CveVentaAmortizacion:=VentaActual.CveVenta, CveCliente:=VentaActual.CveCliente, CveIE:=Pago.CveIE, ImporteME:=Pago.ImportePago, TipoCambio:=TCValuacionPago, CveSubProyecto:=VentaActual.CveSubProyecto) Then ErrorMovtos = True If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, Pago.ImportePago, ImporteMN, 207, Pago.Referencia, Concepto, VentaActual.IdCtaContableClienteComplementaria, CveVenta:=Pago.CveVentaAmortizacion, CveVentaAmortizacion:=VentaActual.CveVenta, CveCliente:=VentaActual.CveCliente, CveIE:=Pago.CveIE, ImporteME:=Pago.ImportePago, TipoCambio:=TCValuacionPago, CveSubProyecto:=VentaActual.CveSubProyecto) Then ErrorMovtos = True
Else Else
'Agregamos Nacional 'Agregamos Nacional
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, Pago.ImportePago, Pago.ImportePago, 91, Pago.Referencia, Concepto, VentaActual.IdCtaContableCliente, CveVenta:=Pago.CveVentaAmortizacion, CveVentaAmortizacion:=VentaActual.CveVenta, CveCliente:=VentaActual.CveCliente, CveIE:=Pago.CveIE, CvePersonal:=Pago.CvePersonal) Then ErrorMovtos = True If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, Pago.ImportePago, Pago.ImportePago, 91, Pago.Referencia, Concepto, VentaActual.IdCtaContableCliente, CveVenta:=Pago.CveVentaAmortizacion, CveVentaAmortizacion:=VentaActual.CveVenta, CveCliente:=VentaActual.CveCliente, CveIE:=Pago.CveIE, CvePersonal:=Pago.CvePersonal) Then ErrorMovtos = True
@@ -10133,7 +10133,7 @@ Public Class ClsPaginas
End If End If
If Pago.TipoPago = "I" AndAlso Not ErrorMovtos Then 'I N G R E S O S X C O M P R O B A R If Pago.TipoPago = "I" AndAlso Not ErrorMovtos Then ' I N G R E S O S X C O M P R O B A R
Dim Ret As New ConceptosRetenciones Dim Ret As New ConceptosRetenciones
If UsuarioActual.Empresa.TipoContabilidad = 2 Then If UsuarioActual.Empresa.TipoContabilidad = 2 Then
If ObjConta.GetRetCuenta(66, UsuarioActual.CveEmpresa) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then Ret.IdCtaContableAcreditable = ObjConta.DtResultados.Rows(0)("IdCuentaIEPSAcreditable").ToString.ToEntero If ObjConta.GetRetCuenta(66, UsuarioActual.CveEmpresa) AndAlso ObjConta.DtResultados.Rows.Count > 0 Then Ret.IdCtaContableAcreditable = ObjConta.DtResultados.Rows(0)("IdCuentaIEPSAcreditable").ToString.ToEntero

View File

@@ -1812,32 +1812,24 @@ Partial Class Compras_Compras
Dim nodeconceptos As XmlNode = XMLDoc.SelectSingleNode(String.Format("//{0}:Conceptos", Prefijo), namespaces) Dim nodeconceptos As XmlNode = XMLDoc.SelectSingleNode(String.Format("//{0}:Conceptos", Prefijo), namespaces)
Xml.Append(Replace(Replace(Replace(Replace(nodeconceptos.OuterXml, "<cfdi:", "<"), "</cfdi:", "</"), "xmlns:cfdi=""http://www.sat.gob.mx/cfd/3""", ""), "xmlns:cfdi=""http://www.sat.gob.mx/cfd/4""", "")) Xml.Append(Replace(Replace(Replace(Replace(Replace(nodeconceptos.OuterXml, "<cfdi:", "<"), "</cfdi:", "</"), "xmlns:cfdi=""http://www.sat.gob.mx/cfd/3""", ""), "xmlns:cfdi=""http://www.sat.gob.mx/cfd/4""", ""), "&quot;", ""))
If ObjeFacturas.GetFacturasComparacionXML(Version, Xml.ToString, UsuarioActual.CveEmpresa) Then If ObjeFacturas.GetFacturasComparacionXML(Version, System.Web.HttpUtility.HtmlDecode(Xml.ToString).Replace(Chr(13), "").Replace(Chr(10), ""), UsuarioActual.CveEmpresa) Then
TmpDT = ObjeFacturas.DtResultados TmpDT = ObjeFacturas.DtResultados
TmpDT.Columns.Add("CveSATPSActualizado") TmpDT.Columns.Add("CveSATPSActualizado")
SubTotalConceptos = TmpDT.SUMD("Total").RoundSQL
'TmpDT.Columns.Add("RetIVAPorcentaje")
'TmpDT.Columns.Add("RetISRPorcentaje")
'TmpDT.Columns.Add("IEPSPSPorcentaje")
'TmpDT.Columns.Add("IEPSPSIVAPorcentaje")
SubTotalConceptos = Math.Round(TmpDT.SUM("Total"), 2).ToDecimal
AddPS2(False) AddPS2(False)
'VALIDA QUE EL XML SI VIENE CON EL CODIGO SAT 01010101 'VALIDA QUE EL XML SI VIENE CON EL CODIGO SAT 01010101
Dim ProductosCodigoSATNoPermitidos As New StringBuilder("") Dim ProductosCodigoSATNoPermitidos As New StringBuilder("")
For Each drr As DataRow In TmpDT.FiltraParametros("ClaveProdServ = '01010101'").Rows For Each drr As DataRow In TmpDT.FiltraParametros("ClaveProdServ = '01010101'").Rows
ProductosCodigoSATNoPermitidos.AppendFormat("{0}</br>", drr("PS")) ProductosCodigoSATNoPermitidos.AppendFormat("{0}</br>", drr("PS"))
Next Next
If ProductosCodigoSATNoPermitidos.ToString.Length > 0 Then If ProductosCodigoSATNoPermitidos.ToString.Length > 0 Then
Dim mensajeAdvertencia As String = String.Format("El comprobante contiene productos con código SAT '01010101', revise los productos:</br></br>{0}", ProductosCodigoSATNoPermitidos.ToString) Dim mensajeAdvertencia As String = String.Format("El comprobante contiene productos con código SAT '01010101', revise los productos:</br></br>{0}", ProductosCodigoSATNoPermitidos.ToString)
Alert(mensajeAdvertencia, TipoMensaje.MsgAdvertencia) Alert(mensajeAdvertencia, TipoMensaje.MsgAdvertencia)
End If End If
End If End If
@@ -7645,6 +7637,7 @@ Partial Class Compras_Compras
Pago.CveMonedaPago = 1 Pago.CveMonedaPago = 1
Pago.CveCompraAmortizacion = CveCompraNC Pago.CveCompraAmortizacion = CveCompraNC
Pago.CveConceptoPago = CveConceptoPago Pago.CveConceptoPago = CveConceptoPago
Pago.AplicaAcreditable = If(Ant.TipoMovto.Contiene("NC", "DEV"), False, True) 'SI ES NC, no se acredita
ErrorMovtosCxP = AplicaPrePolizaPagoCompra(CompraActual, Pago, CvePrePoliza, ObjConta) ErrorMovtosCxP = AplicaPrePolizaPagoCompra(CompraActual, Pago, CvePrePoliza, ObjConta)

View File

@@ -2428,6 +2428,7 @@ Partial Class Inventarios_TraspasoAlmacen
TxtCodigoPSRecepcion.Text = "" TxtCodigoPSRecepcion.Text = ""
TdSeriePSRecepcion.Visible = False TdSeriePSRecepcion.Visible = False
TxtSeriePSRecepcion.Text = "" TxtSeriePSRecepcion.Text = ""
TxtCodigoPSRecepcion.Focus()
UpDatosRecepcion.Update() UpDatosRecepcion.Update()
Exit Sub Exit Sub
End If End If