diff --git a/gracedb/alert.py b/gracedb/alert.py index f61d4353aec3a617aa480fb1aa094756c6aec462..24d1b0dc7595ed0eff5eac54a2e6cf1bc34cfc83 100644 --- a/gracedb/alert.py +++ b/gracedb/alert.py @@ -30,9 +30,9 @@ def prepareSummary(event): return "GPS Time: %s" % event.gpstime -def issueAlertForUpdate(event, description, doxmpp): +def issueAlertForUpdate(event, description, doxmpp, filename=""): if doxmpp: - issueXMPPAlert(event, "", "", "update", description) + issueXMPPAlert(event, filename, "", "update", description) # XXX No emails for this. Argh. def issueAlertForLabel(event, label, doxmpp): diff --git a/gracedb/api.py b/gracedb/api.py index 6064ca3fca8e0a655e825426dc5ed01576b3a406..11157c5a8a586e204064ad1f0502f6fce41b3935 100644 --- a/gracedb/api.py +++ b/gracedb/api.py @@ -803,7 +803,7 @@ class Files(APIView): try: description = "UPLOAD: {0}".format(filename) - issueAlertForUpdate(event, description, doxmpp=True) + issueAlertForUpdate(event, description, doxmpp=True, filename=filename) except: # XXX something should be done here. pass diff --git a/gracedb/views.py b/gracedb/views.py index 9515fc37ee5dc821e13c9dc5b402fb44c2657dc5..3961a80c75021cc03cc3644aa77552e8f1d09975 100644 --- a/gracedb/views.py +++ b/gracedb/views.py @@ -304,7 +304,7 @@ def _createLog(request, graceid, comment, uploadedFile=None): description = "LOG: " if uploadedFile: description = "UPLOAD: '%s' " % uploadedFile.name - issueAlertForUpdate(event, description+comment, doxmpp=True) + issueAlertForUpdate(event, description+comment, doxmpp=True, filename=uploadedFile.name) # XXX should be json rval = str(rdict)