{% extends "base_generic.html" %} {% block style %} .product-title, .product-description, .price, .vote, .sizes { margin-bottom: 15px; } {% endblock %} {% block content %}

Title: {{ book.title }}

Author:{{ book.author }}

Summary: {{ book.summary }}

ISBN: {{ book.isbn }}

Language: {{ book.language }}

Genre: {% for genre in book.genre.all %}{{ genre }}{% if not forloop.last %}, {% endif %}{% endfor %}

Copies

{% if user.is_superuser %} DELETE Update {% endif %} {% if book.available_copies %}
no of avialable copies={{ book.available_copies }}
Issue {% endif %}
{% if rr %} Give review about book {% endif %}
{% if reviews %} {% for r in reviews %} {% if r.review is not "none" %}

{{ r.student.name }}

{{ r.review }}

{% endif %} {% endfor %} {% else %} No reviews yet {% endif %}
{% endblock %} {% block javascript %} var i=0; var a; {% for r in reviews %} a=document.getElementById("{{ r.id }}"); i=0; if (parseFloat({{ r.rating }})>parseInt({{ r.rating }})) { a.innerHTML = a.innerHTML+ ""; } for (i = 0; i < parseInt({{ r.rating }}); i++) { a.innerHTML = a.innerHTML+""; } {% endfor %} {% endblock %}