From cf0cf84d563c7433230b21e66c0a292677df500c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Tue, 28 Feb 2012 09:26:31 +0100 Subject: [PATCH] Better titles --- trans/models.py | 2 +- trans/views.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/trans/models.py b/trans/models.py index c80ea195b..fe14c1ac2 100644 --- a/trans/models.py +++ b/trans/models.py @@ -165,7 +165,7 @@ class Translation(models.Model): return ('trans.views.show_translation', (), {'project': self.subproject.slug, 'subproject': self.subproject.slug, 'lang': self.language.code}) def __unicode__(self): - return '%s@%s' % (self.language.name, self.subproject.__unicode__()) + return '%s %s' % (self.language.name, self.subproject.__unicode__()) def update_from_blob(self, blob): ''' diff --git a/trans/views.py b/trans/views.py index bff6618e1..20e8fbc13 100644 --- a/trans/views.py +++ b/trans/views.py @@ -8,7 +8,7 @@ def show_project(request, project): return render_to_response('project.html', RequestContext(request, { 'object': obj, - 'title': '%s @ Weblate' % obj.name, + 'title': '%s @ Weblate' % (obj.__unicode__()), })) def show_subproject(request, project, subproject): @@ -16,7 +16,7 @@ def show_subproject(request, project, subproject): return render_to_response('subproject.html', RequestContext(request, { 'object': obj, - 'title': '%s/%s @ Weblate' % (obj.name, obj.project.name), + 'title': '%s @ Weblate' % (obj.__unicode__()), })) def show_translation(request, project, subproject, lang): @@ -24,6 +24,6 @@ def show_translation(request, project, subproject, lang): return render_to_response('translation.html', RequestContext(request, { 'object': obj, - 'title': '%s %s/%s @ Weblate' % (obj.language.name, obj.subproject.name, obj.subproject.project.name), + 'title': '%s @ Weblate' % (obj.__unicode__()), }))