diff --git a/gracedb/alert.py b/gracedb/alert.py index a6607a8199980941880d292238625128682661a7..10dc7791fb6ced2a158913a27767deea394a7e17 100644 --- a/gracedb/alert.py +++ b/gracedb/alert.py @@ -15,8 +15,7 @@ import glue.ligolw.utils import glue.lvalert.utils def issueAlert(event, location, temp_data_loc): -# Branson commented out just in case somebody is listening. -# issueXMPPAlert(event, location, temp_data_loc) + issueXMPPAlert(event, location, temp_data_loc) issueEmailAlert(event, location) def indent(nindent, text): @@ -68,6 +67,7 @@ def issueAlertForLabel(event, label, doxmpp): def issueEmailAlert(event, location): + # Gather Recipients if event.group.name == 'Test': fromaddress = settings.ALERT_TEST_EMAIL_FROM @@ -77,30 +77,13 @@ def issueEmailAlert(event, location): fromaddress = settings.ALERT_EMAIL_FROM toaddresses = settings.ALERT_EMAIL_TO bccaddresses = settings.ALERT_EMAIL_BCC -# Branson debugging. -# toaddresses = [] -# bccaddress = [] atype = AnalysisType.objects.filter(code=event.analysisType)[0] triggers = atype.trigger_set.filter(labels=None) - -# Branson debugging. -# dfile=open("/home/branson/gracedbdev/gracedb/dfile.txt", mode="w"); for trigger in triggers: for recip in trigger.contacts.all(): - if not trigger.farThresh: -# toaddresses = settings.ALERT_EMAIL_TO -# bccaddresses = settings.ALERT_EMAIL_BCC - bccaddresses.append(recip.email) - else: -# Branson debugging. -# dfile.write("event.far = %f\n" % event.far); - if event.far and event.far < trigger.farThresh: -# toaddresses = settings.ALERT_EMAIL_TO -# bccaddresses = settings.ALERT_EMAIL_BCC - bccaddresses.append(recip.email) -# Branson debugging. -# dfile.close() + bccaddresses.append(recip.email) + subject = "[gracedb] %s event. ID: %s" % (event.get_analysisType_display(), event.graceid()) message = """ New Event diff --git a/templates/admin/base_site.html b/templates/admin/base_site.html index 918fe2d06e68af0d98024cf83f06408a45fbc453..d531014fe246942a467fbd7f7a98eff14f19897c 100644 --- a/templates/admin/base_site.html +++ b/templates/admin/base_site.html @@ -19,7 +19,7 @@ <li id="nav-create"><a href="{% url create %}">Create</a></li> <li id="nav-reports"><a href="{% url reports %}">Reports</a></li> <li id="nav-feeds"><a href="{% url feeds %}">RSS</a></li> - <li id="nav-userprofile"><a href="{% url userprofile-home %}">Settings</a></li> + <li id="nav-userprofile"><a href="{% url userprofile-home %}">Options</a></li> {% if ligouser %}<li id="nav-user">Authenticated as: {{ ligouser.name }}</li>{% endif %} <ul> {% endblock %} diff --git a/templates/base.html b/templates/base.html index c58c173c186f7e88cae72a2d38cb0e1e448b82fc..f9eec575d1aba079a5c7d27d8730603ecf10cb99 100644 --- a/templates/base.html +++ b/templates/base.html @@ -36,7 +36,7 @@ function changeTime(obj, label) { <li id="nav-reports"><a href="{% url reports %}">Reports</a></li> <li id="nav-feeds"><a href="{% url feeds %}">RSS</a></li> <li id="nav-latest"><a href="{% url latest %}">Latest</a></li> - <li id="nav-userprofile"><a href="{% url userprofile-home %}">Settings</a></li> + <li id="nav-userprofile"><a href="{% url userprofile-home %}">Options</a></li> {% if ligouser %}<li id="nav-user">Authenticated as: {{ ligouser.name }}</li>{% endif %} </ul> <center> diff --git a/templates/gracedb/index.html b/templates/gracedb/index.html index 0048dbe3967859db42d1b488fc807b53fc5c3414..bd87b3857210a26f54419a5059619f943781f013 100644 --- a/templates/gracedb/index.html +++ b/templates/gracedb/index.html @@ -26,7 +26,7 @@ You can read about using the service on the <div class="text"> To receive email alerts when GraCEDb events are created, sign up on the <a target="_blank" href="http://listserv.ligo.org/cgi-bin/mailman/listinfo/gracedb">gracedb mailing list</a> or set up your own alert under the -<a href="{% url userprofile-home %}">Settings</a> menu item. +<a href="{% url userprofile-home %}">Options</a> menu item. </div> {% endblock %} diff --git a/templates/profile/createNotification.html b/templates/profile/createNotification.html index 42af3858db0c2287b849c6d17754614b4860d415..a5a81e1d9603d21e8c8ff97d48c29aa313601266 100644 --- a/templates/profile/createNotification.html +++ b/templates/profile/createNotification.html @@ -1,6 +1,6 @@ {% extends "base.html" %} -{% block title %}Settings | Create {{ creating }}{% endblock %} +{% block title %}Options | Create {{ creating }}{% endblock %} {% block heading %}Create {{ creating }}{% endblock %} {% block pageid %}userprofile{% endblock %} diff --git a/templates/profile/notifications.html b/templates/profile/notifications.html index e69215c78eabe44611a2fe7ecd43f3f272374c41..ea4105918b918c6b2b5549c9ba768ffeab1174e9 100644 --- a/templates/profile/notifications.html +++ b/templates/profile/notifications.html @@ -1,6 +1,6 @@ {% extends "base.html" %} -{% block title %}Settings | Notifications{% endblock %} +{% block title %}Options | Notifications{% endblock %} {% block heading %}Notifications{% endblock %} {% block pageid %}userprofile{% endblock %} diff --git a/urls.py b/urls.py index 9e8da698ba487eb8264138f69b6de08f852a3860..6684532c10dab2594ce0911542463c2ce27032bc 100644 --- a/urls.py +++ b/urls.py @@ -17,7 +17,7 @@ urlpatterns = patterns('', url (r'^$', 'gracedb.views.index', name="home"), (r'^events/', include('gracedb.urls')), (r'^api/', include('gracedb.urls_rest')), - (r'^settings/', include('userprofile.urls')), + (r'^options/', include('userprofile.urls')), (r'^cli/create', 'gracedb.views.create'), (r'^cli/ping', 'gracedb.views.ping'), (r'^cli/log', 'gracedb.views.log'),