summaryrefslogtreecommitdiff
path: root/templates/mirrors
diff options
context:
space:
mode:
authorLuke Shumaker <lukeshu@sbcglobal.net>2015-04-16 02:50:22 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2015-04-16 02:50:22 -0400
commitd2eb47c0dfc068c7727232d89daeee377969288d (patch)
treea28b938c1eef550a5a0d21fdab0b1fef41d4ffd3 /templates/mirrors
parent4da7072d827b6cc2cd3aeae908b221b58738f364 (diff)
parentc8d979b8a48805d162ab46cdc4e493da0aa1595c (diff)
Merge branch 'archweb-generic'
Diffstat (limited to 'templates/mirrors')
-rw-r--r--templates/mirrors/error_table.html.jinja8
-rw-r--r--templates/mirrors/url_details_logs.html.jinja4
2 files changed, 7 insertions, 5 deletions
diff --git a/templates/mirrors/error_table.html.jinja b/templates/mirrors/error_table.html.jinja
index 52f68135..132aae63 100644
--- a/templates/mirrors/error_table.html.jinja
+++ b/templates/mirrors/error_table.html.jinja
@@ -7,16 +7,18 @@
<th>Error Message</th>
<th>Last Occurred</th>
<th>Occurrences (last {{ cutoff|hours }})</th>
+ <th></th>
</tr>
</thead>
<tbody>
{% for log in error_logs %}<tr class="{{ loop.cycle('odd', 'even') }}">
- <td>{{ log.url__url }}</td>
- <td>{{ log.url__protocol__protocol }}</td>
- <td class="country">{{ country_flag(log.country) }}{{ log.country.name }}</td>
+ <td>{{ log.url.url }}</td>
+ <td>{{ log.url.protocol.protocol }}</td>
+ <td class="country">{{ country_flag(log.url.country) }}{{ log.url.country.name }}</td>
<td class="wrap">{{ log.error|linebreaksbr }}</td>
<td>{{ log.last_occurred|date('Y-m-d H:i') }}</td>
<td>{{ log.error_count }}</td>
+ <td><a href="{{ log.url.get_absolute_url() }}">details</a></td>
</tr>{% endfor %}
</tbody>
</table>
diff --git a/templates/mirrors/url_details_logs.html.jinja b/templates/mirrors/url_details_logs.html.jinja
index 58f179d8..51f54931 100644
--- a/templates/mirrors/url_details_logs.html.jinja
+++ b/templates/mirrors/url_details_logs.html.jinja
@@ -14,8 +14,8 @@
<tbody>
{% for log in logs %}<tr class="{{ loop.cycle('odd', 'even') }}">
<td>{{ log.check_time|date('Y-m-d H:i') }}</td>
- <td class="country">{{ country_flag(log.location.country) }}{{ log.location.country.name }}</td>
- <td>{{ log.location.source_ip }}</td>
+ <td class="country">{% if log.location %}{{ country_flag(log.location.country) }}{{ log.location.country.name }}{% else %}Unknown{% endif %}</td>
+ <td>{% if log.location %}{{ log.location.source_ip }}{% else %}Unknown{% endif %}</td>
<td>{{ log.last_sync|date('Y-m-d H:i') }}</td>
<td>{{ log.delay|duration }}</td>
<td>{{ log.duration|floatvalue }}</td>