Commit e2b6bb71 authored by Jan Enzo Salvador's avatar Jan Enzo Salvador

Added BookForm class and AuthorForm class

parent 9567abf2
from django import forms
from .models import Author, Books
class BookForm(forms.ModelForm):
class Meta:
model = Books
fields = '__all__'
# template to be used by default is called Books_form.html
class AuthorForm(forms.ModelForm):
class Meta:
model = Author
fields = '__all__'
# template to be used by default is called Author_form.html
\ 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