{% extends "base.html" %} {% load staticfiles %} {% block content %} {% if messages %} {% for message in messages %}

{{ message }}

{% endfor %} {% endif %}
{% csrf_token %}
{% if context %} {% if user.is_authenticated %} {% endif %} {% for book in context %} {% if user.is_authenticated %} {% endif %} {% if user.is_authenticated %} {% if user.groups.all.0.name == 'Readers' %} {% else %} {% endif %} {% endif %} {% endfor %}
# Book Title Author(s) Total BooksAvailable Books Action
{{ forloop.counter0|add:context.start_index }} {{ book.title }} {% for author in book.author.all %} {{ author }}{% if not forloop.last %}, {% endif %}{% endfor %} {{ book.total_quantity }}{{ book.quantity }} {% if book.status == 'l' %} {% elif book.id in book_ids %} {% else %} {% endif %} {% if book.quantity > 0 %} Lend Book {% endif %} Add Copy
{% else %}

No such record found!

{% endif %}
{% if context.has_other_pages %} {% endif %} {% endblock %}