fixed bug with swapping book in series when we dont have details on book to swap with, also really disabled up/down buttons, rather than just made them look disabled
This commit is contained in:
@@ -45,18 +45,18 @@
|
||||
{% if SeriesBookNum( series.id, book.id ) == 1 %}
|
||||
<script>
|
||||
{% if book.parent_ref|length %}
|
||||
$('#up-{{book.parent_ref[0].book_id}}').addClass("disabled")
|
||||
$('#up-{{book.parent_ref[0].book_id}}').prop("disabled", true)
|
||||
{% else %}
|
||||
$('#up-{{book.id}}').addClass("disabled")
|
||||
$('#up-{{book.id}}').prop("disabled", true)
|
||||
{% endif %}
|
||||
</script>
|
||||
{% endif %}
|
||||
{% if SeriesBookNum( series.id, book.id ) == series.num_books %}
|
||||
<script>
|
||||
{% if book.parent_ref|length %}
|
||||
$('#down-{{book.parent_ref[0].book_id}}').addClass("disabled")
|
||||
$('#down-{{book.parent_ref[0].book_id}}').prop("disabled", true)
|
||||
{% else %}
|
||||
$('#down-{{book.id}}').addClass("disabled")
|
||||
$('#down-{{book.id}}').prop("disabled", true)
|
||||
{% endif %}
|
||||
</script>
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user