fix: Calculate gross amount using price_subtotal instead of price_subtotal_incl for order lines.

This commit is contained in:
Suherdy Yacob 2026-02-10 17:15:17 +07:00
parent c63270d21a
commit b381cbc779

View File

@ -42,9 +42,9 @@ class PosSession(models.Model):
# We can sum the positive lines to get the "Sale Value".
gross_amount = sum(
line.price_subtotal_incl
line.price_subtotal
for line in order.lines
if line.price_subtotal_incl > 0
if line.price_subtotal > 0
)
if float_is_zero(gross_amount, precision_rounding=self.currency_id.rounding):