summaryrefslogtreecommitdiff
path: root/addons/web/static/src/xml/base.xml
diff options
context:
space:
mode:
authorJorge Pinna Puissant <jpp@odoo.com>2020-03-30 10:03:03 +0000
committerJorge Pinna Puissant <jpp@odoo.com>2020-03-30 12:33:13 +0000
commit1c3d1eed015b2fc19245657ae861a3cb6831bde8 (patch)
treea877ef6374d726f35561a260584742f975ba1573 /addons/web/static/src/xml/base.xml
parent91d341adceb3d9bc9a92299aa0b456b33ed0ba29 (diff)
[FIX] account: avoid convert amount in currency into debit/credit in a reverse entry
- Create an account in foreign currency; - Create different currency rates for the foreign currency at different dates; - Create a journal entry at past date X with 2 lines, and use the "foreign currency account" for one of the lines, but a domestic currency account for the other; - Now try to reverse the entry at a later date with a different exchange rate (select an appropriate date in the wizard). Before this commit, an error was raise because the move is not balanced. This issue occurs because the 'amount_currency' value is used to recompute the debit/credit value based on original currency rate. But the _onchange_currency function is also called, and it recomputes the credit/debit for the foreign currency line with the exchange rate of the date of the reverse entry. This commit is a fine-tuning of ae3d7aeb706dc1bc3216fd63c6a943e5d9cb56e7 to avoid recomputing credit/debit in a reverse entry. opw-2227098 closes odoo/odoo#48609 X-original-commit: 748b2bcb3950840d815040684f72802c968240f2 Signed-off-by: Simon Goffin (sig) <sig@openerp.com> Signed-off-by: Jorge Pinna Puissant (jpp) <jpp@odoo.com>
Diffstat (limited to 'addons/web/static/src/xml/base.xml')
0 files changed, 0 insertions, 0 deletions