Skip to content

Conversation

@qgroulard
Copy link

Because when the discount total is changed on a SOL, the discount total of every lines of the SO is recomputed.
If we use the same method as the one that computes the price total (_compute_amount()), it triggers the re-computation of fields such as 'discount' and 'price_unit', which is unexpected.

See in this video how price and discount of other lines are recomputed when we edit a line (before this patch):

Capture.video.du.07-01-26.14.50.06.webm

…ounts

Because when the discount total is changed on a SOL, the discount total of every
lines of the SO is recomputed.
If we use the same method as the one that computes the price total, it triggers
the recomputation of fields such as 'discount' and 'price_unit', which is
unexpected.
@qgroulard qgroulard force-pushed the 16.0-sale_discount_display_amount_compute-qgr branch from 5413754 to ee75280 Compare January 7, 2026 14:04
@rousseldenis rousseldenis added this to the 16.0 milestone Jan 19, 2026
Copy link
Contributor

@rousseldenis rousseldenis left a comment

Choose a reason for hiding this comment

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

Seems legit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants