#142 Localized date improved
* fixes bug where created timestamp has been displayed on modified attribute on detail views * enhances localized date and datetime rendering * reorders sub menus in user's profile hub
This commit is contained in:
@@ -11,6 +11,7 @@ https://docs.djangoproject.com/en/3.1/ref/settings/
|
||||
"""
|
||||
import os
|
||||
from django.utils.translation import gettext_lazy as _
|
||||
from django.conf.locale.de import formats as de_formats
|
||||
|
||||
# Build paths inside the project like this: BASE_DIR / 'subdir'.
|
||||
BASE_DIR = os.path.dirname(
|
||||
@@ -162,9 +163,15 @@ LANGUAGES = [
|
||||
|
||||
USE_THOUSAND_SEPARATOR = True
|
||||
|
||||
# Regular python relevant date/datetime formatting
|
||||
DEFAULT_DATE_TIME_FORMAT = '%d.%m.%Y %H:%M:%S'
|
||||
DEFAULT_DATE_FORMAT = '%d.%m.%Y'
|
||||
|
||||
# Template relevant date/datetime formatting
|
||||
# See the Note on here: https://docs.djangoproject.com/en/3.2/ref/templates/builtins/#date
|
||||
de_formats.DATETIME_FORMAT = "d.m.Y, H:i"
|
||||
de_formats.DATE_FORMAT = "d.m.Y"
|
||||
|
||||
TIME_ZONE = 'Europe/Berlin'
|
||||
|
||||
USE_I18N = True
|
||||
|
||||
Reference in New Issue
Block a user