equal
deleted
inserted
replaced
74 |
74 |
75 class EmailAddressOneLineView(baseviews.OneLineView): |
75 class EmailAddressOneLineView(baseviews.OneLineView): |
76 __select__ = implements('EmailAddress') |
76 __select__ = implements('EmailAddress') |
77 |
77 |
78 def cell_call(self, row, col, **kwargs): |
78 def cell_call(self, row, col, **kwargs): |
79 entity = self.entity(row, col) |
79 entity = self.rset.get_entity(row, col) |
80 if entity.reverse_primary_email: |
80 if entity.reverse_primary_email: |
81 self.w(u'<b>') |
81 self.w(u'<b>') |
82 if entity.alias: |
82 if entity.alias: |
83 self.w(u'%s <' % xml_escape(entity.alias)) |
83 self.w(u'%s <' % xml_escape(entity.alias)) |
84 self.w('<a href="%s">%s</a>' % (xml_escape(entity.absolute_url()), |
84 self.w('<a href="%s">%s</a>' % (xml_escape(entity.absolute_url()), |
94 |
94 |
95 id = 'mailto' |
95 id = 'mailto' |
96 __select__ = implements('EmailAddress') |
96 __select__ = implements('EmailAddress') |
97 |
97 |
98 def cell_call(self, row, col, **kwargs): |
98 def cell_call(self, row, col, **kwargs): |
99 entity = self.entity(row, col) |
99 entity = self.rset.get_entity(row, col) |
100 if entity.reverse_primary_email: |
100 if entity.reverse_primary_email: |
101 self.w(u'<b>') |
101 self.w(u'<b>') |
102 if entity.alias: |
102 if entity.alias: |
103 alias = entity.alias |
103 alias = entity.alias |
104 elif entity.reverse_use_email: |
104 elif entity.reverse_use_email: |
117 |
117 |
118 class EmailAddressTextView(baseviews.TextView): |
118 class EmailAddressTextView(baseviews.TextView): |
119 __select__ = implements('EmailAddress') |
119 __select__ = implements('EmailAddress') |
120 |
120 |
121 def cell_call(self, row, col, **kwargs): |
121 def cell_call(self, row, col, **kwargs): |
122 self.w(self.entity(row, col).display_address()) |
122 self.w(self.rset.get_entity(row, col).display_address()) |