5 | | the bug can be fixed by converting the Decimal to a fixed point value in admin/utils.py: |
6 | | |
7 | | |
8 | | {{{ |
9 | | @@ -375,7 +375,7 @@ def display_for_field(value, field): |
10 | | elif isinstance(field, (models.DateField, models.TimeField)): |
11 | | return formats.localize(value) |
12 | | elif isinstance(field, models.DecimalField): |
13 | | - return formats.number_format(value, field.decimal_places) |
14 | | + return formats.number_format(format(value, "f"), field.decimal_places) |
15 | | elif isinstance(field, models.FloatField): |
16 | | return formats.number_format(value) |
17 | | else: |
18 | | }}} |
| 5 | the bug can be fixed by converting the Decimal to a fixed point value in django.utils.numberformat.format: |