Commit 07421ea1 authored by RJC's avatar RJC

added url endpoint for authorcreate view in urls.py in bookshelf module

parent b7036c00
from django.urls import path
from django.urls import path, re_path
from .views import HomePageView, BookListView, BookDetailView, BookCreateView,\
AuthorListView, AuthorDetailView
AuthorListView, AuthorCreateView, AuthorDetailView
urlpatterns = [
path('homepage/', HomePageView.as_view()),
path('books/', BookListView.as_view()),
path('books/add/', BookCreateView.as_view()),
path('books/<int:pk>/details/', BookDetailView.as_view()),
path('books/<int:pk>/details/', BookDetailView.as_view(), name='bookdetailview'),
path('authors/', AuthorListView.as_view()),
path('authors/<int:pk>/details/', AuthorDetailView.as_view()),
path('authors/add/', AuthorCreateView.as_view()),
path('authors/<int:pk>/details/', AuthorDetailView.as_view(), name='authordetailview'),
]
app_name = 'bookshelf'
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment