0 CyC Impresión de saldo anticipo
This commit is contained in:
@@ -1617,18 +1617,19 @@ Partial Class PopUpVerFactura
|
||||
DatosSaldoAntNCDev.FiltroPrimeroValor("Tipo", $"CveVenta={CveVenta}"),
|
||||
DatosSaldoAntNCDev.FiltroPrimeroValor("Tipo", $"CveIE={CveIE}"))
|
||||
|
||||
Folio = If(CveVenta > 0,
|
||||
DatosSaldoAntNCDev.FiltroPrimeroValor("Folio", $"CveVenta={CveVenta}"),
|
||||
DatosSaldoAntNCDev.FiltroPrimeroValor("Folio", $"CveIE={CveIE}"))
|
||||
|
||||
|
||||
|
||||
If CveIE > 0 Then
|
||||
CveVenta = DatosSaldoAntNCDev.FiltroPrimeroValor("CveVenta", $"CveIE={CveIE}").ToEntero
|
||||
Folio = DatosSaldoAntNCDev.FiltroPrimeroValor("Folio", $"CveIE={CveIE}")
|
||||
Else
|
||||
Folio = DatosSaldoAntNCDev.FiltroPrimeroValor("Folio", $"CveVenta={CveVenta}")
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
If TipoDocto.Contiene("Egs", "Dev", "Ant") Then
|
||||
If TipoDocto.Contiene("Egs", "Dev", "Ant", "NC") Then
|
||||
Dim AplicaAmortizacion As Boolean = False
|
||||
If TipoDocto.Contiene("Ant") Then AplicaAmortizacion = True
|
||||
|
||||
@@ -1648,31 +1649,9 @@ Partial Class PopUpVerFactura
|
||||
Dim DbRowVenta = ObjVentas.DtResultados.Copy().FiltroPrimero("")
|
||||
|
||||
If DbRowVenta IsNot Nothing Then
|
||||
'Dim VentaActual As New Venta(UsuarioActual)
|
||||
'VentaActual.CveVenta = CveVentaAmortizada
|
||||
'VentaActual.TipoDocto = DbRowVenta("TipoDocto").ToString
|
||||
'VentaActual.Fecha = DbRowVenta("Fecha").ToString.ToDate
|
||||
'VentaActual.CveCliente = DbRowVenta("CveCliente").ToString.ToEntero
|
||||
'VentaActual.CveMoneda = DbRowVenta("CveMoneda").ToString.ToEntero
|
||||
'VentaActual.SerieFolio = DbRowVenta("SerieFolio").ToString
|
||||
'VentaActual.ClienteNombre = DbRowVenta("ClienteNombre").ToString
|
||||
'VentaActual.TC = DbRowVenta("TipoCambio").ToString.ToDecimal
|
||||
'VentaActual.Total = DbRowVenta("Total").ToString.ToDecimal
|
||||
'VentaActual.IVA = DbRowVenta("IVA").ToString.ToDecimal
|
||||
'VentaActual.IEPS = DbRowVenta("IEPS").ToString.ToDecimal
|
||||
'VentaActual.RetIVA = DbRowVenta("RetIVA").ToString.ToDecimal
|
||||
'VentaActual.RetISR = DbRowVenta("RetISR").ToString.ToDecimal
|
||||
|
||||
'VentaActual.PorcentajeIVA = DbRowVenta("PorcentajeIVA").ToString.ToDecimal
|
||||
'VentaActual.UsuarioActual = UsuarioActual
|
||||
'VentaActual.CveSubProyecto = DbRowVenta("CveSubProyecto").ToString.ToEntero
|
||||
|
||||
'VentaActual.CveMoneda = DbRowVenta("CveMoneda").ToString.ToEntero
|
||||
'VentaActual.SerieFolio = DbRowVenta("SerieFolio").ToString
|
||||
|
||||
params.Add(New ReportParameter("SerieFolio", DbRowVenta("SerieFolio").ToString))
|
||||
params.Add(New ReportParameter("Moneda", DbRowVenta("Moneda").ToString))
|
||||
params.Add(New ReportParameter("Cliente", DbRowVenta("Cliente").ToString))
|
||||
params.Add(New ReportParameter("Cliente", DbRowVenta("ClienteNombre").ToString))
|
||||
|
||||
End If
|
||||
|
||||
@@ -1685,26 +1664,23 @@ Partial Class PopUpVerFactura
|
||||
|
||||
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
'params.Add(New ReportParameter("FechaInicio", FechaI))
|
||||
'params.Add(New ReportParameter("FechaFin", FechaF))
|
||||
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToString))
|
||||
'params.Add(New ReportParameter("AgrupadoPor", $"<b>Agrupado Por:</b> {Grupo}{FechaIn}{FechaFn}"))
|
||||
params.Add(New ReportParameter("LogoPath", If(Imagen.Exists, $"file://{Imagen.FullName}", "")))
|
||||
|
||||
params.Add(New ReportParameter("SaldoAntNCDev", SaldoAntNCDev.ToString))
|
||||
params.Add(New ReportParameter("Monto", Monto.ToString))
|
||||
params.Add(New ReportParameter("Saldo", Saldo.ToString))
|
||||
params.Add(New ReportParameter("Folio", Folio))
|
||||
|
||||
Dim NombreArchivo As String = "SaldoAntNCDev.rdlc"
|
||||
|
||||
Dim Archivo As New System.IO.FileInfo(String.Format("{0}Formatos\{1}", UsuarioActual.Empresa.Ruta, NombreArchivo))
|
||||
|
||||
If Archivo.Exists Then
|
||||
ImprimirPDF(Archivo.FullName, DTNCVinculadas, params, "OrdenesdeCompraporvincular ", Opcion)
|
||||
ImprimirPDF(Archivo.FullName, DTNCVinculadas, params, "Aplicaciones", "PDF")
|
||||
Else
|
||||
ImprimirPDF($"Empresas/Grales/Formatos/{NombreArchivo}", DTNCVinculadas, params, "OrdenesdeCompraporvincular", Opcion)
|
||||
ImprimirPDF($"Empresas/Grales/Formatos/{NombreArchivo}", DTNCVinculadas, params, "Aplicaciones", "PDF")
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
@@ -868,6 +868,34 @@ Partial Class Ventas_PVCobranza
|
||||
If Not String.IsNullOrEmpty(MsgTimbrado) Then
|
||||
msBuild.AppendFormat("<br/>{0}<br/>", MsgTimbrado)
|
||||
End If
|
||||
|
||||
|
||||
|
||||
If respNC IsNot Nothing Then
|
||||
For Each dr As DataRow In respNC.Factura.DtAnticiposAplicados.Rows
|
||||
msBuild.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA={1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}&SALDO={5}",
|
||||
dr("CveIE").ToString,
|
||||
dr("CveVenta").ToString,
|
||||
respNC.Factura.CveCliente,
|
||||
respNC.CveVenta,
|
||||
respNC.Factura.Total,
|
||||
(respNC.Factura.Total - respNC.Factura.DtAnticiposAplicados.SUM("Importe"))))}"">Imprimir historial {dr("Folio").ToString}</a><br/>")
|
||||
Next
|
||||
Else
|
||||
For Each dr As DataRow In respFactura.Factura.DtAnticiposAplicados.Rows
|
||||
msBuild.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA={1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}&SALDO={5}",
|
||||
dr("CveIE").ToString,
|
||||
dr("CveVenta").ToString,
|
||||
respFactura.Factura.CveCliente,
|
||||
respFactura.CveVenta,
|
||||
respFactura.Factura.Total,
|
||||
(respFactura.Factura.Total - respFactura.Factura.DtAnticiposAplicados.SUM("Importe"))))}"">Imprimir historial {dr("Folio").ToString}</a><br/>")
|
||||
Next
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
Else
|
||||
msBuild.Append($"Pago Registrado correctamente.<br/><br/> <a href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=VTA&CVEVENTA={0}&PAG=1&GUARDAR=1&TICKET=1®ENERAR=1", CveVenta))}"" class='Texto'>Imprimir ticket</a>")
|
||||
End If
|
||||
@@ -1124,7 +1152,7 @@ Partial Class Ventas_PVCobranza
|
||||
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)))
|
||||
|
||||
For Each dr As DataRow In DtAnticipos.Rows
|
||||
SBAmortizaciones.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA{1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}&SALDO={5}",
|
||||
SBAmortizaciones.AppendLine($"<br><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={Encripta(String.Format("OP=AMORTIZACIONHIS&CVEIE={0}&CVEVENTA={1}&CVECLIENTE={2}&CVEVENTAAMORTIZADA={3}&MONTO={4}&SALDO={5}",
|
||||
dr("CveIE").ToString,
|
||||
dr("CveVenta").ToString,
|
||||
Retorno.Factura.CveCliente,
|
||||
@@ -1191,6 +1219,7 @@ Partial Class Ventas_PVCobranza
|
||||
End If
|
||||
|
||||
Return Retorno
|
||||
|
||||
End Function
|
||||
|
||||
Private Function ValidateString(texto As String, contenidoValidar As String) As Boolean
|
||||
|
||||
Reference in New Issue
Block a user