{{{
context = {"exfloat": 1000.01, "exint": 1000}
[...]
{{ exfloat|intcomma }} # output: 1.000,01 -> correct
{{ exfloat|floatformat:2|intcomma }} # output: 1,000,01 -> wrong
{{ exfloat|floatformat:-2|intcomma }} # output: 1,000,01 -> wrong
{{ exint|intcomma }} # output: 1.000 -> correct
{{ exint|floatformat:2|intcomma }} # output: 1,000,00 -> wrong
{{ exint|floatformat:-2|intcomma }} # output: 1.000 -> correct
}}}
Localization is German, no possible setting following the documentation is
fixing this.
--
Ticket URL: <https://code.djangoproject.com/ticket/33771>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* status: new => closed
* resolution: => fixed
Comment:
The solution is "2g" for example, as described in documentation. Referal
to floatformat on localizing sites containing information about thousand
separator may be advised. Found the answer after looking up the
implementation and was wondering, why the docs didn't state that (but
found it now).
--
Ticket URL: <https://code.djangoproject.com/ticket/33771#comment:1>
* resolution: fixed => invalid
--
Ticket URL: <https://code.djangoproject.com/ticket/33771#comment:2>