diff -r fc63b80ec979 -r 1d25e928c299 web/views/emailaddress.py --- a/web/views/emailaddress.py Mon Sep 14 11:25:56 2009 +0200 +++ b/web/views/emailaddress.py Tue Sep 15 15:01:41 2009 +0200 @@ -24,17 +24,9 @@ def render_entity_attributes(self, entity): self.w(u'

') entity.view('oneline', w=self.w) - if not entity.canonical: - canonemailaddr = entity.canonical_form() - if canonemailaddr: - self.w(u' (%s)' % canonemailaddr.view('oneline')) - self.w(u'

') - elif entity.identical_to: - self.w(u'') - identicaladdr = [e.view('oneline') for e in entity.identical_to] - self.field('identical_to', ', '.join(identicaladdr)) - else: - self.w(u'') + if entity.prefered: + self.w(u' (%s)' % entity.prefered.view('oneline')) + self.w(u'') try: persons = entity.reverse_primary_email except Unauthorized: @@ -88,6 +80,7 @@ if entity.reverse_primary_email: self.w(u'') + class EmailAddressMailToView(baseviews.OneLineView): """A one line view that builds a user clickable URL for an email with 'mailto:'"""