From 935a15f46ad6b30033d08bb6994f9f08bc777c5b Mon Sep 17 00:00:00 2001
From: Magnus Hagander <magnus@hagander.net>
Date: Tue, 16 Feb 2016 17:20:22 +0100
Subject: [PATCH] Log is not a separate page anymore, so fix links

Also add an anchor on the edit page to deal with it
---
 .../register/templates/aggregatorlog.html     | 26 -------------------
 .../hamnadmin/register/templates/edit.html    |  1 +
 .../hamnadmin/register/templates/index.html   |  4 +--
 3 files changed, 3 insertions(+), 28 deletions(-)
 delete mode 100644 hamnadmin/hamnadmin/register/templates/aggregatorlog.html

diff --git a/hamnadmin/hamnadmin/register/templates/aggregatorlog.html b/hamnadmin/hamnadmin/register/templates/aggregatorlog.html
deleted file mode 100644
index b3892b7..0000000
--- a/hamnadmin/hamnadmin/register/templates/aggregatorlog.html
+++ /dev/null
@@ -1,26 +0,0 @@
-{% extends "regbase.html" %}
-{%block regcontent %}
-<p>
-This is a log of the most recent activity on your feed. Note that only
-operations that had some effect are logged. The normal fetches that are
-made every 15 minutes don't log anything unless they found new posts or
-some error occurred.
-</p>
-<p>
-Return to <a href="../..">blog list</a>.
-</p>
-<table border="1" cellspacing="0" cellpadding="1">
-<tr>
- <th>Time</th>
- <th>Status</th>
- <th>Info</th>
-</tr>
-{% for entry in entries %}
-<tr valign="top">
- <td>{{entry.ts}}</td>
- <td>{{entry.success|yesno:"Success,Failure"}}</td>
- <td>{{entry.info}}</td>
-</tr>
-{%endfor%}
-</table>
-{% endblock %}
diff --git a/hamnadmin/hamnadmin/register/templates/edit.html b/hamnadmin/hamnadmin/register/templates/edit.html
index ef9e272..9f0abae 100644
--- a/hamnadmin/hamnadmin/register/templates/edit.html
+++ b/hamnadmin/hamnadmin/register/templates/edit.html
@@ -104,6 +104,7 @@ The blog is currently waiting for moderator approval.
 </form>
 
 {%if not new%}
+<a name="log"></a>
 <h3>Log</h3>
 <table class="table table-condensed table-striped">
   <tr>
diff --git a/hamnadmin/hamnadmin/register/templates/index.html b/hamnadmin/hamnadmin/register/templates/index.html
index ed5256b..e6e1c87 100644
--- a/hamnadmin/hamnadmin/register/templates/index.html
+++ b/hamnadmin/hamnadmin/register/templates/index.html
@@ -42,9 +42,9 @@ Last http get: {{blog.lastget|date:"Y-m-d H:i:s"}}<br/>
    {%elif blog.approved%}
     {%if blog.recent_failures%}
      {%if blog.recent_failures > 5%}
-      <a href="log/{{blog.id}}/"><span class="label label-danger">Multiple failures</span></a>
+      <a href="edit/{{blog.id}}/#log"><span class="label label-danger">Multiple failures</span></a>
      {%else%}
-      <a href="log/{{blog.id}}/"><span class="label label-warning">Sporadic errors</span></a>
+      <a href="edit/{{blog.id}}/#log"><span class="label label-warning">Sporadic errors</span></a>
     {%endif%}
    {%else%}
     <span class="label label-success">Approved and working</span>
-- 
2.39.5

