This is a note to my and @agitator's future self and anyone to whom it may concerns.
I have a
year field and Plone renders it in German as as
My customer dislikes the dot in there.
z3c.form uses a dataconverter to localize the output of number fields, such as
At the end, the dataconverter uses the locale formatters from
zope.i18n.locales and those are having inheriting XML-definitions for
The definitions are loaded there.
So how to change them?
- copy the xml-file from
zope.i18n.locales.datato your projects root,
- for my case change the numbers group value to empty:
... <numbers> <symbols> <decimal>.</decimal> <group></group> ...
- in your projects
from zope.i18n.locales import locales from zope.i18n.locales.xmlfactory import LocaleFactory import os locales._locales["de", "AT", None] = LocaleFactory( os.path.join(os.path.dirname(__file__), "de_AT_patched.xml") )()