Float fields and decimal separator in fr_BE

Bug #893575 reported by Francois Degrave
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Odoo Web (MOVED TO GITHUB)
Fix Released
High
Unassigned

Bug Description

Hi!

When I use a float field in a view with french language selected, the decimal separator displayed is a comma, as expected. However when I edit the field, if I write something like 12,00 it is interpreted as 1200, whereas 12.00 is interpreted as 12,00.

Cheers!

Related branches

description: updated
Revision history for this message
Xavier (Open ERP) (xmo-deactivatedaccount) wrote :

I can't reproduce this issue, could you give a view where you can see this issue? And your browser and OS? I tried to alter the "revenu estimé" and "probabilité" fields in an "Opportunité" (both are float fields), and I get the expected behavior, "12,00" is treated as 1200/100, as expected, and correctly re-displayed as "12,00"

Changed in openerp-web:
status: New → Incomplete
Revision history for this message
Francois Degrave (fde-be) wrote :

It happens in a view I created, I can try to find one in the official addons. It is in a one2many field, displayed as an editable tree.

Changed in openerp-web:
status: Incomplete → New
Revision history for this message
Xavier (Open ERP) (xmo-deactivatedaccount) wrote :

> It happens in a view I created, I can try to find one in the official addons.
> It is in a one2many field, displayed as an editable tree.

The bill of material form view has such a thing (the components field), I could not reproduce the issue: after configuring the database to "french", both input and output are correct. Marking the bug as invalid, don't hesitate reopening it if you find a way to repro.

Changed in openerp-web:
status: New → Invalid
Revision history for this message
Francois Degrave (fde-be) wrote :

In fact, it happens for me in fr_BE, but not in fr...

Changed in openerp-web:
status: Invalid → New
Revision history for this message
Roberto López López (bergensk) wrote :

The decimal separator is defined as a dot for fr_be language. The web client behavior is correct, if you prefer a comma you could change it in your settings.

Changed in openerp-web:
status: New → Invalid
Revision history for this message
Francois Degrave (fde-be) wrote :

"The decimal separator is defined as a dot for fr_be language."
No, it is not.

Changed in openerp-web:
status: Invalid → New
Revision history for this message
Francois Degrave (fde-be) wrote :

>>> locale.setlocale(locale.LC_ALL, 'fr_BE.UTF-8')
'fr_BE.UTF-8'
>>> locale.localeconv()['decimal_point']
','

summary: - Float fields and decimal separator in french
+ Float fields and decimal separator in fr_BE
Changed in openerp-web:
importance: Undecided → High
status: New → In Progress
Revision history for this message
Xavier (Open ERP) (xmo-deactivatedaccount) wrote :

Should be fixed in trunk as of revision <email address hidden>

Changed in openerp-web:
status: In Progress → Fix Released
Revision history for this message
Francois Degrave (fde-be) wrote :

OK, nice! Thanks!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.