diff options
author | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-01-20 19:59:38 +0100 |
---|---|---|
committer | Étienne Loks <etienne.loks@iggdrasil.net> | 2017-01-20 19:59:38 +0100 |
commit | 34e2ab88b6a4e33784f1306bae3e27df1b355739 (patch) | |
tree | c7946c091644647edbb3a4eb27ca5a5bc9def18e /ishtar_common/menu_base.py | |
parent | 1d7b5ef3055236b56ec1e104ab66a6ccc8e3da14 (diff) | |
parent | d006f284d408ccc00ba5f93ddd845ef2950f0ea3 (diff) | |
download | Ishtar-34e2ab88b6a4e33784f1306bae3e27df1b355739.tar.bz2 Ishtar-34e2ab88b6a4e33784f1306bae3e27df1b355739.zip |
Merge branch 'master' into v0.9
Diffstat (limited to 'ishtar_common/menu_base.py')
-rw-r--r-- | ishtar_common/menu_base.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ishtar_common/menu_base.py b/ishtar_common/menu_base.py index 64dfbae95..0117b375d 100644 --- a/ishtar_common/menu_base.py +++ b/ishtar_common/menu_base.py @@ -21,13 +21,14 @@ from ishtar_common.models import get_current_profile class SectionItem: - def __init__(self, idx, label, childs=[], profile_restriction=None): + def __init__(self, idx, label, childs=[], profile_restriction=None, css=''): self.idx = idx self.label = label self.childs = childs self.available = False self.items = {} self.profile_restriction = profile_restriction + self.css = css def check_profile_restriction(self): if self.profile_restriction: @@ -63,13 +64,14 @@ class SectionItem: class MenuItem: def __init__(self, idx, label, model=None, access_controls=[], - profile_restriction=None): + profile_restriction=None, css=''): self.idx = idx self.label = label self.model = model self.access_controls = access_controls self.available = False self.profile_restriction = profile_restriction + self.css = css if not self.check_profile_restriction(): return False |