1
0
mirror of https://github.com/django/django.git synced 2025-10-31 09:41:08 +00:00

Fixed #19567 -- Added JavaScriptCatalog and JSONCatalog class-based views

Thanks Cristiano Coelho and Tim Graham for the reviews.
This commit is contained in:
Claude Paroz
2016-03-07 21:52:08 +01:00
parent 79a091820f
commit de40cfbe74
11 changed files with 591 additions and 40 deletions

View File

@@ -277,6 +277,14 @@ Internationalization
Content) for AJAX requests when there is no ``next`` parameter in ``POST`` or
``GET``.
* The :class:`~django.views.i18n.JavaScriptCatalog` and
:class:`~django.views.i18n.JSONCatalog` class-based views supersede the
deprecated ``javascript_catalog()`` and ``json_catalog()`` function-based
views. The new views are almost equivalent to the old ones except that by
default the new views collect all JavaScript strings in the ``djangojs``
translation domain from all installed apps rather than only the JavaScript
strings from :setting:`LOCALE_PATHS`.
Management Commands
~~~~~~~~~~~~~~~~~~~
@@ -929,6 +937,10 @@ Miscellaneous
``Model._meta.add_field()`` are deprecated in favor of ``private_only``
and ``private``, respectively.
* The ``javascript_catalog()`` and ``json_catalog()`` views are deprecated in
favor of class-based views :class:`~django.views.i18n.JavaScriptCatalog`
and :class:`~django.views.i18n.JSONCatalog`.
.. _removed-features-1.10:
Features removed in 1.10