From 730ac948b5dfb70646fad96cd7bad0453b9f0cea Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Fri, 21 Dec 2012 19:11:47 -0600 Subject: Add a __unicode__ method for RecentUpdate Signed-off-by: Dan McGee --- public/utils.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/public/utils.py b/public/utils.py index bf74881..c283821 100644 --- a/public/utils.py +++ b/public/utils.py @@ -49,6 +49,10 @@ class RecentUpdate(object): if package.arch not in arches and not arches.add(package.arch): yield PackageStandin(package) + def __unicode__(self): + return "RecentUpdate '%s %s' <%d packages>" % ( + self.pkgbase, self.version, len(self.packages)) + @cache_function(62) def get_recent_updates(number=15, testing=True, staging=False): repos = Repo.objects.all() -- cgit v1.2.3-24-g4f1b