From c949320aa6a7c5b91ee8e8c0fb9d08ca3e275eea Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Vinot?= Date: Fri, 7 Aug 2020 11:58:20 +0200 Subject: [PATCH] new: Add link to download redirects on tree page --- website/web/__init__.py | 2 +- website/web/templates/tree.html | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/website/web/__init__.py b/website/web/__init__.py index fd998681..7596e479 100644 --- a/website/web/__init__.py +++ b/website/web/__init__.py @@ -402,7 +402,7 @@ def tree(tree_uuid: str, urlnode_uuid: Optional[str]=None): return render_template('tree.html', tree_json=tree_json, start_time=start_time, user_agent=user_agent, root_url=root_url, tree_uuid=tree_uuid, meta=meta, enable_mail_notification=enable_mail_notification, - urlnode_uuid=urlnode_uuid) + urlnode_uuid=urlnode_uuid, has_redirects=True if cache['redirects'] else False) except NoValidHarFile as e: return render_template('error.html', error_message=e) diff --git a/website/web/templates/tree.html b/website/web/templates/tree.html index 6c1aaa04..d6ee2f61 100644 --- a/website/web/templates/tree.html +++ b/website/web/templates/tree.html @@ -87,6 +87,11 @@ Show Statistics + {% if has_redirects %} +
  • + Download redirects +
  • + {% endif %}
  • Unflag all nodes
  • @@ -100,7 +105,7 @@
  • Notify by mail
  • - {%endif%} + {% endif %}