mirror of
https://github.com/encode/django-rest-framework.git
synced 2025-06-16 11:33:19 +03:00
Fix up the example
This commit is contained in:
parent
dac7eb0916
commit
0da291fad3
|
@ -83,8 +83,8 @@ Using Django REST framework can be as simple as adding a few lines to your urlco
|
||||||
model = MyModel
|
model = MyModel
|
||||||
|
|
||||||
urlpatterns = patterns('',
|
urlpatterns = patterns('',
|
||||||
url(r'^$', RootModelResource.as_view(resource=MyResource)),
|
url(r'^$', ListOrCreateModelView.as_view(resource=MyResource)),
|
||||||
url(r'^(?P<pk>[^/]+)/$', ModelResource.as_view(resource=MyResource)),
|
url(r'^(?P<pk>[^/]+)/$', InstanceModelView.as_view(resource=MyResource)),
|
||||||
)
|
)
|
||||||
|
|
||||||
Django REST framework comes with two "getting started" examples.
|
Django REST framework comes with two "getting started" examples.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user