Fix show cover

Update more debug output for kobo sync
This commit is contained in:
Ozzie Isaacs 2021-07-12 14:58:03 +02:00
parent e69b1adccd
commit 616cc2018a
3 changed files with 12 additions and 1 deletions

View File

@ -139,6 +139,7 @@ def convert_to_kobo_timestamp_string(timestamp):
def HandleSyncRequest():
sync_token = SyncToken.SyncToken.from_headers(request.headers)
log.info("Kobo library sync request received.")
log.debug("SyncToken: {}".format(sync_token))
if not current_app.wsgi_app.is_proxied:
log.debug('Kobo: Received unproxied request, changed request port to external server port')
@ -330,6 +331,7 @@ def generate_sync_response(sync_token, sync_results, set_cont=False):
extra_headers["x-kobo-sync"] = "continue"
sync_token.to_headers(extra_headers)
log.debug("Kobo Sync Content: {}".format(sync_results))
response = make_response(jsonify(sync_results), extra_headers)
return response

View File

@ -183,3 +183,12 @@ class SyncToken:
},
}
return b64encode_json(token)
def __str__(self):
return "{},{},{},{},{},{},{}".format(self.raw_kobo_store_token,
self.books_last_created,
self.books_last_modified,
self.archive_last_modified,
self.reading_state_last_modified,
self.tags_last_modified,
self.books_last_id)

View File

@ -3,7 +3,7 @@
{% if book %}
<div class="col-sm-3 col-lg-3 col-xs-12">
<div class="cover">
<img id="detailcover" title="{{entry.title}}" src="{{ url_for('web.get_cover', book_id=book.id, edit=1|uuidfilter) }}" alt="{{ book.title }}"/>
<img id="detailcover" title="{{book.title}}" src="{{ url_for('web.get_cover', book_id=book.id, edit=1|uuidfilter) }}" alt="{{ book.title }}"/>
</div>
{% if g.user.role_delete_books() %}
<div class="text-center">