diff --git a/tailbone/views/master.py b/tailbone/views/master.py index ea911bd0..79f537e0 100644 --- a/tailbone/views/master.py +++ b/tailbone/views/master.py @@ -905,6 +905,19 @@ class MasterView(View): """ return obj.id_str + def render_as_is(self, obj, field): + return getattr(obj, field) + + def render_url(self, obj, field): + url = getattr(obj, field) + if url: + return tags.link_to(url, url, target='_blank') + + def render_html(self, obj, field): + html = getattr(obj, field) + if html: + return HTML.literal(html) + def render_default_phone(self, obj, field): """ Render the "default" (first) phone number for the given contact.