| 1 |
|
| 2 |
{% extends "base.html" %} |
| 3 |
|
| 4 |
{% block style %} |
| 5 |
table { |
| 6 |
color: #151B54; |
| 7 |
} |
| 8 |
|
| 9 |
table tr th { |
| 10 |
color: white; |
| 11 |
background: #736F6E; |
| 12 |
} |
| 13 |
|
| 14 |
{% endblock %} |
| 15 |
|
| 16 |
{% block document_title %}{{ block.super }} - Coloured style{% endblock %} |
| 17 |
{% block page_title %}{{ block.super }} - Coloured style{% endblock %} |
| 18 |
|
| 19 |
{% block title_row %}<tr><th>Title</th><th>Genre</th><th>Rating</th></tr>{% endblock %} |
| 20 |
{% block book_rows %} |
| 21 |
{% for book in books %} |
| 22 |
{% ifchanged %}<tr><td colspan="3" align="center" style="background:yellow;" >{{ book.author }}</td>{% endifchanged %} |
| 23 |
<tr style="background-color:{% cycle "#E3E4FA" "#FCDFFF" "#E9CFEC" "#C8BBBE" %};" ><td>{{ book.title }}</td><td>{{ book.genre }}</td><td>{% range book.rating %}<img src="{% media_finder "star.png" %}" />{% endrange %}</td></tr> |
| 24 |
{% empty %} |
| 25 |
<tr><td><div>No Books here!</div></td></tr> |
| 26 |
{% endfor %} |
| 27 |
{% endblock %} |