4 Saldos en viaticos BDH,

This commit is contained in:
rakcsle
2025-01-20 08:51:00 -07:00
parent 6140f1b73a
commit e7f85af6b2
5 changed files with 1996 additions and 1815 deletions

View File

@@ -1425,9 +1425,14 @@ Partial Class PopUpVerFactura
'Imprime Movimiento de IE
If UrlParametros("OP").ToString = "ImprimeMov" Then
Dim ImportePagoTotal As Decimal = If(UrlParametros("IMPORTEPAGOTOTAL") IsNot Nothing AndAlso UrlParametros("IMPORTEPAGOTOTAL").ToString.ToDecimal > 0, UrlParametros("IMPORTEPAGOTOTAL").ToString.ToDecimal, -1)
Dim SaldoTotal As Decimal = If(UrlParametros("SALDO") IsNot Nothing AndAlso UrlParametros("SALDO").ToString.ToDecimal > 0, UrlParametros("SALDO").ToString.ToDecimal, -1)
If UrlParametros("CVEIE") IsNot Nothing AndAlso UrlParametros("CVEIE").ToString.ToEntero > 0 Then
ImprimeMov(UrlParametros("CVEIE").ToString.ToEntero)
ImprimeMov(UrlParametros("CVEIE").ToString.ToEntero, ImportePagoTotal, SaldoTotal)
End If
End If
'IMPRIME DEPOSITOS CAJA
@@ -5885,7 +5890,7 @@ Partial Class PopUpVerFactura
End Sub
Private Sub ImprimeMov(CveIE As Integer)
Private Sub ImprimeMov(CveIE As Integer, Optional ImportePagoTotal As Decimal = 0, Optional SaldoTotal As Decimal = 0)
Dim ObjIE As New ClsBancos()
Dim DtGvRH As New DataTable
Dim DtComprobacion As New DataTable
@@ -5969,6 +5974,16 @@ Partial Class PopUpVerFactura
params.Add(New ReportParameter("importe", ParamComprobacion.Rows(0)("Importe").ToString))
params.Add(New ReportParameter("TotAbono", DtComprobacion.SUM("Abonado").ToString))
If UsuarioActual.CveEmpresa = 140 Then
Dim Aplicado As Decimal = 0
Dim ImporteDoc As Decimal = ParamComprobacion.Rows(0)("Importe").ToString.ToDecimal
Dim LeyendaSaldo As String = $"Folio #{ParamComprobacion.Rows(0)("Folio").ToString} con importe de ${ImporteDoc.ToString("###,###,###.00")} y saldo antes de la comprobación de ${SaldoTotal.ToString("###,###,###.00")}, Comprobaciones a la fecha {ParamComprobacion.Rows(0)("FechaDocumento").ToString().ToDate().ToString("dd/MM/yyyy")} ${ImportePagoTotal.ToString("###,###,###.00")} saldo después de la comprobación ${(SaldoTotal - ImportePagoTotal).ToString("###,###,###.00")} ."
params.Add(New ReportParameter("LeyendaSaldo", LeyendaSaldo))
End If
params.Add(New ReportParameter("LogoPath", RutaImagenLogo))
ImprimirPDF("Empresas/Grales/Formatos/RepRembolsosComprobaciones.rdlc", DtComprobacion, params, String.Format("IE{0}", CveIE), Formato:="PDF")