Skip to content
Snippets Groups Projects
Commit 1e6c4a69 authored by Tanner Prestegard's avatar Tanner Prestegard Committed by GraceDB
Browse files

Bugfixes for operator signoff display on home page

parent e5aa17a3
No related branches found
No related tags found
No related merge requests found
......@@ -119,10 +119,10 @@ def index(request):
context['new_signoff_graceids'] = [e.graceid for e in new_events]
context['older_signoff_graceids'] = [e.graceid for e in older_events]
# TODO: ensure not test or MDC types once those are implemented
# Superevent signoffs
context['signoff_superevent_ids'] = [s.superevent_id for s in
Superevent.objects.filter(labelling__label__name=label_name)]
Superevent.objects.filter(labelling__label__name=label_name,
category=Superevent.SUPEREVENT_CATEGORY_PRODUCTION)]
recent_events = ''
if request.user and not is_external(request.user) and settings.SHOW_RECENT_EVENTS_ON_HOME:
......
......@@ -91,10 +91,11 @@ follow-ups. </p>
<!--XXX Infrastructure for human signoffs. Hopefully this will not be permanent. -->
{% if signoff_authorized %}
{% if new_signoff_graceids|length or older_signoff_graceids|length %}
{% if signoff_superevent_ids|length or new_signoff_graceids|length or older_signoff_graceids|length %}
<div class="signoff-area">
<h2>Attention {{signoff_instrument}} Operator</h2>
<br />
<h2>Attention {{signoff_instrument}} Operator</h2>
<br />
{% if signoff_superevent_ids|length %}
<h3>The following superevents require your signoff:</h3>
{% if signoff_superevent_ids|length %}
<ul>
......@@ -103,6 +104,8 @@ follow-ups. </p>
{% endfor %}
</ul>
{% endif %}
{% endif %}
{% if new_signoff_graceids|length or older_signoff_graceids|length %}
<h3>The following events require your sign-off:</h3>
{% if new_signoff_graceids|length %}
<p>Events submitted within the last 24 hours:</p>
......@@ -120,7 +123,8 @@ follow-ups. </p>
{% endfor %}
</ul>
{% endif %}
<p>Please click on the link(s) above and use the form at the top of the page.</p>
{% endif %}
<p>Please click on the link(s) above and use the form at the top of the page.</p>
</div>
{% endif %}
{% endif %}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment