Skip to content

Commit

Permalink
Merge pull request afup#1370 from afup/infos_justificatif_tva
Browse files Browse the repository at this point in the history
ajout des infos de montants HT/de TVA dans le journal
  • Loading branch information
agallou authored Nov 30, 2023
2 parents 8ed1404 + 606c24a commit 6e38310
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 3 deletions.
22 changes: 20 additions & 2 deletions htdocs/pages/administration/compta_journal.php
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,16 @@ function paybox_link($description)
'Règlement',
'Commentaire',
'Justificatif',
'Nom justificatif'
'Nom justificatif',
'Montant HT',
'TVA',
'Montant HT non soumis à TVA',
'Montant HT soumis à TVA 5,5',
'TVA 5,5',
'Montant HT soumis à TVA 10',
'TVA 10',
'Montant HT soumis à TVA 20',
'TVA 20'
];
fputcsv($fp, $columns, $csvDelimiter, $csvEnclosure);

Expand All @@ -332,7 +341,16 @@ function paybox_link($description)
$line['reglement'],
$line['comment'],
$line['attachment_required'] ? 'Oui' : 'Non',
$line['attachment_filename']
$line['attachment_filename'],
$line['montant_ht'],
$line['montant_tva'],
$line['montant_ht_0'],
$line['montant_ht_5_5'],
$line['montant_tva_5_5'],
$line['montant_ht_10'],
$line['montant_tva_10'],
$line['montant_ht_20'],
$line['montant_tva_20']
],
$csvDelimiter,
$csvEnclosure
Expand Down
11 changes: 10 additions & 1 deletion sources/Afup/Comptabilite/Comptabilite.php
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,16 @@ function obtenirJournal($debitCredit = '',
$requete .= 'compta_reglement.reglement, ';
$requete .= 'compta_evenement.evenement, ';
$requete .= 'compta_categorie.categorie, ';
$requete .= 'compta_compte.nom_compte ';
$requete .= 'compta_compte.nom_compte, ';
$requete .= '(compta.montant_ht_soumis_tva_0 + compta.montant_ht_soumis_tva_5_5 + compta.montant_ht_soumis_tva_10 + compta.montant_ht_soumis_tva_20) as montant_ht, ';
$requete .= '((compta.montant_ht_soumis_tva_5_5*0.055) + (compta.montant_ht_soumis_tva_10*0.1) + (compta.montant_ht_soumis_tva_20*0.2)) as montant_tva, ';
$requete .= 'compta.montant_ht_soumis_tva_0 as montant_ht_0, ';
$requete .= 'compta.montant_ht_soumis_tva_5_5 as montant_ht_5_5, ';
$requete .= 'compta.montant_ht_soumis_tva_5_5*0.055 as montant_tva_5_5, ';
$requete .= 'compta.montant_ht_soumis_tva_10 as montant_ht_10, ';
$requete .= 'compta.montant_ht_soumis_tva_10*0.1 as montant_tva_10, ';
$requete .= 'compta.montant_ht_soumis_tva_20 as montant_ht_20, ';
$requete .= 'compta.montant_ht_soumis_tva_20*0.2 as montant_tva_20 ';
$requete .= 'FROM ';
$requete .= 'compta ';
$requete .= 'LEFT JOIN ';
Expand Down

0 comments on commit 6e38310

Please sign in to comment.