Created
November 17, 2015 05:44
-
-
Save wbaek/afecf829db72074215c0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django.conf.urls import url | |
from api import views | |
urlpatterns = [ | |
url(r'images/$', views.ImageList.as_view()), | |
url(r'images/(?P<pk>[0-9a-zA-Z-]*)$', views.ImageDetail.as_view(), name='image-detail'), | |
url(r'tags/$', views.TagList.as_view()), | |
url(r'tags/(?P<pk>[0-9a-zA-Z-]*)$', views.TagDetail.as_view(), name='tag-detail'), | |
] | |
from rest_framework.urlpatterns import format_suffix_patterns | |
urlpatterns = format_suffix_patterns(urlpatterns) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment