Files
odoo_source/addons/product
Pierre Masereel 44f5881511 [FIX] product: give correct currency when computing based pricelist
When your pricelist item price is based on an other prcicelist in
another currency, the wrong currency is given to the function
_get_product_price. we sould give the currency of the base_pricelist
instead of the target one.

Here is a example:
We have a priclist in INR based on a pricelist in USD. And the company
currency is euro.

When we go for the first time in '_compute_base_price', where we'll call
_get_product_price to get the price from the base pricelist (the $ one)

We get as src_currency the USD and target the INR. Since we are calling
_get_product_price with INR as currency, when _get_product_price will
call _compute_base_price, we'll get EUR as src_currency and INR as
target.

This will lead to apply on the EU price (the one on the product) the
rate of EUR->INR then apply over it USD -> INR. Instead of EUR -> USD
and then USD -> INR

closes odoo/odoo#119505

X-original-commit: 8ace9942368688dc1183133f451ea788a03e0f14
Signed-off-by: Victor Feyens (vfe) <vfe@odoo.com>
Signed-off-by: Masereel Pierre <pim@odoo.com>
2023-04-25 06:39:49 +02:00
..
…
2023-03-20 16:51:30 +01:00