#128 product_update_price_last_purchase: adapt last purchase price calculation to changes in purchase_triple_discount refactor in OCA/purchase-workflow/pull/2599
This commit is contained in:
parent
4ab5fa28e8
commit
4134424dea
1 changed files with 2 additions and 2 deletions
|
|
@ -33,7 +33,7 @@ class StockMove(models.Model):
|
||||||
):
|
):
|
||||||
price_updated = float_round(
|
price_updated = float_round(
|
||||||
move.purchase_line_id.price_unit
|
move.purchase_line_id.price_unit
|
||||||
* (1 - move.purchase_line_id.discount / 100),
|
* (1 - move.purchase_line_id.discount1 / 100),
|
||||||
precision_digits=2,
|
precision_digits=2,
|
||||||
)
|
)
|
||||||
elif (
|
elif (
|
||||||
|
|
@ -42,7 +42,7 @@ class StockMove(models.Model):
|
||||||
):
|
):
|
||||||
price_updated = float_round(
|
price_updated = float_round(
|
||||||
move.purchase_line_id.price_unit
|
move.purchase_line_id.price_unit
|
||||||
* (1 - move.purchase_line_id.discount / 100)
|
* (1 - move.purchase_line_id.discount1 / 100)
|
||||||
* (1 - move.purchase_line_id.discount2 / 100),
|
* (1 - move.purchase_line_id.discount2 / 100),
|
||||||
precision_digits=2,
|
precision_digits=2,
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue