mirror of
https://github.com/encode/django-rest-framework.git
synced 2024-11-22 09:36:49 +03:00
Deployed 2da473c8
with MkDocs version: 1.1.2
This commit is contained in:
parent
e1b86272eb
commit
c8d45f9272
4
404.html
4
404.html
|
@ -293,6 +293,10 @@
|
|||
<a href="/community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="/community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="/community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -658,8 +662,8 @@ print(token.key)
|
|||
<hr />
|
||||
<p><strong>Note:</strong> If you use <code>TokenAuthentication</code> in production you must ensure that your API is only available over <code>https</code>.</p>
|
||||
<hr />
|
||||
<h4 id="generating-tokens"><a class="toclink" href="#generating-tokens">Generating Tokens</a></h4>
|
||||
<h5 id="by-using-signals"><a class="toclink" href="#by-using-signals">By using signals</a></h5>
|
||||
<h3 id="generating-tokens"><a class="toclink" href="#generating-tokens">Generating Tokens</a></h3>
|
||||
<h4 id="by-using-signals"><a class="toclink" href="#by-using-signals">By using signals</a></h4>
|
||||
<p>If you want every user to have an automatically generated Token, you can simply catch the User's <code>post_save</code> signal.</p>
|
||||
<pre><code>from django.conf import settings
|
||||
from django.db.models.signals import post_save
|
||||
|
@ -679,7 +683,7 @@ from rest_framework.authtoken.models import Token
|
|||
for user in User.objects.all():
|
||||
Token.objects.get_or_create(user=user)
|
||||
</code></pre>
|
||||
<h5 id="by-exposing-an-api-endpoint"><a class="toclink" href="#by-exposing-an-api-endpoint">By exposing an api endpoint</a></h5>
|
||||
<h4 id="by-exposing-an-api-endpoint"><a class="toclink" href="#by-exposing-an-api-endpoint">By exposing an api endpoint</a></h4>
|
||||
<p>When using <code>TokenAuthentication</code>, you may want to provide a mechanism for clients to obtain a token given the username and password. REST framework provides a built-in view to provide this behaviour. To use it, add the <code>obtain_auth_token</code> view to your URLconf:</p>
|
||||
<pre><code>from rest_framework.authtoken import views
|
||||
urlpatterns += [
|
||||
|
@ -718,7 +722,7 @@ class CustomAuthToken(ObtainAuthToken):
|
|||
path('api-token-auth/', CustomAuthToken.as_view())
|
||||
]
|
||||
</code></pre>
|
||||
<h5 id="with-django-admin"><a class="toclink" href="#with-django-admin">With Django admin</a></h5>
|
||||
<h4 id="with-django-admin"><a class="toclink" href="#with-django-admin">With Django admin</a></h4>
|
||||
<p>It is also possible to create Tokens manually through the admin interface. In case you are using a large user base, we recommend that you monkey patch the <code>TokenAdmin</code> class customize it to your needs, more specifically by declaring the <code>user</code> field as <code>raw_field</code>.</p>
|
||||
<p><code>your_app/admin.py</code>:</p>
|
||||
<pre><code>from rest_framework.authtoken.admin import TokenAdmin
|
||||
|
@ -802,7 +806,7 @@ class ExampleAuthentication(authentication.BaseAuthentication):
|
|||
<p><a href="https://github.com/James1345/django-rest-knox">Django-rest-knox</a> library provides models and views to handle token-based authentication in a more secure and extensible way than the built-in TokenAuthentication scheme - with Single Page Applications and Mobile clients in mind. It provides per-client tokens, and views to generate them when provided some other authentication (usually basic authentication), to delete the token (providing a server enforced logout) and to delete all tokens (logs out all clients that a user is logged into).</p>
|
||||
<h2 id="django-oauth-toolkit"><a class="toclink" href="#django-oauth-toolkit">Django OAuth Toolkit</a></h2>
|
||||
<p>The <a href="https://github.com/evonove/django-oauth-toolkit">Django OAuth Toolkit</a> package provides OAuth 2.0 support and works with Python 3.4+. The package is maintained by <a href="https://github.com/jazzband/">jazzband</a> and uses the excellent <a href="https://github.com/idan/oauthlib">OAuthLib</a>. The package is well documented, and well supported and is currently our <strong>recommended package for OAuth 2.0 support</strong>.</p>
|
||||
<h4 id="installation-configuration"><a class="toclink" href="#installation-configuration">Installation & configuration</a></h4>
|
||||
<h3 id="installation-configuration"><a class="toclink" href="#installation-configuration">Installation & configuration</a></h3>
|
||||
<p>Install using <code>pip</code>.</p>
|
||||
<pre><code>pip install django-oauth-toolkit
|
||||
</code></pre>
|
||||
|
@ -822,7 +826,7 @@ REST_FRAMEWORK = {
|
|||
<h2 id="django-rest-framework-oauth"><a class="toclink" href="#django-rest-framework-oauth">Django REST framework OAuth</a></h2>
|
||||
<p>The <a href="https://jpadilla.github.io/django-rest-framework-oauth/">Django REST framework OAuth</a> package provides both OAuth1 and OAuth2 support for REST framework.</p>
|
||||
<p>This package was previously included directly in the REST framework but is now supported and maintained as a third-party package.</p>
|
||||
<h4 id="installation-configuration_1"><a class="toclink" href="#installation-configuration_1">Installation & configuration</a></h4>
|
||||
<h3 id="installation-configuration_1"><a class="toclink" href="#installation-configuration_1">Installation & configuration</a></h3>
|
||||
<p>Install the package using <code>pip</code>.</p>
|
||||
<pre><code>pip install djangorestframework-oauth
|
||||
</code></pre>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -486,6 +490,16 @@
|
|||
</li>
|
||||
|
||||
|
||||
<li class="main">
|
||||
<a href="#third-party-packages">Third party packages</a>
|
||||
</li>
|
||||
|
||||
|
||||
<li>
|
||||
<a href="#drf-standardized-errors">DRF Standardized Errors</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<div class="promo">
|
||||
<hr/>
|
||||
|
@ -682,6 +696,10 @@ API-only application.)</p>
|
|||
<p>Set as <code>handler400</code>:</p>
|
||||
<pre><code>handler400 = 'rest_framework.exceptions.bad_request'
|
||||
</code></pre>
|
||||
<h1 id="third-party-packages"><a class="toclink" href="#third-party-packages">Third party packages</a></h1>
|
||||
<p>The following third-party packages are also available.</p>
|
||||
<h2 id="drf-standardized-errors"><a class="toclink" href="#drf-standardized-errors">DRF Standardized Errors</a></h2>
|
||||
<p>The <a href="https://github.com/ghazi-git/drf-standardized-errors">drf-standardized-errors</a> package provides an exception handler that generates the same format for all 4xx and 5xx responses. It is a drop-in replacement for the default exception handler and allows customizing the error response format without rewriting the whole exception handler. The standardized error response format is easier to document and easier to handle by API consumers.</p>
|
||||
|
||||
|
||||
</div> <!--/span-->
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -427,10 +431,6 @@
|
|||
<a href="#booleanfield">BooleanField</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#nullbooleanfield">NullBooleanField</a>
|
||||
</li>
|
||||
|
||||
|
||||
<li class="main">
|
||||
<a href="#string-fields">String fields</a>
|
||||
|
@ -741,10 +741,6 @@ explicitly declare the <code>BooleanField</code> on the serializer class, or use
|
|||
<code>extra_kwargs</code> option to set the <code>required</code> flag.</p>
|
||||
<p>Corresponds to <code>django.db.models.fields.BooleanField</code>.</p>
|
||||
<p><strong>Signature:</strong> <code>BooleanField()</code></p>
|
||||
<h2 id="nullbooleanfield"><a class="toclink" href="#nullbooleanfield">NullBooleanField</a></h2>
|
||||
<p>A boolean representation that also accepts <code>None</code> as a valid value.</p>
|
||||
<p>Corresponds to <code>django.db.models.fields.NullBooleanField</code>.</p>
|
||||
<p><strong>Signature:</strong> <code>NullBooleanField()</code></p>
|
||||
<hr />
|
||||
<h1 id="string-fields"><a class="toclink" href="#string-fields">String fields</a></h1>
|
||||
<h2 id="charfield"><a class="toclink" href="#charfield">CharField</a></h2>
|
||||
|
@ -848,8 +844,6 @@ explicitly declare the <code>BooleanField</code> on the serializer class, or use
|
|||
<p>And to validate numbers up to anything less than one billion with a resolution of 10 decimal places:</p>
|
||||
<pre><code>serializers.DecimalField(max_digits=19, decimal_places=10)
|
||||
</code></pre>
|
||||
<p>This field also takes an optional argument, <code>coerce_to_string</code>. If set to <code>True</code> the representation will be output as a string. If set to <code>False</code> the representation will be left as a <code>Decimal</code> instance and the final representation will be determined by the renderer.</p>
|
||||
<p>If unset, this will default to the same value as the <code>COERCE_DECIMAL_TO_STRING</code> setting, which is <code>True</code> unless set otherwise.</p>
|
||||
<hr />
|
||||
<h1 id="date-and-time-fields"><a class="toclink" href="#date-and-time-fields">Date and time fields</a></h1>
|
||||
<h2 id="datetimefield"><a class="toclink" href="#datetimefield">DateTimeField</a></h2>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -596,7 +600,7 @@ class UserList(generics.ListCreateAPIView):
|
|||
<ul>
|
||||
<li><code>queryset</code> - The queryset that should be used for returning objects from this view. Typically, you must either set this attribute, or override the <code>get_queryset()</code> method. If you are overriding a view method, it is important that you call <code>get_queryset()</code> instead of accessing this property directly, as <code>queryset</code> will get evaluated once, and those results will be cached for all subsequent requests.</li>
|
||||
<li><code>serializer_class</code> - The serializer class that should be used for validating and deserializing input, and for serializing output. Typically, you must either set this attribute, or override the <code>get_serializer_class()</code> method.</li>
|
||||
<li><code>lookup_field</code> - The model field that should be used to for performing object lookup of individual model instances. Defaults to <code>'pk'</code>. Note that when using hyperlinked APIs you'll need to ensure that <em>both</em> the API views <em>and</em> the serializer classes set the lookup fields if you need to use a custom value.</li>
|
||||
<li><code>lookup_field</code> - The model field that should be used for performing object lookup of individual model instances. Defaults to <code>'pk'</code>. Note that when using hyperlinked APIs you'll need to ensure that <em>both</em> the API views <em>and</em> the serializer classes set the lookup fields if you need to use a custom value.</li>
|
||||
<li><code>lookup_url_kwarg</code> - The URL keyword argument that should be used for object lookup. The URL conf should include a keyword argument corresponding to this value. If unset this defaults to using the same value as <code>lookup_field</code>.</li>
|
||||
</ul>
|
||||
<p><strong>Pagination</strong>:</p>
|
||||
|
@ -707,7 +711,7 @@ class UserList(generics.ListCreateAPIView):
|
|||
<p>If the request data provided for creating the object was invalid, a <code>400 Bad Request</code> response will be returned, with the error details as the body of the response.</p>
|
||||
<h2 id="retrievemodelmixin"><a class="toclink" href="#retrievemodelmixin">RetrieveModelMixin</a></h2>
|
||||
<p>Provides a <code>.retrieve(request, *args, **kwargs)</code> method, that implements returning an existing model instance in a response.</p>
|
||||
<p>If an object can be retrieved this returns a <code>200 OK</code> response, with a serialized representation of the object as the body of the response. Otherwise it will return a <code>404 Not Found</code>.</p>
|
||||
<p>If an object can be retrieved this returns a <code>200 OK</code> response, with a serialized representation of the object as the body of the response. Otherwise, it will return a <code>404 Not Found</code>.</p>
|
||||
<h2 id="updatemodelmixin"><a class="toclink" href="#updatemodelmixin">UpdateModelMixin</a></h2>
|
||||
<p>Provides a <code>.update(request, *args, **kwargs)</code> method, that implements updating and saving an existing model instance.</p>
|
||||
<p>Also provides a <code>.partial_update(request, *args, **kwargs)</code> method, which is similar to the <code>update</code> method, except that all fields for the update will be optional. This allows support for HTTP <code>PATCH</code> requests.</p>
|
||||
|
@ -771,7 +775,7 @@ class UserList(generics.ListCreateAPIView):
|
|||
queryset = self.filter_queryset(queryset) # Apply any filter backends
|
||||
filter = {}
|
||||
for field in self.lookup_fields:
|
||||
if self.kwargs[field]: # Ignore empty fields.
|
||||
if self.kwargs.get(field): # Ignore empty fields.
|
||||
filter[field] = self.kwargs[field]
|
||||
obj = get_object_or_404(queryset, **filter) # Lookup the object
|
||||
self.check_object_permissions(self.request, obj)
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -656,7 +660,7 @@ class ExampleView(APIView):
|
|||
<p>The <code>IsAuthenticatedOrReadOnly</code> will allow authenticated users to perform any request. Requests for unauthorised users will only be permitted if the request method is one of the "safe" methods; <code>GET</code>, <code>HEAD</code> or <code>OPTIONS</code>.</p>
|
||||
<p>This permission is suitable if you want to your API to allow read permissions to anonymous users, and only allow write permissions to authenticated users.</p>
|
||||
<h2 id="djangomodelpermissions"><a class="toclink" href="#djangomodelpermissions">DjangoModelPermissions</a></h2>
|
||||
<p>This permission class ties into Django's standard <code>django.contrib.auth</code> <a href="https://docs.djangoproject.com/en/stable/topics/auth/customizing/#custom-permissions">model permissions</a>. This permission must only be applied to views that have a <code>.queryset</code> property or <code>get_queryset()</code> method. Authorization will only be granted if the user <em>is authenticated</em> and has the <em>relevant model permissions</em> assigned.</p>
|
||||
<p>This permission class ties into Django's standard <code>django.contrib.auth</code> <a href="https://docs.djangoproject.com/en/stable/topics/auth/customizing/#custom-permissions">model permissions</a>. This permission must only be applied to views that have a <code>.queryset</code> property or <code>get_queryset()</code> method. Authorization will only be granted if the user <em>is authenticated</em> and has the <em>relevant model permissions</em> assigned. The appropriate model is determined by checking <code>get_queryset().model</code> or <code>queryset.model</code>.</p>
|
||||
<ul>
|
||||
<li><code>POST</code> requests require the user to have the <code>add</code> permission on the model.</li>
|
||||
<li><code>PUT</code> and <code>PATCH</code> requests require the user to have the <code>change</code> permission on the model.</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -558,7 +562,7 @@ urlpatterns += router.urls
|
|||
path('api/', include((router.urls, 'app_name'), namespace='instance_name')),
|
||||
]
|
||||
</code></pre>
|
||||
<p>See Django's <a href="https://docs.djangoproject.com/en/1.11/topics/http/urls/#url-namespaces">URL namespaces docs</a> and the <a href="https://docs.djangoproject.com/en/2.0/ref/urls/#include"><code>include</code> API reference</a> for more details.</p>
|
||||
<p>See Django's <a href="https://docs.djangoproject.com/en/4.0/topics/http/urls/#url-namespaces">URL namespaces docs</a> and the <a href="https://docs.djangoproject.com/en/4.0/ref/urls/#include"><code>include</code> API reference</a> for more details.</p>
|
||||
<hr />
|
||||
<p><strong>Note</strong>: If using namespacing with hyperlinked serializers you'll also need to ensure that any <code>view_name</code> parameters
|
||||
on the serializers correctly reflect the namespace. In the examples above you'd need to include a parameter such as
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -590,7 +594,7 @@ do so like so:</p>
|
|||
<code>rest_framework.schemas.openapi.SchemaGenerator</code> and provide your subclass
|
||||
as an argument to the <code>generateschema</code> command or <code>get_schema_view()</code> helper
|
||||
function.</p>
|
||||
<h3 id="get_schemaself-request"><a class="toclink" href="#get_schemaself-request">get_schema(self, request)</a></h3>
|
||||
<h3 id="get_schemaself-requestnone-publicfalse"><a class="toclink" href="#get_schemaself-requestnone-publicfalse">get_schema(self, request=None, public=False)</a></h3>
|
||||
<p>Returns a dictionary that represents the OpenAPI schema:</p>
|
||||
<pre><code>generator = SchemaGenerator(title='Stock Prices API')
|
||||
schema = generator.get_schema()
|
||||
|
@ -700,6 +704,8 @@ serializers.</p>
|
|||
<h4 id="get_component_name"><a class="toclink" href="#get_component_name"><code>get_component_name()</code></a></h4>
|
||||
<p>Computes the component's name from the serializer.</p>
|
||||
<p>You may see warnings if your API has duplicate component names. If so you can override <code>get_component_name()</code> or pass the <code>component_name</code> <code>__init__()</code> kwarg (see below) to provide different names.</p>
|
||||
<h4 id="get_reference"><a class="toclink" href="#get_reference"><code>get_reference()</code></a></h4>
|
||||
<p>Returns a reference to the serializer component. This may be useful if you override <code>get_schema()</code>.</p>
|
||||
<h4 id="map_serializer"><a class="toclink" href="#map_serializer"><code>map_serializer()</code></a></h4>
|
||||
<p>Maps serializers to their OpenAPI representations.</p>
|
||||
<p>Most serializers should conform to the standard OpenAPI <code>object</code> type, but you may
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -1120,7 +1124,7 @@ AccountSerializer():
|
|||
<p>A mapping of Django model fields to REST framework serializer fields. You can override this mapping to alter the default serializer fields that should be used for each model field.</p>
|
||||
<h3 id="serializer_related_field"><a class="toclink" href="#serializer_related_field"><code>.serializer_related_field</code></a></h3>
|
||||
<p>This property should be the serializer field class, that is used for relational fields by default.</p>
|
||||
<p>For <code>ModelSerializer</code> this defaults to <code>PrimaryKeyRelatedField</code>.</p>
|
||||
<p>For <code>ModelSerializer</code> this defaults to <code>serializers.PrimaryKeyRelatedField</code>.</p>
|
||||
<p>For <code>HyperlinkedModelSerializer</code> this defaults to <code>serializers.HyperlinkedRelatedField</code>.</p>
|
||||
<h3 id="serializer_url_field"><a class="toclink" href="#serializer_url_field"><code>.serializer_url_field</code></a></h3>
|
||||
<p>The serializer field class that should be used for any <code>url</code> field on the serializer.</p>
|
||||
|
@ -1323,7 +1327,7 @@ class BookSerializer(serializers.Serializer):
|
|||
</ul>
|
||||
<p>Because this class provides the same interface as the <code>Serializer</code> class, you can use it with the existing generic class-based views exactly as you would for a regular <code>Serializer</code> or <code>ModelSerializer</code>.</p>
|
||||
<p>The only difference you'll notice when doing so is the <code>BaseSerializer</code> classes will not generate HTML forms in the browsable API. This is because the data they return does not include all the field information that would allow each field to be rendered into a suitable HTML input.</p>
|
||||
<h5 id="read-only-baseserializer-classes"><a class="toclink" href="#read-only-baseserializer-classes">Read-only <code>BaseSerializer</code> classes</a></h5>
|
||||
<h4 id="read-only-baseserializer-classes"><a class="toclink" href="#read-only-baseserializer-classes">Read-only <code>BaseSerializer</code> classes</a></h4>
|
||||
<p>To implement a read-only serializer using the <code>BaseSerializer</code> class, we just need to override the <code>.to_representation()</code> method. Let's take a look at an example using a simple Django model:</p>
|
||||
<pre><code>class HighScore(models.Model):
|
||||
created = models.DateTimeField(auto_now_add=True)
|
||||
|
@ -1352,7 +1356,7 @@ def all_high_scores(request):
|
|||
serializer = HighScoreSerializer(queryset, many=True)
|
||||
return Response(serializer.data)
|
||||
</code></pre>
|
||||
<h5 id="read-write-baseserializer-classes"><a class="toclink" href="#read-write-baseserializer-classes">Read-write <code>BaseSerializer</code> classes</a></h5>
|
||||
<h4 id="read-write-baseserializer-classes"><a class="toclink" href="#read-write-baseserializer-classes">Read-write <code>BaseSerializer</code> classes</a></h4>
|
||||
<p>To create a read-write serializer we first need to implement a <code>.to_internal_value()</code> method. This method returns the validated values that will be used to construct the object instance, and may raise a <code>serializers.ValidationError</code> if the supplied data is in an incorrect format.</p>
|
||||
<p>Once you've implemented <code>.to_internal_value()</code>, the basic validation API will be available on the serializer, and you will be able to use <code>.is_valid()</code>, <code>.validated_data</code> and <code>.errors</code>.</p>
|
||||
<p>If you want to also support <code>.save()</code> you'll need to also implement either or both of the <code>.create()</code> and <code>.update()</code> methods.</p>
|
||||
|
@ -1394,7 +1398,7 @@ def all_high_scores(request):
|
|||
</code></pre>
|
||||
<h4 id="creating-new-base-classes"><a class="toclink" href="#creating-new-base-classes">Creating new base classes</a></h4>
|
||||
<p>The <code>BaseSerializer</code> class is also useful if you want to implement new generic serializer classes for dealing with particular serialization styles, or for integrating with alternative storage backends.</p>
|
||||
<p>The following class is an example of a generic serializer that can handle coercing arbitrary objects into primitive representations.</p>
|
||||
<p>The following class is an example of a generic serializer that can handle coercing arbitrary complex objects into primitive representations.</p>
|
||||
<pre><code>class ObjectSerializer(serializers.BaseSerializer):
|
||||
"""
|
||||
A read-only serializer that coerces arbitrary complex objects
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
<a class="repo-link btn btn-inverse btn-small " rel="next" href="../3.12-announcement/">
|
||||
Next <i class="icon-arrow-right icon-white"></i>
|
||||
</a>
|
||||
<a class="repo-link btn btn-inverse btn-small " rel="prev" href="../release-notes/">
|
||||
<a class="repo-link btn btn-inverse btn-small " rel="prev" href="../3.14-announcement/">
|
||||
<i class="icon-arrow-left icon-white"></i> Previous
|
||||
</a>
|
||||
<a id="search_modal_show" class="repo-link btn btn-inverse btn-small" href="#mkdocs_search_modal" data-toggle="modal" data-target="#mkdocs_search_modal"><i class="icon-search icon-white"></i> Search</a>
|
||||
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li class="active" >
|
||||
<a href="./">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
555
community/3.14-announcement/index.html
Normal file
555
community/3.14-announcement/index.html
Normal file
|
@ -0,0 +1,555 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<meta charset="utf-8">
|
||||
<title>3.14 Announcement - Django REST framework</title>
|
||||
<link href="../../img/favicon.ico" rel="icon" type="image/x-icon">
|
||||
<link rel="canonical" href="https://www.django-rest-framework.org/community/3.14-announcement/" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="description" content="Django, API, REST, 3.14 Announcement">
|
||||
<meta name="author" content="Tom Christie">
|
||||
|
||||
<!-- Le styles -->
|
||||
<link href="../../css/prettify.css" rel="stylesheet">
|
||||
<link href="../../css/bootstrap.css" rel="stylesheet">
|
||||
<link href="../../css/bootstrap-responsive.css" rel="stylesheet">
|
||||
<link href="../../css/default.css" rel="stylesheet">
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
var _gaq = _gaq || [];
|
||||
_gaq.push(['_setAccount', 'UA-18852272-2']);
|
||||
_gaq.push(['_trackPageview']);
|
||||
|
||||
(function() {
|
||||
var ga = document.createElement('script');
|
||||
ga.type = 'text/javascript';
|
||||
ga.async = true;
|
||||
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
|
||||
var s = document.getElementsByTagName('script')[0];
|
||||
s.parentNode.insertBefore(ga, s);
|
||||
})();
|
||||
</script>
|
||||
|
||||
<style>
|
||||
#sidebarInclude img {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
#sidebarInclude a.promo {
|
||||
color: black;
|
||||
}
|
||||
@media (max-width: 767px) {
|
||||
div.promo {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body onload="prettyPrint()" class="-page">
|
||||
|
||||
<div class="wrapper">
|
||||
<div class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="navbar-inner">
|
||||
<div class="container-fluid">
|
||||
<a class="repo-link btn btn-primary btn-small" href="https://github.com/encode/django-rest-framework/tree/master">GitHub</a>
|
||||
<a class="repo-link btn btn-inverse btn-small " rel="next" href="../3.13-announcement/">
|
||||
Next <i class="icon-arrow-right icon-white"></i>
|
||||
</a>
|
||||
<a class="repo-link btn btn-inverse btn-small " rel="prev" href="../release-notes/">
|
||||
<i class="icon-arrow-left icon-white"></i> Previous
|
||||
</a>
|
||||
<a id="search_modal_show" class="repo-link btn btn-inverse btn-small" href="#mkdocs_search_modal" data-toggle="modal" data-target="#mkdocs_search_modal"><i class="icon-search icon-white"></i> Search</a>
|
||||
<a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</a>
|
||||
<a class="brand" href="https://www.django-rest-framework.org/">Django REST framework</a>
|
||||
<div class="nav-collapse collapse">
|
||||
|
||||
<!-- Main navigation -->
|
||||
<ul class="nav navbar-nav">
|
||||
|
||||
<li >
|
||||
<a href="../..">Home</a>
|
||||
</li>
|
||||
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Tutorial <b class="caret"></b></a>
|
||||
<ul class="dropdown-menu">
|
||||
|
||||
<li >
|
||||
<a href="../../tutorial/quickstart/">Quickstart</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../tutorial/1-serialization/">1 - Serialization</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../tutorial/2-requests-and-responses/">2 - Requests and responses</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../tutorial/3-class-based-views/">3 - Class based views</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../tutorial/4-authentication-and-permissions/">4 - Authentication and permissions</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../tutorial/5-relationships-and-hyperlinked-apis/">5 - Relationships and hyperlinked APIs</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../tutorial/6-viewsets-and-routers/">6 - Viewsets and routers</a>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">API Guide <b class="caret"></b></a>
|
||||
<ul class="dropdown-menu">
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/requests/">Requests</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/responses/">Responses</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/views/">Views</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/generic-views/">Generic views</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/viewsets/">Viewsets</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/routers/">Routers</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/parsers/">Parsers</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/renderers/">Renderers</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/serializers/">Serializers</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/fields/">Serializer fields</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/relations/">Serializer relations</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/validators/">Validators</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/authentication/">Authentication</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/permissions/">Permissions</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/caching/">Caching</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/throttling/">Throttling</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/filtering/">Filtering</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/pagination/">Pagination</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/versioning/">Versioning</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/content-negotiation/">Content negotiation</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/metadata/">Metadata</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/schemas/">Schemas</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/format-suffixes/">Format suffixes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/reverse/">Returning URLs</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/exceptions/">Exceptions</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/status-codes/">Status codes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/testing/">Testing</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../api-guide/settings/">Settings</a>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Topics <b class="caret"></b></a>
|
||||
<ul class="dropdown-menu">
|
||||
|
||||
<li >
|
||||
<a href="../../topics/documenting-your-api/">Documenting your API</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../topics/api-clients/">API Clients</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../topics/internationalization/">Internationalization</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../topics/ajax-csrf-cors/">AJAX, CSRF & CORS</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../topics/html-and-forms/">HTML & Forms</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../topics/browser-enhancements/">Browser Enhancements</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../topics/browsable-api/">The Browsable API</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../topics/rest-hypermedia-hateoas/">REST, Hypermedia & HATEOAS</a>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
<li class="dropdown active">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Community <b class="caret"></b></a>
|
||||
<ul class="dropdown-menu">
|
||||
|
||||
<li >
|
||||
<a href="../tutorials-and-resources/">Tutorials and Resources</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../third-party-packages/">Third Party Packages</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../contributing/">Contributing to REST framework</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../project-management/">Project management</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li class="active" >
|
||||
<a href="./">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.12-announcement/">3.12 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.11-announcement/">3.11 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.10-announcement/">3.10 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.9-announcement/">3.9 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.8-announcement/">3.8 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.7-announcement/">3.7 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.6-announcement/">3.6 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.5-announcement/">3.5 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.4-announcement/">3.4 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.3-announcement/">3.3 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.2-announcement/">3.2 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.1-announcement/">3.1 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.0-announcement/">3.0 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../kickstarter-announcement/">Kickstarter Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../mozilla-grant/">Mozilla Grant</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../funding/">Funding</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../jobs/">Jobs</a>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</li>
|
||||
|
||||
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
<!--/.nav-collapse -->
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="body-content">
|
||||
<div class="container-fluid">
|
||||
<!-- Search Modal -->
|
||||
<div id="mkdocs_search_modal" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h3 id="myModalLabel">Documentation search</h3>
|
||||
</div>
|
||||
|
||||
<div class="modal-body">
|
||||
<form role="form" autocomplete="off">
|
||||
<div class="form-group">
|
||||
<input type="text" name="q" class="form-control" placeholder="Search..." id="mkdocs-search-query">
|
||||
</div>
|
||||
</form>
|
||||
<div id="mkdocs-search-results"></div>
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<button class="btn" data-dismiss="modal" aria-hidden="true">Close</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row-fluid">
|
||||
<div class="span3">
|
||||
<div id="table-of-contents">
|
||||
<ul class="nav nav-list side-nav well sidebar-nav-fixed">
|
||||
|
||||
|
||||
|
||||
<li class="main">
|
||||
<a href="#django-rest-framework-314">Django REST framework 3.14</a>
|
||||
</li>
|
||||
|
||||
|
||||
<li>
|
||||
<a href="#django-41-support">Django 4.1 support</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#raise_exceptions-argument-for-is_valid-is-now-keyword-only">raise_exceptions argument for is_valid is now keyword-only.</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#manyrelatedfield-supports-returning-the-default-when-the-source-attribute-doesnt-exist">ManyRelatedField supports returning the default when the source attribute doesn't exist.</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#make-open-api-get_reference-public">Make Open API get_reference public.</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#change-semantic-of-or-of-two-permission-classes">Change semantic of OR of two permission classes.</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#minor-fixes-and-improvements">Minor fixes and improvements</a>
|
||||
</li>
|
||||
|
||||
|
||||
|
||||
<div class="promo">
|
||||
<hr/>
|
||||
<div id="sidebarInclude">
|
||||
</div>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="main-content" class="span9">
|
||||
|
||||
|
||||
|
||||
<style>
|
||||
.promo li a {
|
||||
float: left;
|
||||
width: 130px;
|
||||
height: 20px;
|
||||
text-align: center;
|
||||
margin: 10px 30px;
|
||||
padding: 150px 0 0 0;
|
||||
background-position: 0 50%;
|
||||
background-size: 130px auto;
|
||||
background-repeat: no-repeat;
|
||||
font-size: 120%;
|
||||
color: black;
|
||||
}
|
||||
.promo li {
|
||||
list-style: none;
|
||||
}
|
||||
</style>
|
||||
|
||||
<h1 id="django-rest-framework-314"><a class="toclink" href="#django-rest-framework-314">Django REST framework 3.14</a></h1>
|
||||
<h2 id="django-41-support"><a class="toclink" href="#django-41-support">Django 4.1 support</a></h2>
|
||||
<p>The latest release now fully supports Django 4.1, and drops support for Django 2.2.</p>
|
||||
<p>Our requirements are now:</p>
|
||||
<ul>
|
||||
<li>Python 3.6+</li>
|
||||
<li>Django 4.1, 4.0, 3.2, 3.1, 3.0</li>
|
||||
</ul>
|
||||
<h2 id="raise_exceptions-argument-for-is_valid-is-now-keyword-only"><a class="toclink" href="#raise_exceptions-argument-for-is_valid-is-now-keyword-only"><code>raise_exceptions</code> argument for <code>is_valid</code> is now keyword-only.</a></h2>
|
||||
<p>Calling <code>serializer_instance.is_valid(True)</code> is no longer acceptable syntax.
|
||||
If you'd like to use the <code>raise_exceptions</code> argument, you must use it as a
|
||||
keyword argument.</p>
|
||||
<p>See Pull Request <a href="https://github.com/encode/django-rest-framework/pull/7952">#7952</a> for more details.</p>
|
||||
<h2 id="manyrelatedfield-supports-returning-the-default-when-the-source-attribute-doesnt-exist"><a class="toclink" href="#manyrelatedfield-supports-returning-the-default-when-the-source-attribute-doesnt-exist"><code>ManyRelatedField</code> supports returning the default when the source attribute doesn't exist.</a></h2>
|
||||
<p>Previously, if you used a serializer field with <code>many=True</code> with a dot notated source field
|
||||
that didn't exist, it would raise an <code>AttributeError</code>. Now it will return the default or be
|
||||
skipped depending on the other arguments.</p>
|
||||
<p>See Pull Request <a href="https://github.com/encode/django-rest-framework/pull/7574">#7574</a> for more details.</p>
|
||||
<h2 id="make-open-api-get_reference-public"><a class="toclink" href="#make-open-api-get_reference-public">Make Open API <code>get_reference</code> public.</a></h2>
|
||||
<p>Returns a reference to the serializer component. This may be useful if you override <code>get_schema()</code>.</p>
|
||||
<h2 id="change-semantic-of-or-of-two-permission-classes"><a class="toclink" href="#change-semantic-of-or-of-two-permission-classes">Change semantic of OR of two permission classes.</a></h2>
|
||||
<p>When OR-ing two permissions, the request has to pass either class's <code>has_permission() and has_object_permission()</code>.</p>
|
||||
<p>Previously, both class's <code>has_permission()</code> was ignored when OR-ing two permissions together.</p>
|
||||
<p>See Pull Request <a href="https://github.com/encode/django-rest-framework/pull/7522">#7522</a> for more details.</p>
|
||||
<h2 id="minor-fixes-and-improvements"><a class="toclink" href="#minor-fixes-and-improvements">Minor fixes and improvements</a></h2>
|
||||
<p>There are a number of minor fixes and improvements in this release. See the <a href="../release-notes/">release notes</a> page for a complete listing.</p>
|
||||
|
||||
|
||||
</div> <!--/span-->
|
||||
</div> <!--/row-->
|
||||
</div> <!--/.fluid-container-->
|
||||
</div> <!--/.body content-->
|
||||
<div id="push"></div>
|
||||
</div> <!--/.wrapper -->
|
||||
|
||||
<footer class="span12">
|
||||
<p>Documentation built with <a href="http://www.mkdocs.org/">MkDocs</a>.
|
||||
</p>
|
||||
</footer>
|
||||
|
||||
<!-- Le javascript
|
||||
================================================== -->
|
||||
<!-- Placed at the end of the document so the pages load faster -->
|
||||
<script async src="https://fund.django-rest-framework.org/sidebar_include.js"></script>
|
||||
<script src="../../js/jquery-1.8.1-min.js"></script>
|
||||
<script src="../../js/prettify-1.0.js"></script>
|
||||
<script src="../../js/bootstrap-2.1.1-min.js"></script>
|
||||
<script src="../../js/theme.js"></script>
|
||||
|
||||
<script>var base_url = '../..';</script>
|
||||
|
||||
<script src="../../search/main.js" defer></script>
|
||||
|
||||
|
||||
<script>
|
||||
var shiftWindow = function() {
|
||||
scrollBy(0, -50)
|
||||
};
|
||||
|
||||
if (location.hash) shiftWindow();
|
||||
window.addEventListener("hashchange", shiftWindow);
|
||||
|
||||
$('.dropdown-menu').on('click touchstart', function(event) {
|
||||
event.stopPropagation();
|
||||
});
|
||||
|
||||
// Dynamically force sidenav/dropdown to no higher than browser window
|
||||
$('.side-nav, .dropdown-menu').css('max-height', window.innerHeight - 130);
|
||||
|
||||
$(function() {
|
||||
$(window).resize(function() {
|
||||
$('.side-nav, .dropdown-menu').css('max-height', window.innerHeight - 130);
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -593,7 +597,7 @@ form.signup {
|
|||
<h2 id="what-future-funding-will-enable"><a class="toclink" href="#what-future-funding-will-enable">What future funding will enable</a></h2>
|
||||
<ul>
|
||||
<li>Realtime API support, using WebSockets. This will consist of documentation and support for using REST framework together with Django Channels, plus integrating WebSocket support into the client libraries.</li>
|
||||
<li>Better authentication defaults, possibly bringing JWT & CORs support into the core package.</li>
|
||||
<li>Better authentication defaults, possibly bringing JWT & CORS support into the core package.</li>
|
||||
<li>Securing the community & operations manager position long-term.</li>
|
||||
<li>Opening up and securing a part-time position to focus on ticket triage and resolution.</li>
|
||||
<li>Paying for development time on building API client libraries in a range of programming languages. These would be integrated directly into the upcoming API documentation.</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -442,7 +446,7 @@
|
|||
<li><a href="https://djangojobs.net/jobs/">https://djangojobs.net/jobs/</a></li>
|
||||
<li><a href="https://findwork.dev/django-rest-framework-jobs">https://findwork.dev/django-rest-framework-jobs</a></li>
|
||||
<li><a href="https://www.indeed.com/q-Django-jobs.html">https://www.indeed.com/q-Django-jobs.html</a></li>
|
||||
<li><a href="https://stackoverflow.com/jobs/developer-jobs-using-django">https://stackoverflow.com/jobs/developer-jobs-using-django</a></li>
|
||||
<li><a href="https://stackoverflow.com/jobs/companies?tl=django">https://stackoverflow.com/jobs/companies?tl=django</a></li>
|
||||
<li><a href="https://www.upwork.com/o/jobs/browse/skill/django-framework/">https://www.upwork.com/o/jobs/browse/skill/django-framework/</a></li>
|
||||
<li><a href="https://www.technojobs.co.uk/django-jobs">https://www.technojobs.co.uk/django-jobs</a></li>
|
||||
<li><a href="https://remoteok.io/remote-django-jobs">https://remoteok.io/remote-django-jobs</a></li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -54,7 +54,7 @@
|
|||
<div class="navbar-inner">
|
||||
<div class="container-fluid">
|
||||
<a class="repo-link btn btn-primary btn-small" href="https://github.com/encode/django-rest-framework/tree/master">GitHub</a>
|
||||
<a class="repo-link btn btn-inverse btn-small " rel="next" href="../3.13-announcement/">
|
||||
<a class="repo-link btn btn-inverse btn-small " rel="next" href="../3.14-announcement/">
|
||||
Next <i class="icon-arrow-right icon-white"></i>
|
||||
</a>
|
||||
<a class="repo-link btn btn-inverse btn-small " rel="prev" href="../project-management/">
|
||||
|
@ -293,6 +293,10 @@
|
|||
<a href="./">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -425,6 +429,10 @@
|
|||
<a href="#upgrading">Upgrading</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#314x-series">3.14.x series</a>
|
||||
</li>
|
||||
|
||||
<li>
|
||||
<a href="#313x-series">3.13.x series</a>
|
||||
</li>
|
||||
|
@ -524,6 +532,23 @@
|
|||
<pre><code>pip show djangorestframework
|
||||
</code></pre>
|
||||
<hr />
|
||||
<h2 id="314x-series"><a class="toclink" href="#314x-series">3.14.x series</a></h2>
|
||||
<h3 id="3140"><a class="toclink" href="#3140">3.14.0</a></h3>
|
||||
<p>Date: 22nd September 2022</p>
|
||||
<ul>
|
||||
<li>Django 2.2 is no longer supported. [<a href="https://github.com/encode/django-rest-framework/pull/8662">#8662</a>]</li>
|
||||
<li>Django 4.1 compatibility. [<a href="https://github.com/encode/django-rest-framework/pull/8591">#8591</a>]</li>
|
||||
<li>Add <code>--api-version</code> CLI option to <code>generateschema</code> management command. [<a href="https://github.com/encode/django-rest-framework/pull/8663">#8663</a>]</li>
|
||||
<li>Enforce <code>is_valid(raise_exception=False)</code> as a keyword-only argument. [<a href="https://github.com/encode/django-rest-framework/pull/7952">#7952</a>]</li>
|
||||
<li>Stop calling <code>set_context</code> on Validators. [<a href="https://github.com/encode/django-rest-framework/pull/8589">#8589</a>]</li>
|
||||
<li>Return <code>NotImplemented</code> from <code>ErrorDetails.__ne__</code>. [<a href="https://github.com/encode/django-rest-framework/pull/8538">#8538</a>]</li>
|
||||
<li>Don't evaluate <code>DateTimeField.default_timezone</code> when a custom timezone is set. [<a href="https://github.com/encode/django-rest-framework/pull/8531">#8531</a>]</li>
|
||||
<li>Make relative URLs clickable in Browseable API. [<a href="https://github.com/encode/django-rest-framework/pull/8464">#8464</a>]</li>
|
||||
<li>Support <code>ManyRelatedField</code> falling back to the default value when the attribute specified by dot notation doesn't exist. Matches <code>ManyRelatedField.get_attribute</code> to <code>Field.get_attribute</code>. [<a href="https://github.com/encode/django-rest-framework/pull/7574">#7574</a>]</li>
|
||||
<li>Make <code>schemas.openapi.get_reference</code> public. [<a href="https://github.com/encode/django-rest-framework/pull/7515">#7515</a>]</li>
|
||||
<li>Make <code>ReturnDict</code> support <code>dict</code> union operators on Python 3.9 and later. [<a href="https://github.com/encode/django-rest-framework/pull/8302">#8302</a>]</li>
|
||||
<li>Update throttling to check if <code>request.user</code> is set before checking if the user is authenticated. [<a href="https://github.com/encode/django-rest-framework/pull/8370">#8370</a>]</li>
|
||||
</ul>
|
||||
<h2 id="313x-series"><a class="toclink" href="#313x-series">3.13.x series</a></h2>
|
||||
<h3 id="3131"><a class="toclink" href="#3131">3.13.1</a></h3>
|
||||
<p>Date: 15th December 2021</p>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -568,6 +572,8 @@
|
|||
<li><a href="https://github.com/barseghyanartur/django-elasticsearch-dsl-drf">django-elasticsearch-dsl-drf</a> - Integrate Elasticsearch DSL with Django REST framework. Package provides views, serializers, filter backends, pagination and other handy add-ons.</li>
|
||||
<li><a href="https://github.com/rhenter/django-api-client">django-api-client</a> - DRF client that groups the Endpoint response, for use in CBVs and FBV as if you were working with Django's Native Models..</li>
|
||||
<li><a href="https://github.com/iashraful/fast-drf">fast-drf</a> - A model based library for making API development faster and easier.</li>
|
||||
<li><a href="https://github.com/Raekkeri/django-requestlogs">django-requestlogs</a> - Providing middleware and other helpers for audit logging for REST framework.</li>
|
||||
<li><a href="https://github.com/ghazi-git/drf-standardized-errors">drf-standardized-errors</a> - DRF exception handler to standardize error responses for all API endpoints.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
BIN
img/premium/spacinov-readme.png
Normal file
BIN
img/premium/spacinov-readme.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 56 KiB |
|
@ -293,6 +293,10 @@
|
|||
<a href="community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -559,7 +563,7 @@ continued development by <strong><a href="community/funding/">signing up for a p
|
|||
<p>REST framework requires the following:</p>
|
||||
<ul>
|
||||
<li>Python (3.6, 3.7, 3.8, 3.9, 3.10)</li>
|
||||
<li>Django (2.2, 3.0, 3.1, 3.2, 4.0)</li>
|
||||
<li>Django (2.2, 3.0, 3.1, 3.2, 4.0, 4.1)</li>
|
||||
</ul>
|
||||
<p>We <strong>highly recommend</strong> and only officially support the latest patch release of
|
||||
each Python and Django series.</p>
|
||||
|
|
File diff suppressed because one or more lines are too long
138
sitemap.xml
138
sitemap.xml
|
@ -1,271 +1,275 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"><url>
|
||||
<loc>https://www.django-rest-framework.org/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/tutorial/quickstart/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/tutorial/1-serialization/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/tutorial/2-requests-and-responses/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/tutorial/3-class-based-views/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/tutorial/4-authentication-and-permissions/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/tutorial/5-relationships-and-hyperlinked-apis/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/tutorial/6-viewsets-and-routers/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/requests/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/responses/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/views/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/generic-views/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/viewsets/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/routers/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/parsers/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/renderers/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/serializers/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/fields/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/relations/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/validators/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/authentication/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/permissions/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/caching/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/throttling/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/filtering/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/pagination/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/versioning/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/content-negotiation/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/metadata/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/schemas/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/format-suffixes/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/reverse/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/exceptions/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/status-codes/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/testing/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/api-guide/settings/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/documenting-your-api/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/api-clients/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/internationalization/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/ajax-csrf-cors/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/html-and-forms/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/browser-enhancements/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/browsable-api/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/topics/rest-hypermedia-hateoas/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/tutorials-and-resources/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/third-party-packages/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/contributing/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/project-management/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/release-notes/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.14-announcement/</loc>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.13-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.12-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.11-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.10-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.9-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.8-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.7-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.6-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.5-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.4-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.3-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.2-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.1-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/3.0-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/kickstarter-announcement/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/mozilla-grant/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/funding/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url><url>
|
||||
<loc>https://www.django-rest-framework.org/community/jobs/</loc>
|
||||
<lastmod>2022-06-06</lastmod>
|
||||
<lastmod>2022-09-22</lastmod>
|
||||
<changefreq>daily</changefreq>
|
||||
</url>
|
||||
</urlset>
|
BIN
sitemap.xml.gz
BIN
sitemap.xml.gz
Binary file not shown.
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -552,7 +556,7 @@ from snippets import views
|
|||
|
||||
urlpatterns = [
|
||||
path('snippets/', views.snippet_list),
|
||||
path('snippets/<int:pk>', views.snippet_detail),
|
||||
path('snippets/<int:pk>/', views.snippet_detail),
|
||||
]
|
||||
|
||||
urlpatterns = format_suffix_patterns(urlpatterns)
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
@ -537,8 +541,8 @@ from snippets import views
|
|||
|
||||
# Create a router and register our viewsets with it.
|
||||
router = DefaultRouter()
|
||||
router.register(r'snippets', views.SnippetViewSet,basename="snippets")
|
||||
router.register(r'users', views.UserViewSet,basename="users")
|
||||
router.register(r'snippets', views.SnippetViewSet,basename="snippet")
|
||||
router.register(r'users', views.UserViewSet,basename="user")
|
||||
|
||||
# The API URLs are now determined automatically by the router.
|
||||
urlpatterns = [
|
||||
|
|
|
@ -293,6 +293,10 @@
|
|||
<a href="../../community/release-notes/">Release Notes</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.14-announcement/">3.14 Announcement</a>
|
||||
</li>
|
||||
|
||||
<li >
|
||||
<a href="../../community/3.13-announcement/">3.13 Announcement</a>
|
||||
</li>
|
||||
|
|
Loading…
Reference in New Issue
Block a user