summaryrefslogtreecommitdiff
path: root/ishtar_common/menu_base.py
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@peacefrogs.net>2013-08-23 18:25:58 +0200
committerÉtienne Loks <etienne.loks@peacefrogs.net>2013-08-23 18:25:58 +0200
commit7be596f41305b4be26796625bd800d58a04bb0a7 (patch)
tree9743bec37b2c651fafecfc373a1d5bb8bc2aadc3 /ishtar_common/menu_base.py
parented74b751839d42d30a74b0d67a47ae138a537377 (diff)
downloadIshtar-7be596f41305b4be26796625bd800d58a04bb0a7.tar.bz2
Ishtar-7be596f41305b4be26796625bd800d58a04bb0a7.zip
PersonType from single value to multi value for Person
Diffstat (limited to 'ishtar_common/menu_base.py')
-rw-r--r--ishtar_common/menu_base.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/ishtar_common/menu_base.py b/ishtar_common/menu_base.py
index 37f482219..11ce4e688 100644
--- a/ishtar_common/menu_base.py
+++ b/ishtar_common/menu_base.py
@@ -62,8 +62,7 @@ class MenuItem:
return True
# manage by person type
if hasattr(user, 'ishtaruser'):
- person_type = user.ishtaruser.person.person_type
- if person_type.rights.filter(wizard__url_name=self.idx).count():
+ if ishtar_user.has_right(self.idx):
return True
return False
@@ -76,8 +75,7 @@ class MenuItem:
return True
# manage by person type
if hasattr(user, 'ishtaruser'):
- person_type = user.ishtaruser.person.person_type
- if person_type.rights.filter(wizard__url_name=self.idx).count():
+ if ishtar_user.has_right(self.idx):
return True
return False