Skip to content
Snippets Groups Projects
Select Git revision
  • 0d9788a158b2fb1f7cbfa8f30f460e91c26c3599
  • master default protected
2 results

home.html

Blame
  • home.html 540 B
    {% extends "base.html" %}
    
    {% block content %}
      <h1>Book List</h1>
      {% if books %}
      <ul>
        {% for book in books %}
          <li>{{book.book_title}}</li>
          <li>{{book.author_fk.author_name}}</li>
          <li>
            {% for genre in book.genres.all %}
              {{genre}},
              {% endfor %}  
          </li>
           {% if book.description %}
                <li>{{book.description}}</li>
            {% endif %}
          <li>{{book.price}}</li>
          <hr>
        {% endfor %}
      </ul>
      {% else %}
        <p>No book info</p>
      {% endif %} 
    {% endblock %}