Arthur de Jong

Open Source / Free Software developer

summaryrefslogtreecommitdiffstats
path: root/django/utils/formats.py
Commit message (Collapse)AuthorAgeFilesLines
* Removed some obsolete absolute_imports.Tim Graham2015-02-091-3/+0
|
* Sorted imports with isort; refs #23860.Tim Graham2015-02-061-6/+8
|
* Fixed #24149 -- Normalized tuple settings to lists.darkryder2015-02-031-4/+4
|
* Replaced set([foo, ...]) by {foo, ...} literals. Refs PR ↵Thomas Chaumeny2014-09-281-2/+2
| | | | | | 3282. Thanks Collin Anderson for the review.
* Fixed #22171 -- Improved sanitize_separators clevernessClaude Paroz2014-08-181-3/+7
| | | | | Thanks Klaas van Schelven for the report and Tim Graham for the review.
* Fixed #20477: Allowed list of modules for FORMAT_MODULE_PATHMartin Brochhaus2014-05-211-15/+23
| | | | | | | | | Previously the FORMAT_MODULE_PATH setting only accepted one string (dotted module path). A feature has been added to also allow a list of strings. This is useful when using several reusable third party apps that define new formats. We can now use them all and we can even override some of the formats by providing a project-wide format module.
* Revert "Fixed #20477: Allowed ↵Tim Graham2014-05-191-9/+4
| | | | | | settings.FORMAT_MODULE_PATH to be a list of modules." This reverts commit 950b6de16ac2f8135612f2ed5984c090dd8e4dcf.
* Fixed #20477: Allowed settings.FORMAT_MODULE_PATH to be ↵Martin Brochhaus2014-05-191-4/+9
| | | | | | | | | | | a list of modules. Previously the FORMAT_MODULE_PATH setting only accepted one string (dotted module path). This is useful when using several reusable third party apps that define new formats. We can now use them all and we can even override some of the formats by providing a project-wide format module.
* Correct flake8 E302 violationsRay Ashman Jr2013-11-031-0/+10
|
* Moved a settings usage up the stack in utils/formats.py ↵Adrian Holovaty2013-09-071-4/+4
| | | | #unsettings
* Avoid importing the deprecated `django.utils.importlib` ↵Simon Charette2013-08-201-0/+2
| | | | package.
* Deprecated django.utils.importlibClaude Paroz2013-07-291-2/+2
| | | | This was a shim for pre-Python 2.7 support.
* Fixed #19917 -- Added microseconds in default ↵Claude Paroz2013-03-021-1/+1
| | | | | | TIME_INPUT_FORMATS Thanks minddust for the report.
* Improved input sanitizing with thousand separatorsClaude Paroz2013-02-151-11/+13
| | | | | | | For languages with non-breaking space as thousand separator, standard space input should also be allowed, as few people know how to enter non-breaking space on keyboards. Refs #17217. Thanks Alexey Boriskin for the report and initial patch.
* Fixed #19015 -- Add ISO input formats to all formatsClaude Paroz2012-12-011-0/+16
|
* Replaced some smart_xxx by force_xxx equivalentClaude Paroz2012-08-301-5/+5
| | | | | smart_str/smart_text should only be used when a potential lazy string should be preserved in the result of the function call.
* [py3] Replaced unicode/str by six.text_type/bytes.Aymeric Augustin2012-07-221-2/+2
|
* [py3] Replaced basestring by six.string_types.Aymeric Augustin2012-07-221-1/+1
|
* [py3] Removed longs.Aymeric Augustin2012-07-221-2/+3
|
* Fixed 16938 -- Ensured that the active locale's formats ↵Julien Phalip2011-10-201-1/+6
| | | | | | take precedence over the default settings even if they would be interpreted as False in a conditional test (e.g. 0 or empty string). Thanks to pikerr for the report and initial patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@17017 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #16909 -- Pass language to get_format_modules when ↵Jannis Leidel2011-09-221-3/+4
| | | | | | calling it from get_format to make sure the correct module is returned. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16884 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #16404 -- Fixed a regression in the localization ↵Jannis Leidel2011-09-081-1/+2
| | | | | | changes in the humanize app made in r16168. Thanks, grepsd@gmail.com. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16726 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #5714 -- Strip whitespaces around date and time ↵Jannis Leidel2011-05-011-2/+5
| | | | | | form field values before converting it to a native type. Thanks to SmileyChris for the initial patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16137 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14824 -- Corrected the handling of formats when ↵Russell Keith-Magee2011-02-041-1/+11
| | | | | | USE_L10N is disabled. Thanks to nullie for the report and initial patch, and to idle for the separate report with helpful debug info. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15404 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed stability of data input/output L10N format modules ↵Ramiro Morales2011-02-031-2/+2
| | | | | | priority order. Thanks tonnzor for the report and fix. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15402 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #15024 -- Ensure that choice of L10N format module ↵Ramiro Morales2011-01-131-1/+3
| | | | | | used is stable given a stable setup of format modules in ll/ and ll_CC/ dirs. Thanks David Reynolds for the report and suggestions leading to the solution. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15183 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14807 -- Ensure that boolean values aren't ↵Russell Keith-Magee2010-12-041-1/+4
| | | | | | localized as T.rue and Fa.lse because of the thousand separator. Thanks to vanschelven for the report and patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14804 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14181 -- Added a template tag and filters to ↵Russell Keith-Magee2010-10-291-17/+32
| | | | | | allow localization to be disabled in a template. Thanks to Benjamin Wohlwend for the work on the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14395 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14053 -- Also localize long integers. Thanks, ↵Jannis Leidel2010-09-271-2/+2
| | | | | | David Danier. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13920 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14290 -- Made format localization faster by ↵Jannis Leidel2010-09-271-30/+50
| | | | | | caching the format modules. Thanks, Teemu Kurppa and Anssi Kääriäinen for the report and initial patches. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13898 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #13702 -- Made sure to actually fall back to the ↵Jannis Leidel2010-09-121-10/+10
| | | | | | l10n format strings provided in the settings, when disabled. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13770 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12779 - Sanitize numeric form field input ↵Jannis Leidel2010-03-011-0/+19
| | | | | | according to decimal and thousand separator settings. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12625 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12777 - Localize decimal fields correctly. ↵Jannis Leidel2010-02-051-5/+3
| | | | | | Thanks, Florian Apolloner git-svn-id: http://code.djangoproject.com/svn/django/trunk@12382 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12435 - Handle Unicode characters in format ↵Jannis Leidel2010-01-011-0/+1
| | | | | | strings correctly. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12057 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12472 - Correctly show TimeFields values when ↵Jannis Leidel2010-01-011-1/+7
| | | | | | using locale-aware formatting. Thanks to Ramiro Morales for providing the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12050 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12454 - Added support for localized formats to ↵Jannis Leidel2009-12-301-2/+4
| | | | | | admin date and time widgets. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12030 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12444 - Date based widgets now correctly handle ↵Jannis Leidel2009-12-301-18/+25
| | | | | | input values when using locale-aware formatting. Also fixes #7656. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12029 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #7980 - Improved i18n framework to support locale ↵Jannis Leidel2009-12-221-0/+97
aware formatting (dates and numbers) and form processing. Thanks to Marc Garcia for working on this during his Google Summer of Code 2009! Additionally fixes #1061, #2203, #3940, #5526, #6449, #6231, #6693, #6783, #9366 and #10891. git-svn-id: http://code.djangoproject.com/svn/django/trunk@11964 bcc190cf-cafb-0310-a4f2-bffc1f526a37