Skip to content

Commit

Permalink
Merge pull request #72 from boris/fixes-0.6.6
Browse files Browse the repository at this point in the history
Use proper object names instead of ids
  • Loading branch information
boris authored May 22, 2024
2 parents 1d2d055 + d38406e commit edb96f4
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions app/templates/show_book.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,22 @@
{% with rating = item[6] %}

<div class="container has-text-justified">
<h1 class="title">{{ item[1] }}</h1>
<h2 class="text-muted">{{ item[9] }} ({{ item[10] }})</h2>
<h1 class="title">{{ item.title }}</h1>
<h2 class="text-muted">{{ item.author_name }} ({{ item.author_country }})</h2>

<div class="container">
<div class="row no-gutters">
<div class="col-sm-5">
<p><b>Género: </b>{{ item[13] }}</p>
<p><b>Editorial: </b>{{ item[12] }}</p>
<p><b>Año: </b>{{ item[2] }}</p>
<p><b>¿Leído?: </b>{% if item[4] %}✔️{%else%}✖️{%endif%}</p>
<p><b>¿Prestado?: </b>{% if item[5] %}✔️{%else%}✖️{%endif%}</p>
<p><b>Número de páginas: </b>{{ item[3] }}</p>
<p><b>Género: </b>{{ item.genre_name }}</p>
<p><b>Editorial: </b>{{ item.editorial_name }}</p>
<p><b>Año: </b>{{ item.year }}</p>
<p><b>¿Leído?: </b>{% if item.read %}✔️{%else%}✖️{%endif%}</p>
<p><b>¿Prestado?: </b>{% if item.shared %}✔️{%else%}✖️{%endif%}</p>
<p><b>Número de páginas: </b>{{ item.pages }}</p>
<p><b>Puntuación: </b>{{ rating * '⭐' |safe}}{{ (5 - rating) * '⚝' |safe }}</p>
<p><b>ISBN: </b>{{ item[9] }}</p>
<p><b>ISBN: </b>{{ item.isbn }}</p>
<p><b>Tags: </b>
{% set tag_list = item[8].split(', ')%}
{% set tag_list = item.tags.split(', ')%}
<ul>
{% for tag in tag_list %}
<li><a href="{{ url_for('main.show_tag', tag = tag)}}">{{tag}}</a></li>
Expand Down

0 comments on commit edb96f4

Please sign in to comment.