summaryrefslogtreecommitdiff
path: root/pgcommitfest/commitfest/models.py
diff options
context:
space:
mode:
Diffstat (limited to 'pgcommitfest/commitfest/models.py')
-rw-r--r--pgcommitfest/commitfest/models.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/pgcommitfest/commitfest/models.py b/pgcommitfest/commitfest/models.py
index 124af72..e1b83b4 100644
--- a/pgcommitfest/commitfest/models.py
+++ b/pgcommitfest/commitfest/models.py
@@ -183,6 +183,10 @@ class PatchHistory(models.Model):
by = models.ForeignKey(User, blank=False, null=False)
what = models.CharField(max_length=500, null=False, blank=False)
+ @property
+ def by_string(self):
+ return "%s %s (%s)" % (self.by.first_name, self.by.last_name, self.by.username)
+
def __unicode__(self):
return "%s - %s" % (self.patch.name, self.date)