Files
drupal-figli-compta/web
bachir b7490eb76a Ajoute la TVA (%) et calcule automatiquement le Montant TTC
Architecture : Montant HT reste saisi à la main, un nouveau champ TVA
(%) le complète, et Montant TTC = round(HT * (1 + TVA/100), 2) devient
une valeur calculée plutôt que saisie -- champ readonly dans le
formulaire (aperçu live en JS), calcul faisant foi côté serveur dans
figli_compta_ledger_node_presave().

Migration (update hooks 8004/8005) : Montant TTC n'est **jamais**
modifié pour les données historiques -- seul un TVA effectif est
rétro-calculé depuis HT/TTC existants et ajouté en tant que nouvelle
métadonnée (1498 lignes renseignées, 58 laissées vides faute de TTC
source). Précision du champ TVA fixée à 4 décimales après vérification
empirique sur les 1556 lignes existantes : reconstruire TTC = HT * (1 +
TVA/100) avec un taux arrondi à 4 décimales ne s'écarte du TTC réel que
pour 9 lignes (probables factures multi-taux), contre 74 à 2 décimales.

Garde-fou supplémentaire dans le presave : le recalcul du TTC ne se
déclenche que si HT ou TVA ont réellement changé par rapport à la
révision précédente (comparaison à $node->original) -- sans ça,
rouvrir une ancienne ligne migrée pour corriger un simple libellé
aurait silencieusement dérivé son TTC historique de ±0,01€ à cause de
l'arrondi du taux rétro-calculé, ce qu'interdit la règle du projet de
ne jamais corriger les données historiques.

Réorganisation du formulaire : N° Facture rejoint Client sur une même
ligne, Montant HT/TVA/Montant TTC forment la ligne suivante -- les
poids de champs doivent rester des entiers (Drupal tronque silencieusement
tout poids fractionnaire lors de la sauvegarde de l'affichage).
2026-09-07 11:36:53 +02:00
..

Drupal Logo

Drupal is an open source content management platform supporting a variety of websites ranging from personal weblogs to large community-driven websites. For more information, visit the Drupal website, Drupal.org, and join the Drupal community.

Contributing

Drupal is developed on Drupal.org, the home of the international Drupal community since 2001!

Drupal.org hosts Drupal's GitLab repository, its issue queue, and its documentation. Before you start working on code, be sure to search the issue queue and create an issue if your aren't able to find an existing issue.

Every issue on Drupal.org automatically creates a new community-accessible fork that you can contribute to. Learn more about the code contribution process on the Issue forks & merge requests page.

Usage

For a brief introduction, see USAGE.txt. You can also find guides, API references, and more by visiting Drupal's documentation page.

You can quickly extend Drupal's core feature set by installing any of its thousands of free and open source modules. With Drupal and its module ecosystem, you can often build most or all of what your project needs before writing a single line of code.

Changelog

Drupal keeps detailed change records. You can search Drupal's changes for a record of every notable breaking change and new feature since 2011.

Security

For a list of security announcements, see the Security advisories page (available as an RSS feed). This page also describes how to subscribe to these announcements via email.

For information about the Drupal security process, or to find out how to report a potential security issue to the Drupal security team, see the Security team page.

Need a helping hand?

Visit the Support page or browse over a thousand Drupal providers offering design, strategy, development, and hosting services.

Know your rights when using Drupal by reading Drupal core's license.

Learn about the Drupal trademark and logo policy here.