Skip to content
Snippets Groups Projects
Commit c57dcd69 authored by Tanner Prestegard's avatar Tanner Prestegard Committed by gracedb-dev1
Browse files

fixing display for Trigger and Contact models as this caused errors in IPython...

fixing display for Trigger and Contact models as this caused errors in IPython with certain unicode characters
parent edaa9d11
No related branches found
No related tags found
No related merge requests found
......@@ -47,8 +47,7 @@ class Contact(models.Model):
text_phone = models.BooleanField(default=False)
def __unicode__(self):
return u"{0} {1}: {2}".format(self.user.first_name,
self.user.last_name, self.desc)
return u"{0}: {1}".format(self.user.username, self.desc)
def clean(self):
# Mostly used for preventing creation of bad Contact
......@@ -94,9 +93,8 @@ class Trigger(models.Model):
label_query = models.CharField(max_length=100, blank=True)
def __unicode__(self):
return (u"%s %s: %s") % (
self.user.first_name,
self.user.last_name,
return (u"%s: %s") % (
self.user.username,
self.userlessDisplay()
)
......
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