From ca6e910c8a928a375535a4b8c55b12436919dc43 Mon Sep 17 00:00:00 2001 From: Sanj Date: Wed, 11 May 2011 01:59:02 +0530 Subject: [PATCH] model unicode methods should generally include their id. --- edgware/editor/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/edgware/editor/models.py b/edgware/editor/models.py index 4e6da7e..af5ae6d 100644 --- a/edgware/editor/models.py +++ b/edgware/editor/models.py @@ -82,7 +82,7 @@ class Product(models.Model): audios = models.ManyToManyField("Audio", blank=True) def __unicode__(self): - return "%s" % (self.title) + return "%d: %s" % (self.id, self.title,) def get_print_multiplier(self, dpi): # product = Product.objects.get(pk=self.product.id) @@ -269,7 +269,7 @@ class Article(models.Model): return m def __unicode__(self): - return self.name + return "%d: %s" % (self.id, self.name,) def get_dict(self, *args): if len(args) > 0: