summaryrefslogtreecommitdiff
path: root/ishtar_common/models.py
diff options
context:
space:
mode:
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r--ishtar_common/models.py10
1 files changed, 9 insertions, 1 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py
index d76d2e219..8d6278151 100644
--- a/ishtar_common/models.py
+++ b/ishtar_common/models.py
@@ -2405,6 +2405,8 @@ class Person(Address, Merge, OwnPerms, ValueGetter):
)
TABLE_COLS = ('name', 'surname', 'raw_name', 'email', 'person_types_list',
'attached_to__name', 'town')
+ TABLE_COLS_ACCOUNT = ('name', 'surname', 'raw_name', 'email',
+ 'profiles_list', 'attached_to__name', 'town')
SHOW_URL = 'show-person'
MODIFY_URL = 'person_modify'
BASE_SEARCH_VECTORS = ['name', 'surname', 'raw_name', 'town',
@@ -2418,7 +2420,7 @@ class Person(Address, Merge, OwnPerms, ValueGetter):
'attached_to': 'attached_to__pk',
'attached_to__name': 'attached_to__name',
'person_types': 'person_types__pk__in',
- 'ishtaruser__isnull': 'ishtaruser__isnull'
+ 'ishtaruser__isnull': 'ishtaruser__isnull',
}
COL_LABELS = {
'attached_to__name': _(u"Organization")
@@ -2525,6 +2527,12 @@ class Person(Address, Merge, OwnPerms, ValueGetter):
def person_types_list(self):
return u", ".join([unicode(pt) for pt in self.person_types.all()])
+ profiles_list_lbl = _(u"Profiles")
+
+ @property
+ def profiles_list(self):
+ return u", ".join([unicode(p) for p in self.profiles.all()])
+
def generate_merge_key(self):
if self.name and self.name.strip():
self.merge_key = slugify(self.name.strip()) + \