Skip to content

Commit 32a09df

Browse files
author
Richard Jones
committed
have 'roundup-admin security' display property restrictions [SF#1222135]
1 parent 099b509 commit 32a09df

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

CHANGES.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@ Fixed:
1919
- enabled disabling of REMOTE_USER for when it's not a valid username (sf
2020
bug 1190187)
2121
- fix invocation of hasPermission from templating code (sf bug 1224172)
22+
- have 'roundup-admin security' display property restrictions (sf bug
23+
1222135)
2224

2325

2426
2005-05-02 0.8.3

roundup/admin.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
1717
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
1818
#
19-
# $Id: admin.py,v 1.94 2005-05-06 06:49:54 a1s Exp $
19+
# $Id: admin.py,v 1.95 2005-06-24 05:32:56 richard Exp $
2020

2121
'''Administration commands for maintaining Roundup trackers.
2222
'''
@@ -1251,11 +1251,16 @@ def do_security(self, args):
12511251
for rolename, role in roles:
12521252
print _('Role "%(name)s":')%role.__dict__
12531253
for permission in role.permissions:
1254+
d = permission.__dict__
12541255
if permission.klass:
1255-
print _(' %(description)s (%(name)s for "%(klass)s" '
1256-
'only)')%permission.__dict__
1256+
if permission.properties:
1257+
print _(' %(description)s (%(name)s for "%(klass)s"'
1258+
': %(properties)s only)')%d
1259+
else:
1260+
print _(' %(description)s (%(name)s for "%(klass)s" '
1261+
'only)')%d
12571262
else:
1258-
print _(' %(description)s (%(name)s)')%permission.__dict__
1263+
print _(' %(description)s (%(name)s)')%d
12591264
return 0
12601265

12611266
def run_command(self, args):

0 commit comments

Comments
 (0)