Commit 0f006d32 authored by Mario Chirinos Colunga's avatar Mario Chirinos Colunga 💬

update

parent 280acb2c
from django.shortcuts import render from django.shortcuts import render
from django.views import generic
# Create your views here. # Create your views here.
from .models import Book, Author, BookInstance, Genre from .models import Book, Author, BookInstance, Genre
...@@ -21,3 +21,8 @@ def index(request): ...@@ -21,3 +21,8 @@ def index(request):
'index.html', 'index.html',
context={'num_books':num_books,'num_instances':num_instances,'num_instances_available':num_instances_available,'num_authors':num_authors}, context={'num_books':num_books,'num_instances':num_instances,'num_instances_available':num_instances_available,'num_authors':num_authors},
) )
class BookListView(generic.ListView):
model = Book
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