From b332d9b83d6e278db778dd3d0ed18c80d48fb214 Mon Sep 17 00:00:00 2001 From: Rakcsle Supertramp Date: Tue, 15 Dec 2020 15:18:02 -0700 Subject: [PATCH] ClientesAbonar --- Ventas/ClientesAbonar.aspx | 12 ++++++++++-- Ventas/ClientesAbonar.aspx.vb | 23 +++++++++++++++++++++++ 2 files changed, 33 insertions(+), 2 deletions(-) diff --git a/Ventas/ClientesAbonar.aspx b/Ventas/ClientesAbonar.aspx index b3a9d6d14..6887e39d7 100644 --- a/Ventas/ClientesAbonar.aspx +++ b/Ventas/ClientesAbonar.aspx @@ -261,7 +261,7 @@ @@ -358,7 +358,15 @@ CveVenta - + + + + + + + Complemento Pago + + diff --git a/Ventas/ClientesAbonar.aspx.vb b/Ventas/ClientesAbonar.aspx.vb index 98735344f..8b4334e83 100644 --- a/Ventas/ClientesAbonar.aspx.vb +++ b/Ventas/ClientesAbonar.aspx.vb @@ -636,6 +636,17 @@ Partial Class Ventas_ClientesAbonar e.Row.FCCheckBox("Chk").Visible = False End If + + If e.Row.DBCampo("CveVenta").ToEntero > 0 Then + If e.Row.DataKey("ClaveMetodoPagoSAT") = "PUE" Then + e.Row.FCLinkButton("LnkComplemento").Text = "" + e.Row.FCLinkButton("LnkComplemento").CssClass = "text-danger" + End If + Else + e.Row.FCLinkButton("LnkComplemento").Visible = False + End If + + End If End Sub @@ -2505,6 +2516,18 @@ Partial Class Ventas_ClientesAbonar 'For i = 0 To CveVentas.Count - 1 Dim ObjBancos As New ClsBancos + + + If ObjBancos.GetComplementoPagosRep(-1, Now.AddYears(-2), Now, CveIE, -1, If(CveIESustitucion > 0, 2, 1), UsuarioActual.CveEmpresa, -1) Then + If Not ObjBancos.DtResultados.Rows.Count > 0 Then + ObjBancos.Dispose() + Alert("No se generaron complementos de pago porque no hay facturas con método de pago PPD", TipoMensaje.MsgAdvertencia) + Return "" + End If + End If + + + ObjBancos.IniciaTransacSQL() If ObjBancos.GeneraTimbrePago(CveIE, -1, UsuarioActual, CveCliente, CFDIRelacionado:=CFDIRelacionadoSustitucion, EsRegeneracion:=If(CveIESustitucion > 0, True, False)) Then