Gdiaz imprecion PVCobranza saldo Anticipo NC

This commit is contained in:
rakcsle
2025-01-13 08:45:02 -07:00
parent 549ea13568
commit b018aca7fe
2 changed files with 36 additions and 0 deletions

View File

@@ -1572,6 +1572,34 @@ Partial Class PopUpVerFactura
End If
End If
'Boleto
If UrlParametros("OP").ToString = "AMORTIZACIONHIS" Then
'CveViajePasajero
Dim CVEIE As Integer = UrlParametros("CVEIE").ToString.ToEntero
Dim CVEVENTA As Integer = UrlParametros("CVEVENTA").ToString.ToEntero
Dim CVECLIENTE As Integer = UrlParametros("CVECLIENTE").ToString.ToEntero
If CVECLIENTE > 0 AndAlso (CVEIE > 0 Or CVEVENTA > 0) Then
ImprimirSaldosAmortizacion(CVEIE, CVEVENTA, CVECLIENTE)
End If
End If
End Sub
Private Sub ImprimirSaldosAmortizacion(CVEIE As Integer, CVEVENTA As Integer, CVECLIENTE As Integer)
If CVEVENTA > 0 Then
End If
If CVEIE > 0 Then
End If
End Sub
Private Function Parametros(Cadena As String) As Hashtable

View File

@@ -962,6 +962,7 @@ Partial Class Ventas_PVCobranza
Private Function GenerarFactura(CveVendedor As Integer, ByRef VentaRemision As Venta, ByRef ObjVentas As ClsVentas, ByRef ObjClientes As ClsClientes, ObservacionesAlmacen As String, VentaConta As Boolean, PlazoCobranza As Integer, Observaciones As String, PedidoContrato As String, OrdenCompra As String) As Modelos.Factura.MMensajeFactura
Dim Retorno As Modelos.Factura.MMensajeFactura = Nothing
Dim SbAlert As New StringBuilder()
Dim SBAmortizaciones As New StringBuilder
Try
Dim DtRemisiones As New DataTable
@@ -1058,6 +1059,7 @@ Partial Class Ventas_PVCobranza
ObjFactura.PreparaTimbre()
If HdnTipoAmortizacion.Value = "4" Then
Dim DtAnticipos As New DataTable()
DtAnticipos.Columns.Add("CveVenta", GetType(Integer))
DtAnticipos.Columns.Add("Importe", GetType(Decimal))
@@ -1075,6 +1077,7 @@ Partial Class Ventas_PVCobranza
For Each GvRow As GridViewRow In GVAnticipos.Rows
If GvRow.FCCheckBox("Chk" & GvRow.RowIndex) IsNot Nothing AndAlso GvRow.FCCheckBox("Chk" & GvRow.RowIndex).Checked Then
Dim CveVenta = GvRow.DataKey("CveVenta").ToEntero()
Dim Importe = GvRow.FCTextBox(String.Format("TxtAnticipo{0}", GvRow.RowIndex)).Text.ToDecimal()
Dim CveConceptoContable = GvRow.DataKey("CveConceptoContable").ToEntero()
@@ -1091,6 +1094,9 @@ Partial Class Ventas_PVCobranza
Dim Tipo = GvRow.DataKey("Tipo")
DtAnticipos.Rows.Add(CveVenta, Importe, CveConceptoContable, CveIE, FolioFiscal, Descuentos, TotalAnticipo, SubTotalAnticipo, CveMoneda, Fecha, TipoCambioPago, Folio, Tipo)
SBAmortizaciones.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA{1}&CVECLIENTE={2}", CveIE, CveVenta, VentaRemision.CveCliente))}"">Imprimir historial {Folio}</a><br/>")
End If
Next
@@ -1116,6 +1122,8 @@ Partial Class Ventas_PVCobranza
Next
SbAlert.AppendFormat("<ul><li><a class=""Texto"" href=""/Compras/PopUpVerFactura.aspx?P={0}"">Descargar PDF Factura</a></li></ul><br/>", Encripta(String.Format("OP=VTA&CVEVENTA={0}&PAG=1&GUARDAR=1", Retorno.CveVenta)))
SbAlert.Append(SBAmortizaciones.ToString)
Else
SbAlert.Append("Ocurrió un error al generar la factura")
End If