From 747dda21c8fdfc10f817ab1ba482a2297f4ee629 Mon Sep 17 00:00:00 2001 From: Roberto Rosario Date: Thu, 15 Jan 2015 02:54:47 -0400 Subject: [PATCH] Add __unicode__ method for DocumentVersion model --- mayan/apps/documents/models.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mayan/apps/documents/models.py b/mayan/apps/documents/models.py index 52f8eda778..d698df3f0e 100644 --- a/mayan/apps/documents/models.py +++ b/mayan/apps/documents/models.py @@ -300,6 +300,9 @@ class DocumentVersion(models.Model): verbose_name = _(u'Document version') verbose_name_plural = _(u'Document version') + def __unicode__(self): + return u'{0} - {1}'.format(self.document, self.timestamp) + def save(self, *args, **kwargs): """ Overloaded save method that updates the document version's checksum,