QuestPdf Implementado en la totalidad de reportes.
All checks were successful
Optimized Build and Deploy / remote-build-and-deploy (push) Successful in 7m55s
All checks were successful
Optimized Build and Deploy / remote-build-and-deploy (push) Successful in 7m55s
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace GestionIntegral.Api.Dtos.Reportes.ViewModels
|
||||
{
|
||||
public class CuentasDistribuidorViewModel
|
||||
{
|
||||
// --- Datos de entrada ---
|
||||
public IEnumerable<BalanceCuentaDistDto> Movimientos { get; set; } = new List<BalanceCuentaDistDto>();
|
||||
public IEnumerable<BalanceCuentaPagosDto> Pagos { get; set; } = new List<BalanceCuentaPagosDto>();
|
||||
public IEnumerable<BalanceCuentaDebCredDto> DebitosCreditos { get; set; } = new List<BalanceCuentaDebCredDto>();
|
||||
|
||||
// Saldo real de la cuenta, se muestra al final sin usarse en cálculos intermedios.
|
||||
public decimal SaldoDeCuenta { get; set; }
|
||||
|
||||
// --- Parámetros del reporte ---
|
||||
public string NombreDistribuidor { get; set; } = string.Empty;
|
||||
public string FechaDesde { get; set; } = string.Empty;
|
||||
public string FechaHasta { get; set; } = string.Empty;
|
||||
public string FechaReporte { get; set; } = DateTime.Now.ToString("dd/MM/yyyy");
|
||||
|
||||
// --- Propiedades para el resumen final ---
|
||||
public decimal TotalMovimientos => Movimientos.Sum(m => m.Debe - m.Haber);
|
||||
public decimal TotalPagos => Pagos.Sum(p => p.Debe - p.Haber);
|
||||
public decimal TotalDebitosCreditos => DebitosCreditos.Sum(d => d.Debe - d.Haber);
|
||||
public decimal TotalPeriodo => TotalMovimientos + TotalPagos + TotalDebitosCreditos;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user