Skip to content

Commit

Permalink
[FIX] use lst_price for _compute_margin in product.product
Browse files Browse the repository at this point in the history
  • Loading branch information
anhvu-sg committed Jan 4, 2024
1 parent 6dd3cfc commit 8101091
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions product_standard_margin/models/product_product.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class ProductProduct(models.Model):

# Compute Section
@api.depends(
"list_price",
"lst_price",
"product_tmpl_id.list_price",
"standard_price",
"taxes_id.price_include",
Expand All @@ -62,7 +62,7 @@ class ProductProduct(models.Model):
def _compute_margin(self):
for product in self:
product.list_price_vat_excl = product.taxes_id.compute_all(
product.list_price, product=product
product.lst_price, product=product
)["total_excluded"]
product.standard_margin = (
product.list_price_vat_excl - product.standard_price
Expand Down

0 comments on commit 8101091

Please sign in to comment.