Skip to content
Snippets Groups Projects
Commit a45d4bd9 authored by Adrien Widart (awt)'s avatar Adrien Widart (awt)
Browse files

[FIX] core: find currency when writing monetary field


When creating a record, if a value is related to a monetary field and if
the currency field is a non-stored related one, the value will not be
rounding: when writing the monetary value in the database, we first call
`convert_to_column`. In the parameter, `record` is empty (it is not yet
created) and `values` only contains the stored values (so the currency
value is not present). As a result, `currency` will not be defined and
the value will not be rounded.

OPW-2955202

closes odoo/odoo#105779

X-original-commit: 4456480b
Related: odoo/enterprise#34091
Signed-off-by: default avatarRaphael Collet <rco@odoo.com>
parent 8dffc81d
Branches
Tags
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment