Gdiaz imprecion PVCobranza saldo Anticipo NC
This commit is contained in:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user