+ list_filter = ['form_tag']
+
+ def admin_list(self, obj, nr):
+ try:
+ field_name = contact_forms[obj.form_tag].admin_list[nr]
+ except BaseException, e:
+ return ''
+ else:
+ return obj.body.get(field_name, '')
+
+ def __getattr__(self, name):
+ if name.startswith('admin_list_'):
+ nr = int(name[len('admin_list_'):])
+ return lambda obj: self.admin_list(obj, nr)
+ raise AttributeError, name