diff options
| author | Jannis Leidel <jannis@leidel.info> | 2010-03-20 15:26:41 +0000 |
|---|---|---|
| committer | Jannis Leidel <jannis@leidel.info> | 2010-03-20 15:26:41 +0000 |
| commit | 10d4094b86721da690fcb3c9bc89b7a0089dfd5c (patch) | |
| tree | 45b76c9e858d994370379b3ce5cef0d0753fdb1d /django/utils/numberformat.py | |
| parent | bfa080f402ddfc383abdbac96fa198e7f2f8ec59 (diff) | |
Fixed #13054 - Only apply grouping to integer part of numbers if explicitly wanted. Thanks, Ramiro Morales.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@12816 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/utils/numberformat.py')
| -rw-r--r-- | django/utils/numberformat.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/django/utils/numberformat.py b/django/utils/numberformat.py index 78ecb2fbdb..129c27f4da 100644 --- a/django/utils/numberformat.py +++ b/django/utils/numberformat.py @@ -30,7 +30,7 @@ def format(number, decimal_sep, decimal_pos, grouping=0, thousand_sep=''): dec_part = dec_part + ('0' * (decimal_pos - len(dec_part))) if dec_part: dec_part = decimal_sep + dec_part # grouping - if settings.USE_THOUSAND_SEPARATOR and grouping: + if settings.USE_L10N and settings.USE_THOUSAND_SEPARATOR and grouping: int_part_gd = '' for cnt, digit in enumerate(int_part[::-1]): if cnt and not cnt % grouping: |
