X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/357027375ff8867f42ca34bcbfb5a78b5b185fc3..0d2ad838d03a600b034f6355a1d43f74debd62eb:/src/api/urls.py diff --git a/src/api/urls.py b/src/api/urls.py index 1c2e656d1..910d362f5 100644 --- a/src/api/urls.py +++ b/src/api/urls.py @@ -15,7 +15,7 @@ auth = OAuthAuthentication(realm="Wolne Lektury") book_list_resource = CsrfExemptResource(handler=handlers.BooksHandler, authentication=auth) ebook_list_resource = Resource(handler=handlers.EBooksHandler) -#book_list_resource = Resource(handler=handlers.BooksHandler) +# book_list_resource = Resource(handler=handlers.BooksHandler) book_resource = Resource(handler=handlers.BookDetailHandler) collection_resource = Resource(handler=handlers.CollectionDetailHandler) @@ -51,7 +51,8 @@ urlpatterns = patterns( url(r'^oauth/authorize/$', 'oauth_user_auth'), url(r'^oauth/access_token/$', csrf_exempt(oauth_access_token)), -) + patterns('', +) + patterns( + '', url(r'^$', TemplateView.as_view(template_name='api/main.html'), name='api'), url(r'^include/(?Pbook|fragment|tag)/(?P\d+)\.(?P.+)\.(?Pxml|json)$', incl, name='api_include'),