[FIX] stock_landed_costs: multi-currency
- Activate 2 currencies - Create a landed cost product - Create a Vendor Bill in a currency different from the company currency - Add the landed cost product - Click on 'Create Landed Costs' The landed cost is created in the company currency, but with the amounts in the vendor bill currency. This happens because the currency conversion is missing. opw-2200500 closes odoo/odoo#45861 X-original-commit: 41f52aef54ddf9ab4cd0f23c1224c2d7581a1ede Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
This commit is contained in:
@@ -31,7 +31,7 @@ class AccountMove(models.Model):
|
||||
'product_id': l.product_id.id,
|
||||
'name': l.product_id.name,
|
||||
'account_id': l.product_id.product_tmpl_id.get_product_accounts()['stock_input'].id,
|
||||
'price_unit': l.price_subtotal,
|
||||
'price_unit': l.currency_id._convert(l.price_subtotal, l.company_currency_id, l.company_id, l.move_id.date),
|
||||
'split_method': 'equal',
|
||||
}) for l in landed_costs_lines],
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user