Premier commit
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
namespace SIFinance.Modules.Finance.Dtos;
|
||||
|
||||
public record AvoirDto(
|
||||
int Id,
|
||||
string Numero,
|
||||
int FournisseurId,
|
||||
string Fournisseur,
|
||||
decimal Montant,
|
||||
decimal SoldeDisponible,
|
||||
DateOnly Date,
|
||||
int? FactureLieeId,
|
||||
string? FactureLieeNumero);
|
||||
|
||||
public record CreateAvoirDto(string Numero, int FournisseurId, decimal Montant, DateOnly Date);
|
||||
@@ -0,0 +1,53 @@
|
||||
namespace SIFinance.Modules.Finance.Dtos;
|
||||
|
||||
public record FactureEcheanceDto(int Id, DateOnly Date, decimal Montant, string Statut);
|
||||
public record FactureJustificatifDto(string Nom, string Url);
|
||||
|
||||
public record FactureDto(
|
||||
int Id,
|
||||
string Numero,
|
||||
int FournisseurId,
|
||||
string Fournisseur,
|
||||
decimal MontantHt,
|
||||
decimal TauxTva,
|
||||
decimal MontantTva,
|
||||
decimal MontantTtc,
|
||||
DateOnly DateFacture,
|
||||
DateOnly DateEcheance,
|
||||
string Statut,
|
||||
int? DemandeAchatId,
|
||||
int? AvoirLieId,
|
||||
string? AvoirLieNumero,
|
||||
decimal? AvoirLieMontant,
|
||||
string? Commentaire,
|
||||
bool EstDoublonSignale,
|
||||
int? ContratId,
|
||||
string? ContratObjet,
|
||||
List<FactureEcheanceDto> Echeances,
|
||||
List<FactureJustificatifDto>? Justificatifs = null);
|
||||
|
||||
// Le formulaire ne saisit qu'un montant TTC global (pas de ventilation HT/TVA à la création) —
|
||||
// on applique un taux de TVA par défaut de 20% et on recalcule HT/TVA à partir du TTC saisi.
|
||||
public record CreateFactureDto(string Numero, int FournisseurId, decimal Montant, DateOnly DateFacture, DateOnly DateEcheance, int? DemandeAchatId, string? Commentaire, int? ContratId);
|
||||
|
||||
public record UpdateFactureCommentaireDto(string? Commentaire);
|
||||
|
||||
public record UpdateFactureStatutDto(string Statut);
|
||||
|
||||
public record CreateEcheanceDto(DateOnly Date, decimal Montant);
|
||||
|
||||
public record UpdateEcheanceDto(DateOnly Date, decimal Montant);
|
||||
|
||||
// Résultat de l'analyse d'un PDF Factur-X/ZUGFeRD uploadé (réception de facture
|
||||
// électronique) — Conforme=false si le PDF n'a pas de XML EN16931 embarqué, auquel cas
|
||||
// les autres champs sont null et la saisie reste manuelle.
|
||||
public record FacturXAnalyseDto(
|
||||
bool Conforme,
|
||||
string? Numero,
|
||||
string? FournisseurNom,
|
||||
decimal? MontantHt,
|
||||
decimal? MontantTva,
|
||||
decimal? MontantTtc,
|
||||
DateOnly? DateFacture,
|
||||
DateOnly? DateEcheance,
|
||||
string? Erreur);
|
||||
@@ -0,0 +1,22 @@
|
||||
namespace SIFinance.Modules.Finance.Dtos;
|
||||
|
||||
// Un "paiement" côté UI peut regrouper plusieurs factures d'un même fournisseur.
|
||||
// La table fin.paiements est 1 ligne par facture : on regroupe par Reference pour l'affichage.
|
||||
public record PaiementGroupeDto(
|
||||
string Reference,
|
||||
int FournisseurId,
|
||||
string Fournisseur,
|
||||
List<int> FactureIds,
|
||||
List<string> FactureNumeros,
|
||||
decimal MontantTotal,
|
||||
int ModePaiementId,
|
||||
string ModePaiement,
|
||||
DateOnly DatePaiement,
|
||||
string Statut,
|
||||
bool Rapproche);
|
||||
|
||||
public record FactureDisponibleDto(int Id, int FournisseurId, string Fournisseur, string Numero, decimal Montant, DateOnly DateFacture);
|
||||
|
||||
public record CreatePaiementDto(List<int> FactureIds, int ModePaiementId, DateOnly DatePaiement, string Reference, string Statut, bool Rapproche);
|
||||
|
||||
public record UpdatePaiementDto(int ModePaiementId, DateOnly DatePaiement, string Reference, string Statut, bool Rapproche);
|
||||
Reference in New Issue
Block a user