From 923f517a8f22ecef87b1695fda418383cf0ab2c0 Mon Sep 17 00:00:00 2001 From: Nick Sweeting Date: Mon, 1 Feb 2021 02:17:54 -0500 Subject: [PATCH] minor fixes --- archivebox/core/admin.py | 1 + archivebox/index/html.py | 7 ++++++- archivebox/templates/core/snapshot.html | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/archivebox/core/admin.py b/archivebox/core/admin.py index ea51f668..bacc53c0 100644 --- a/archivebox/core/admin.py +++ b/archivebox/core/admin.py @@ -106,6 +106,7 @@ class SnapshotAdmin(SearchResultsAdminMixin, admin.ModelAdmin): actions = [delete_snapshots, overwrite_snapshots, update_snapshots, update_titles, verify_snapshots] actions_template = 'admin/actions_as_select.html' form = SnapshotAdminForm + list_per_page = 40 def get_urls(self): urls = super().get_urls() diff --git a/archivebox/index/html.py b/archivebox/index/html.py index 5eba0959..d97c6595 100644 --- a/archivebox/index/html.py +++ b/archivebox/index/html.py @@ -118,6 +118,8 @@ def render_django_template(template: str, context: Mapping[str, str]) -> str: def snapshot_icons(snapshot) -> str: from core.models import EXTRACTORS + # start = datetime.now() + archive_results = snapshot.archiveresult_set.filter(status="succeeded") link = snapshot.as_link() path = link.archive_path @@ -169,4 +171,7 @@ def snapshot_icons(snapshot) -> str: output += '{} '.format(canon["archive_org_path"], str(exists), "archive_org", icons.get("archive_org", "?")) - return format_html('{}', mark_safe(output)) + result = format_html('{}', mark_safe(output)) + # end = datetime.now() + # print(((end - start).total_seconds()*1000) // 1, 'ms') + return result diff --git a/archivebox/templates/core/snapshot.html b/archivebox/templates/core/snapshot.html index ebf2385a..839df05c 100644 --- a/archivebox/templates/core/snapshot.html +++ b/archivebox/templates/core/snapshot.html @@ -484,7 +484,7 @@ - +