Hide read button if no epub
parent
03a9a30a0b
commit
0efba31c86
|
@ -179,11 +179,13 @@
|
|||
</div>
|
||||
</div>
|
||||
<div class="bookSidebar">
|
||||
{% if has_online_book %}
|
||||
<div class="bookRead">
|
||||
<a href="{% url 'read' work_id %}">
|
||||
<button class="button expanded success">Read</button>
|
||||
</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
<div class="bookDownload">
|
||||
<a href="{% url 'download' work_id %}">
|
||||
<button class="button expanded success">Download</button>
|
||||
|
|
|
@ -422,7 +422,8 @@ def work(request, work_id, action='display'):
|
|||
'cover_width': cover_width_number,
|
||||
'action': action,
|
||||
'formset': formset,
|
||||
'kwform': SubjectSelectForm()
|
||||
'kwform': SubjectSelectForm(),
|
||||
'has_online_book': work.first_epub() != None,
|
||||
})
|
||||
|
||||
def edition_uploads(request, edition_id):
|
||||
|
|
Loading…
Reference in New Issue