From 4feeab35e40b7ffe57a85cbf8a7050701bb29473 Mon Sep 17 00:00:00 2001 From: Raphael Michel Date: Sat, 1 Oct 2016 12:32:07 +0200 Subject: [PATCH] Force ISO8601 date format for locale 'en' --- src/pretix/helpers/formats/__init__.py | 0 src/pretix/helpers/formats/en/__init__.py | 0 src/pretix/helpers/formats/en/formats.py | 2 ++ src/pretix/settings.py | 4 ++++ 4 files changed, 6 insertions(+) create mode 100644 src/pretix/helpers/formats/__init__.py create mode 100644 src/pretix/helpers/formats/en/__init__.py create mode 100644 src/pretix/helpers/formats/en/formats.py diff --git a/src/pretix/helpers/formats/__init__.py b/src/pretix/helpers/formats/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/pretix/helpers/formats/en/__init__.py b/src/pretix/helpers/formats/en/__init__.py new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/pretix/helpers/formats/en/formats.py b/src/pretix/helpers/formats/en/formats.py new file mode 100644 index 0000000000..81452fe12f --- /dev/null +++ b/src/pretix/helpers/formats/en/formats.py @@ -0,0 +1,2 @@ +SHORT_DATE_FORMAT = 'Y-m-d' +SHORT_DATETIME_FORMAT = 'Y-d-m P' diff --git a/src/pretix/settings.py b/src/pretix/settings.py index b561ccff43..fc01dedfd0 100644 --- a/src/pretix/settings.py +++ b/src/pretix/settings.py @@ -232,6 +232,10 @@ LOCALE_PATHS = ( os.path.join(os.path.dirname(__file__), 'locale'), ) +FORMAT_MODULE_PATH = [ + 'pretix.helpers.formats', +] + LANGUAGES = [ ('en', _('English')), ('de', _('German')),