Menu

[r5798]: / trunk / gui / account / nav.py  Maximize  Restore  History

Download this file

64 lines (49 with data), 1.7 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
from django_nav import Nav, NavOption
from django.utils.translation import ugettext as _
import models
ICON = u'AccountIcon'
class ChangePass(NavOption):
name = _('Change Password')
type = 'changepass'
icon = u'ChangePasswordIcon'
append_app = False
options = []
class ChangeAdmin(NavOption):
name = _('Change Admin User')
type = 'changeadmin'
icon = u'ChangeAdminIcon'
append_app = False
options = []
#class Logout(NavOption):
#
# name = _('Logout')
# type = 'logout'
# icon = u'LogOutIcon'
# append_app = False
# options = []
class MyAccount(NavOption):
name = _('My Account')
icon = u'MyAccountIcon'
order = -1
#options = [ChangePass, ChangeAdmin, Logout]
options = [ChangePass, ChangeAdmin]
class ViewUsers(NavOption):
name = _('View All Users')
type = 'viewusers'
icon = u'ViewAllUsersIcon'
append_app = False
options = []
def __init__(self, *args, **kwargs):
if models.bsdUsers._admin.icon_view is not None:
icon = models.bsdUsers._admin.icon_view
super(ViewUsers, self).__init__(*args, **kwargs)
class ViewGroups(NavOption):
name = _('View All Groups')
type = 'viewgroups'
icon = u'ViewAllGroupsIcon'
append_app = False
options = []
def __init__(self, *args, **kwargs):
if models.bsdGroups._admin.icon_view is not None:
icon = models.bsdGroups._admin.icon_view
super(ViewGroups, self).__init__(*args, **kwargs)
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.