Commit 3e36865a authored by Agu Syquia's avatar Agu Syquia

Updated the styling of multiple templates

Fixed spacing, and made code more readable
parent b2826720
......@@ -3,17 +3,16 @@
{% block title %}My Favorite Books{% endblock %}
{% block content %}
<h1>{{ object.author }}</h1>
{{ object.first_name }} {{ object.last_name }}<br>
{{ object.nationality }}<br>
{{ object.bio }}<br>
<br>
Books by {{ object.first_name }} {{ objects.last_name }} I love:
<br>
{# https://stackoverflow.com/questions/70442828/django-object-list-from-listview-with-two-models #}
{% for object in author.books_set.all %}
<a href="{{ object.get_absolute_url }}">{{ object }}<br></a>
{% endfor %}
<br>
<a href="/home">Home</a> <a href="/books">Books</a> <a href="/authors">Authors</a>
<h1>
{{ object.author }}
</h1>
{{ object.first_name }} {{ object.last_name }}<br>
{{ object.nationality }}<br>
{{ object.bio }}<br><br>
Books by {{ object.first_name }} {{ objects.last_name }} I love:<br>
{# https://stackoverflow.com/questions/70442828/django-object-list-from-listview-with-two-models #}
{% for object in author.books_set.all %}
<a href="{{ object.get_absolute_url }}">{{ object }}<br></a>
{% endfor %}<br><br>
<a href="/home">Home</a> <a href="/books">Books</a> <a href="/authors">Authors</a>
{% endblock %}
\ No newline at end of file
......@@ -3,10 +3,11 @@
{% block title %}My Favorite Authors{% endblock %}
{% block content %}
<h1>Agu's Favorite Authors:</h1>
{% for object in object_list %}
<a href="{{ object.get_absolute_url }}">{{ object.first_name }} {{ object.last_name}}<br></a>
{% endfor %}
<br>
<a href="/home">Home</a> <a href="/books">Books</a>
<h1>
Agu's Favorite Authors:
</h1>
{% for object in object_list %}
<a href="{{ object.get_absolute_url }}">{{ object.first_name }} {{ object.last_name}}<br></a>
{% endfor %}<br>
<a href="/home">Home</a> <a href="/books">Books</a>
{% endblock %}
\ No newline at end of file
......@@ -10,6 +10,6 @@
{{ object.publisher }}<br>
{{ object.year_published }}<br>
{{ object.ISBN }}<br>
{{ object.blurb }}<br>
{{ object.blurb }}<br><br>
<a href="/home">Home</a> <a href="/books">Books</a> <a href="/authors">Authors</a>
{% endblock %}
\ No newline at end of file
......@@ -3,10 +3,12 @@
{% block title %}My Favorite Books{% endblock %}
{% block content %}
<h1>Agu's Favorite Books:</h1>
{% for object in object_list %}
<a href="{{ object.get_absolute_url }}">{{ object.title }}<br></a>
{% endfor %}
<br>
<h1>
Agu's Favorite Books:
</h1>
{% for object in object_list %}
<a href="{{ object.get_absolute_url }}">
{{ object.title }}<br></a>
{% endfor %}<br>
<a href="/home">Home</a> <a href="/authors">Authors</a>
{% endblock %}
\ 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