Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix simple report : use untaxed amounts #29218

Merged
merged 1 commit into from Apr 4, 2024

Conversation

rycks
Copy link
Contributor

@rycks rycks commented Apr 3, 2024

More details on french forum
https://www.dolibarr.fr/forum/t/baser-le-calcul-du-rapport-chiffre-daffaires-facture-sur-le-ht/45974

Most important part thanks to Philazerty

Définition - Chiffre d'affaires | Insee https://www.insee.fr/fr/metadonnees/definition/c1703

Le chiffre d'affaires représente le montant des affaires (hors taxes) réalisées par une unité statistique (entreprise, unité légale) avec les tiers dans l'exercice de son activité professionnelle

if (!empty($cum[$caseprev]) && !empty($cum[$case])) {
$percent = (round(($cum[$case] - $cum[$caseprev]) / $cum[$caseprev], 4) * 100);
//print "X $cum[$case] - $cum[$caseprev] - $cum[$caseprev] - $percent X";
if (!empty($cum_ht[$caseprev]) && !empty($cum_ht[$case])) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@rycks can you rename cum to cumulative 🙄

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@frederic34 for sure i could do it but i don't know why ? could you please explain it to me (in private mail if that's something embarrassing)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see translation of cum... in french

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and ... that's a remake of weboob story ?

excuse-me but if we have to change all variables names that could be misinterpreted we could have a lot of work "for nothing" ...

Copy link
Contributor Author

@rycks rycks Apr 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Le me do an other PR for that but after merge current PR to avoid collisions

@eldy eldy merged commit bc1f292 into Dolibarr:develop Apr 4, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants