diff options
| author | bve <bve@odoo.com> | 2021-01-11 14:52:19 +0000 |
|---|---|---|
| committer | BVE <bve@odoo.com> | 2021-01-19 13:31:40 +0000 |
| commit | 66533ebd88ed89c3baae6fdb1d0a28a458fa0cb9 (patch) | |
| tree | 8866f966a073abbd6cdc0b74689fbabdaa817fdc /addons/account | |
| parent | 3ef5e63f62f0f84d6e92cb55eb112ab2f2924faa (diff) | |
[IMP] account: warn msg decimal accuracy on modification
commit 31e1322b40ab33bf81d4c000f2b2a3f3eb8d0958 is allowing the
customer to increase is decimal accuracy for currency without
consequences but triggering issue upon lowering it if entries
already exist.
+ Remove the redirection to the support.
Let's ensure that the behavior is consistent and the users are
warned on first modification. To do so, adding an alert msg
in addition of the blocking message in case of lowering the decimal
accuracy after already creating accounting entries.
opw-2428857
closes odoo/odoo#64344
Signed-off-by: Simon Goffin (sig) <sig@openerp.com>
Diffstat (limited to 'addons/account')
| -rw-r--r-- | addons/account/i18n/account.pot | 3 | ||||
| -rw-r--r-- | addons/account/models/res_currency.py | 2 |
2 files changed, 2 insertions, 3 deletions
diff --git a/addons/account/i18n/account.pot b/addons/account/i18n/account.pot index 40a02ca05d3..5ab7d8f1ee4 100644 --- a/addons/account/i18n/account.pot +++ b/addons/account/i18n/account.pot @@ -13632,8 +13632,7 @@ msgstr "" #, python-format msgid "" "You cannot reduce the number of decimal places of a currency which has " -"already been used to make accounting entries. If you really need to do that," -" please contact tech support." +"already been used to make accounting entries." msgstr "" #. module: account diff --git a/addons/account/models/res_currency.py b/addons/account/models/res_currency.py index 0e0a0c06217..964a60e973c 100644 --- a/addons/account/models/res_currency.py +++ b/addons/account/models/res_currency.py @@ -24,7 +24,7 @@ class ResCurrency(models.Model): rounding_val = vals['rounding'] for record in self: if (rounding_val > record.rounding or rounding_val == 0) and record._has_accounting_entries(): - raise UserError(_("You cannot reduce the number of decimal places of a currency which has already been used to make accounting entries. If you really need to do that, please contact tech support.")) + raise UserError(_("You cannot reduce the number of decimal places of a currency which has already been used to make accounting entries.")) return super(ResCurrency, self).write(vals) |
