From a5f4ae70370fa2ec9d83fbe847c54bc45a6ca7e9 Mon Sep 17 00:00:00 2001 From: rrene Date: Tue, 4 Apr 2023 18:16:36 -0700 Subject: [PATCH 01/22] -- --- Compras/Compras.aspx | 2 +- Compras/Compras.aspx.vb | 41 ++++++++++++++++------------------------- 2 files changed, 17 insertions(+), 26 deletions(-) diff --git a/Compras/Compras.aspx b/Compras/Compras.aspx index eb51750c3..0bbd993fd 100644 --- a/Compras/Compras.aspx +++ b/Compras/Compras.aspx @@ -4845,7 +4845,7 @@
+ DataKeyNames="CveCompra,TipoCambio,CveTipoConcepto,UUID,Saldo,SerieFolio,Fecha,CveMoneda" runat="server" AutoGenerateColumns="false" GridLines="None" CssClass="table table-striped table-hover Widthall ScrollAD"> diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb index 30294692a..a77b0224f 100644 --- a/Compras/Compras.aspx.vb +++ b/Compras/Compras.aspx.vb @@ -3587,7 +3587,7 @@ Partial Class Compras_Compras Dim CalRetIVAPor As Decimal = (RetIVAOriginal * 1 / SubTotal2Original).RoundAD(6).ToDecimal If (CalRetIVAPor).RoundSQL(6) = 0.106667 OrElse (CalRetIVAPor).RoundSQL(6) = 0.053333 Then - DdlRetIVAConcepto.SelectedValueExist("1") '10.66 servicios profecionales + DdlRetIVAConcepto.SelectedValueExist("1") '10.66 servicios profesionales End If If (CalRetIVAPor).RoundSQL(2) = 0.04 Then '4 Fletes @@ -3608,8 +3608,8 @@ Partial Class Compras_Compras If (CalRetISRPor).RoundSQL(1) = 0.1 Then '10 Servicios profesionales DdlRetISRConcepto.SelectedValueExist("1") End If - - If (CalRetISRPor).RoundSQL(4) = 0.0125 Then '1.25 Recico regimen simplificado confianza + 'permitido en un margen de 1% a 2% + If (CalRetISRPor).RoundSQL(4) = 0.0125 OrElse (CalRetISRPor >= 0.01 AndAlso CalRetISRPor <= 0.02) Then '1.25 Recico regimen simplificado confianza DdlRetISRConcepto.SelectedValueExist("3") End If @@ -3962,12 +3962,6 @@ Partial Class Compras_Compras End If End If - - 'PARA GLUYAS - If UsuarioActual.CveEmpresa = 66 Then - tPSCodigo = String.Format("{1} - {0}", ValorXML(node, "descripcion").ToUpper.Trim.Replace(vbCrLf, " ").Replace(vbLf, " ").Replace("'", "''"), ValorXML(node, "noIdentificacion").Trim) - End If - 'Alert(ValorXML(node, "ClaveProdServ").Trim) If Version = "3.3" Or Version = "4.0" Then @@ -4992,7 +4986,7 @@ Partial Class Compras_Compras CompraActual.PorcentajeIVA = PorcentajeIVA CompraActual.UsuarioActual = UsuarioActual CompraActual.CveSubProyecto = TmpDT.FiltroPrimeroValor("CveSubProyecto", " CveSubProyecto > 0").ToEntero - CompraActual.IdCtaContableProv = CtaProveedor + CompraActual.IdCtaContableProv = If(CompraActual.CveMoneda = 1, CtaProveedor, CtaProveedorExtranjera) CompraActual.IdCtaContableProvComplementaria = CtaProveedorComplementaria CompraActual.EsImportacion = chkImportacion.Checked @@ -7205,29 +7199,26 @@ Partial Class Compras_Compras 'AMORTIZACIÓN EN EL REGISTRO For Each Gvr As GridViewRow In GvFacturaNC.Rows If Gvr.FCCheckBox("ChkFacturaNC").Checked Then - 'Dim CvePrePolizaTemp = ObjConta.AddPrePolizas("Compras/Registrar-NC", If(EsContado And CvePlantillaPrePoliza = 1, 2, CvePlantillaPrePoliza), ImporteCompra, TxtTotal.Text.ToDouble, DdlMoneda.SelectedValue.ToEntero, TxtFecha.Text.ToDate, ConceptoPoliza, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, FolioFijo:=FolioFijo, ReglaFolioPoliza:=ObjCompras.ObtenerReglaFolio(DdlTipoTransaccion.SelectedValue, DdlTipoTransaccionCaja.SelectedValue, UsuarioActual.CveEmpresa), CveTipoPoliza:=ObjConta.ObtenerTipoPoliza(DdlTipoTransaccion.SelectedValue, DdlTipoTransaccionCaja.SelectedValue, UsuarioActual.CveEmpresa)) Dim importeMovimientoNC = Gvr.FCTextBox("TxtImporte").Text.ToDecimal - Dim TipoCambioFactura = Gvr.DataKey("TipoCambio").ToDecimal ' RMF. falta aplicar si está generada su TC de la última fluctuación - Dim importeMNNC = importeMovimientoNC * TipoCambioFactura * Multiplicador - Dim CveMonedaNC As Integer = If(TipoCambioFactura = 1, 1, 2) - - IdCtaContable = CtaProveedorExtranjera - 'CveCon = ObtConceptoContableProvisionCompra(Gvr.DataKey("CveTipoConcepto").ToEntero, "NC", CveMonedaNC, False) - - CompraActual.CveCompra = Gvr.DataKey("CveCompra").ToEntero - CompraActual.SerieFolio = Gvr.DataKey("SerieFolio") Dim Pago As New CompraPago Pago.ImportePago = importeMovimientoNC - Pago.CveMonedaPago = CveMonedaNC - Pago.CveCompraAmortizacion = CveCompra - Pago.CveConceptoPago = 272 + Pago.CveMonedaPago = CompraActual.CveMoneda + Pago.CveCompraAmortizacion = CompraActual.CveCompra Pago.Referencia = CompraActual.SerieFolio - Pago.TCPago = TipoCambioFactura + Pago.TCPago = CompraActual.TC Pago.AplicaAcreditable = False Pago.TipoPago = "NC" + Pago.Fecha = CompraActual.Fecha 'toma la misma fecha de la provisión en el pago de NC - ErrorMovtosCxP = AplicaPrePolizaPagoCompra(CompraActual, Pago, CvePrePoliza, ObjConta) + 'datos de la compra tipodocto:Fac, para sobreescribirlos + CompraActual.CveCompra = Gvr.DataKey("CveCompra").ToEntero + CompraActual.SerieFolio = Gvr.DataKey("SerieFolio") + CompraActual.TC = Gvr.DataKey("TipoCambio").ToDecimal + CompraActual.Fecha = Gvr.DataKey("Fecha").ToDate + CompraActual.CveMoneda = Gvr.DataKey("CveMoneda").ToEntero + + ErrorPrepoliza = AplicaPrePolizaPagoCompra(CompraActual, Pago, CvePrePoliza, ObjConta) End If Next From 5578e2ff913ced4ad04aa2bbd893ee7c9f8c82af Mon Sep 17 00:00:00 2001 From: rrene Date: Tue, 4 Apr 2023 18:17:03 -0700 Subject: [PATCH 02/22] -- mejora --- Contabilidad/RegPrePolizaS.aspx.vb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Contabilidad/RegPrePolizaS.aspx.vb b/Contabilidad/RegPrePolizaS.aspx.vb index 49bfae125..a55b9af04 100644 --- a/Contabilidad/RegPrePolizaS.aspx.vb +++ b/Contabilidad/RegPrePolizaS.aspx.vb @@ -1631,7 +1631,7 @@ Partial Class ContabilidadC_RegPrePolizaS DdlProveedoresE.Items.Insert(0, New ListItem(" - ", "-1")) End Sub Private Sub CargaComprasE(CveProveedor As Integer) - If DdlConceptosContables.SelectedValue.ToEntero.Contiene(5, 17, 305, 308, 310, 311, 312) Then + If DdlConceptosContablesE.SelectedValue.ToEntero.Contiene(5, 17, 305, 308, 310, 311, 312) Then Dim ObjCompras As New ClsCompras DdlComprasE.ClearSelection() From 165d9e223f9f998480638d512ffd4c6523f74bf5 Mon Sep 17 00:00:00 2001 From: rrene Date: Tue, 4 Apr 2023 18:17:21 -0700 Subject: [PATCH 03/22] -- comentado de prueba --- OC/CatEstatus.aspx.vb | 99 +++++++++++++++++++++---------------------- 1 file changed, 49 insertions(+), 50 deletions(-) diff --git a/OC/CatEstatus.aspx.vb b/OC/CatEstatus.aspx.vb index 31793a760..065901693 100644 --- a/OC/CatEstatus.aspx.vb +++ b/OC/CatEstatus.aspx.vb @@ -71,7 +71,6 @@ Partial Class OC_CatEstatus CargaEstatus() CargarCentrosDeCosto(DdlProyecto, DdlSubProyecto, LblProyecto, LblSubProyecto, divProyecto:=DivProyecto) CargaUsuarios() - sssss() 'SOLO MUESTRA SUBPROYECTO @@ -89,55 +88,55 @@ Partial Class OC_CatEstatus End If End Sub - Private Sub sssss() - Dim length = 200000 - Dim concatString = "" - Dim aaa As New StringBuilder - Dim stopWatch = New Stopwatch() - stopWatch.Start() - - For i As Integer = 0 To length - 1 - concatString = concatString & i - Next - - stopWatch.[Stop]() - aaa.Append($"String Concat took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") - stopWatch.Reset() - concatString = String.Empty - stopWatch.Start() - - For i As Integer = 0 To length - 1 - concatString = $"{concatString}a" - Next - - stopWatch.[Stop]() - aaa.Append($"String Interpolation took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") - stopWatch.Reset() - concatString = String.Empty - Dim stringBuilder = New StringBuilder() - stopWatch.Start() - - For i As Integer = 0 To length - 1 - stringBuilder.Append("a") - Next - - concatString = stringBuilder.ToString() - stopWatch.[Stop]() - aaa.Append($"String Builder took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") - stopWatch.Reset() - concatString = String.Empty - - stopWatch.Start() - - For i As Integer = 0 To length - 1 - concatString = String.Format("a{0}", i) - Next - - stopWatch.[Stop]() - aaa.Append($"String.Format took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") - Alert(aaa.ToString) - - End Sub + 'Private Sub sssss() + ' Dim length = 200000 + ' Dim concatString = "" + ' Dim aaa As New StringBuilder + ' Dim stopWatch = New Stopwatch() + ' stopWatch.Start() + + ' For i As Integer = 0 To length - 1 + ' concatString = concatString & i + ' Next + + ' stopWatch.[Stop]() + ' aaa.Append($"String Concat took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") + ' stopWatch.Reset() + ' concatString = String.Empty + ' stopWatch.Start() + + ' For i As Integer = 0 To length - 1 + ' concatString = $"{concatString}a" + ' Next + + ' stopWatch.[Stop]() + ' aaa.Append($"String Interpolation took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") + ' stopWatch.Reset() + ' concatString = String.Empty + ' Dim stringBuilder = New StringBuilder() + ' stopWatch.Start() + + ' For i As Integer = 0 To length - 1 + ' stringBuilder.Append("a") + ' Next + + ' concatString = stringBuilder.ToString() + ' stopWatch.[Stop]() + ' aaa.Append($"String Builder took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") + ' stopWatch.Reset() + ' concatString = String.Empty + + ' stopWatch.Start() + + ' For i As Integer = 0 To length - 1 + ' concatString = String.Format("a{0}", i) + ' Next + + ' stopWatch.[Stop]() + ' aaa.Append($"String.Format took: {stopWatch.ElapsedMilliseconds} ms, for {length} iterations.
") + ' Alert(aaa.ToString) + + 'End Sub #Region "C A T A L O G O " Public Sub CargaDatos() From 2b1afcddd27ce2c86272d27f596f6d2b8ebb4c4a Mon Sep 17 00:00:00 2001 From: rrene Date: Tue, 4 Apr 2023 18:19:02 -0700 Subject: [PATCH 04/22] =?UTF-8?q?--=20activar=20la=20direcci=C3=B3n=20de?= =?UTF-8?q?=20env=C3=ADo,=20en=20base=20a=20funcionalidad=20161?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Ventas/Ventas.aspx.vb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Ventas/Ventas.aspx.vb b/Ventas/Ventas.aspx.vb index 4ba9f331e..f558af84c 100644 --- a/Ventas/Ventas.aspx.vb +++ b/Ventas/Ventas.aspx.vb @@ -6488,7 +6488,7 @@ Partial Class Ventas End If 'HABILITA LA OPCION DE DIRECCION DE ENVIO - If UsuarioActual.CveEmpresa.Contiene(1, 72, 119, 140) Then + If UsuarioActual.CveEmpresa.Contiene(1, 72, 119, 140, 172, 173, 174) OrElse UsuarioActual.Empresa.Funcionalidad(161) = "1" Then ' si tiene FNC:161, habilita carta porte trDireccionEnvio.Visible = True CargaDireccionesEnvio() End If From e391048b1b2a3da40eb51ad841ad8443fc6d9a3e Mon Sep 17 00:00:00 2001 From: rrene Date: Tue, 4 Apr 2023 18:19:21 -0700 Subject: [PATCH 05/22] - --- Contabilidad2/RepBalanzaComprobacion.aspx.vb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Contabilidad2/RepBalanzaComprobacion.aspx.vb b/Contabilidad2/RepBalanzaComprobacion.aspx.vb index cf275bff4..20c0bced9 100644 --- a/Contabilidad2/RepBalanzaComprobacion.aspx.vb +++ b/Contabilidad2/RepBalanzaComprobacion.aspx.vb @@ -76,9 +76,9 @@ Partial Class Contabilidad2_RepBalanzaComprobacion Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load If Not Page.IsPostBack Then - If UsuarioActual.Empresa.TipoContabilidad = 2 Then - Response.Redirect($"/Contabilidad/RepBalanzaComprobacion.aspx") - End If + 'If UsuarioActual.Empresa.TipoContabilidad = 2 Then + ' Response.Redirect($"/Contabilidad/RepBalanzaComprobacion.aspx") + 'End If Dim ErrorParametros = True ModoImpresion = False From e0aca9cb7e99d6ebb22fd75ec52886a202d34337 Mon Sep 17 00:00:00 2001 From: Jonathan Alexis Perez Morales Date: Tue, 4 Apr 2023 20:13:19 -0700 Subject: [PATCH 06/22] --Vinculacion de intermediarios --- Bancos/IE.aspx.vb | 5 + Ventas/ClientesAbonar.aspx | 287 +++++++++++++++++++++------------- Ventas/ClientesAbonar.aspx.vb | 2 + 3 files changed, 181 insertions(+), 113 deletions(-) diff --git a/Bancos/IE.aspx.vb b/Bancos/IE.aspx.vb index 28d3c6bbc..d887529d1 100644 --- a/Bancos/IE.aspx.vb +++ b/Bancos/IE.aspx.vb @@ -955,6 +955,11 @@ Partial Class Bancos_IE LnkChqDevuelto.Visible = True End If + If Not String.IsNullOrEmpty(ObjIE.DtResultados.Rows(0)("ProveedorIntermediario").ToString) Then + DivIntermediario.Visible = True + LtlIntermediarioTexto.Text = ObjIE.DtResultados.Rows(0)("ProveedorIntermediario").ToString + End If + 'saco el tipo de transaccion Dim dr As DataRow = GlobalDTTipoTransacciones.FiltroPrimero(String.Format("CveTipoTransaccion = {0}", ObjIE.CveTipoTransaccion)) 'Egs o Ing If dr IsNot Nothing Then diff --git a/Ventas/ClientesAbonar.aspx b/Ventas/ClientesAbonar.aspx index ba7d5e7fc..2b2d946f5 100644 --- a/Ventas/ClientesAbonar.aspx +++ b/Ventas/ClientesAbonar.aspx @@ -15,9 +15,9 @@
  • Saldar Cuentas Incobrables
  • -
  • + <%--
  • Vincular Intermediario -
  • + --%>
  • Cargar Layout @@ -42,7 +42,7 @@
    -
    +
    Banco   @@ -114,7 +114,7 @@
    - +
    T.C: @@ -190,43 +190,43 @@
    -
    Otros Ingresos:
    -
    +
    Otros Ingresos:
    +
    -
    Liquidación:
    -
    +
    Liquidación:
    +
    - + - +
    -
    -
    Anticipo:
    +
    +
    Anticipo:
    - +
    -
    -
    - +
    +
    -
    -
    Préstamo:
    +
    +
    Préstamo:
    -
    - -
    -
    Intereses: +
    + +
    +
    + Intereses:
    @@ -256,8 +256,39 @@
    -
    - +
    +
    + +
    +
    +
    +
    +
    +
    +
    +
    + Vinculación de intermediarios + +
    +
    +
    +
    +
    +
    +
    +
    +
    + + A Cuenta de terceros: +
    +
    + +
    +
    +
    +
    +
    @@ -269,7 +300,7 @@
    - +
    -
    @@ -279,19 +310,19 @@
    + - " style="display: inline-block; margin-right: -20px; width: 125px;" /> - " style="margin-top: -3px; margin-right: 20px" class="btn btn-circle btn-sm label-info"> - + " style="display: inline-block; margin-right: -20px; width: 125px;" /> + " style="margin-top: -3px; margin-right: 20px" class="btn btn-circle btn-sm label-info"> +
    - + @@ -299,7 +330,7 @@ DataKeyNames="TipoDocto,CveVenta,CveCliente,SerieFolio,Original,SubTotal,IVA,IEPS,RetIVA,RetISR,Num3,CveSubProyecto,CveMoneda,Saldo,TipoCambio, RFC,UUID,Fecha,PorcentajeIVA,DescuentoProntoPago,CveTipoRetencion,Descuento,ClaveMetodoPagoSAT" CssClass="table table-striped table-advance table-hover Widthall" Style="text-align: center;" GridLines="None" HeaderStyle-CssClass="ADtr"> - + <%--0--%> @@ -318,55 +349,78 @@ <%--2--%> - Tipo
    Docto
    + + Tipo
    + Docto +
    -
    + <%--3--%> - Fecha
    Venta
    + + Fecha
    + Venta +
    <%--4--%> - Fecha
    Vencimiento
    + + Fecha +
    + Vencimiento +
    <%--5--%> - Días
    Vencidos
    + + Días
    + Vencidos +
    <%--6--%> - Método
    de Pago
    + + Método
    + de Pago +
    <%--7--%> - Forma
    de Pago
    + + Forma
    + de Pago +
    -
    + <%--8--%> - Monto
    Venta
    + + Monto +
    + Venta +
     
    <%--9--%> - +   @@ -404,82 +458,88 @@ <%--14--%> - Descuento
    Pronto Pago
    + + Descuento
    + Pronto Pago +
     
    <%--15--%> - - Generar
    NC
    + + + Generar
    + NC +
    - <%--16--%> + <%--16--%> - - + + - <%--17--%> + <%--17--%> - + <%--18--%> - + - + <%--19--%> - + - + <%--20--%> - + - + <%--21--%> - + - + <%--22--%> - + - + <%--23--%> - + - + <%--24--%> - + - + <%--25--%> - + - + - + <%--26--%> - + @@ -487,31 +547,34 @@ <%--27--%> - - + + <%--28--%> - - + + <%--29--%> - + Auxiliar - - + + <%--30--%> - - Comp
    Pago
    + + + Comp
    + Pago +
    - +
    @@ -608,7 +671,7 @@
    <%-- FIN MODAL SALDAR INCOBRABLE--%> -