aboutsummaryrefslogtreecommitdiffstats
path: root/tutorial/5-relationships-and-hyperlinked-apis
diff options
context:
space:
mode:
authorTom Christie2015-03-23 11:34:01 +0000
committerTom Christie2015-03-23 11:34:01 +0000
commit5e96a1ddf17946595a22083b035f99418dd2cbd7 (patch)
tree6f77e244f775547635492bc9e6a2e019a54b2c2b /tutorial/5-relationships-and-hyperlinked-apis
parent09d51ea4e256ed99421dc52cd6b4626e7172b667 (diff)
downloaddjango-rest-framework-5e96a1ddf17946595a22083b035f99418dd2cbd7.tar.bz2
Update documentation
Diffstat (limited to 'tutorial/5-relationships-and-hyperlinked-apis')
-rw-r--r--tutorial/5-relationships-and-hyperlinked-apis/index.html4
1 files changed, 3 insertions, 1 deletions
diff --git a/tutorial/5-relationships-and-hyperlinked-apis/index.html b/tutorial/5-relationships-and-hyperlinked-apis/index.html
index 418c7851..6ac9f9c0 100644
--- a/tutorial/5-relationships-and-hyperlinked-apis/index.html
+++ b/tutorial/5-relationships-and-hyperlinked-apis/index.html
@@ -473,8 +473,10 @@ class UserSerializer(serializers.HyperlinkedModelSerializer):
<li>Our user serializer includes a field that refers to <code>'snippet-detail'</code>.</li>
<li>Our snippet and user serializers include <code>'url'</code> fields that by default will refer to <code>'{model_name}-detail'</code>, which in this case will be <code>'snippet-detail'</code> and <code>'user-detail'</code>.</li>
</ul>
-<p>After adding all those names into our URLconf, our final <code>snippets/urls.py</code> file should look something like this:</p>
+<p>After adding all those names into our URLconf, our final <code>snippets/urls.py</code> file should look like this:</p>
<pre><code>from django.conf.urls import url, include
+from rest_framework.urlpatterns import format_suffix_patterns
+from snippets import views
# API endpoints
urlpatterns = format_suffix_patterns([