Commit f126a7fd authored by John Riz Daniel Ramos's avatar John Riz Daniel Ramos

Code Clean Up

- comments in view.py
parent 7c33a677
...@@ -78,14 +78,3 @@ class AuthorsUpdateView(UpdateView): ...@@ -78,14 +78,3 @@ class AuthorsUpdateView(UpdateView):
template_name = "bookshelf/edit-author.html" template_name = "bookshelf/edit-author.html"
success_url = "../details/" success_url = "../details/"
# def books_view(request):
# if request.method == 'POST':
# form = BooksForm(request.POST)
# if form.is_valid():
# new_subject = form.save()
# return redirect('book_details', pk=new_subject.pk)
# else:
# form = BooksForm()
# return render(request, 'book_details', {'form': form})
\ No newline at end of file
{% extends 'base.html' %} {% extends 'base.html' %}
{% load static %} {% load static %}
{% block title %}Edit{% endblock %} {% block title %}Edit Author{% endblock %}
{% block content %} {% block content %}
{{ form.non_field_errors }} {{ form.non_field_errors }}
{% for field in form %} {% for field in form %}
......
{% extends 'base.html' %} {% extends 'base.html' %}
{% load static %} {% load static %}
{% block title %}Edit{% endblock %} {% block title %}Edit Book{% endblock %}
{% block content %} {% block content %}
{{ form.non_field_errors }} {{ form.non_field_errors }}
{% for field in form %} {% for field in form %}
......
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