mirror of
https://github.com/django/django.git
synced 2025-07-04 09:49:12 +00:00
the i18n middleware now stores the chosen language in the request
so that view code can know what language is chosen (for example to select the right content field from the model if your model supports multiple languages) git-svn-id: http://code.djangoproject.com/svn/django/branches/i18n@744 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
80e450ee2d
commit
96e37129ba
@ -34,5 +34,7 @@ class LocaleMiddleware:
|
||||
|
||||
app = findapp(view_func.__module__)
|
||||
|
||||
request.LANGUAGE_CODE = lang
|
||||
|
||||
translation.activate(app, lang)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user