Permission issue
Chuck Cunningham <[email protected]>
| Newsgroups | gmane.comp.bug-tracking.roundup.user |
|---|---|
| Message-ID | <CAH-41388SWAGShnEKUuEuZs727f2yCkd4=-nVejkFcCoHhQ3uA@mail.gmail.com> |
Hi --
I've been trying to implement this customization below, from
https://www.roundup-tracker.org/docs/customizing.html#examples
It works nicely except for one thing - the dropdowns for "Sort on" and
'Group on" on the webpage become empty when I put this into schema.py, and
I can't sort or group when logged in (although anonymous still has the
dropdowns)...It seems like a permission issue, but I can't figure out what
permission controls those dropdowns...any advice would be appreciated!
All users may only view and edit issues, files and messages they create
<https://www.roundup-tracker.org/docs/customizing.html#id126>
Replace the standard “classic” tracker View and Edit Permission assignments
for the “issue”, “file” and “msg” classes with the following:
def checker(klass):
def check(db, userid, itemid, klass=klass):
return db.getclass(klass).get(itemid, 'creator') == userid
return checkfor cl in 'issue', 'file', 'msg':
p = db.security.addPermission(name='View', klass=cl,
check=checker(cl))
db.security.addPermissionToRole('User', p)
p = db.security.addPermission(name='Edit', klass=cl,
check=checker(cl))
db.security.addPermissionToRole('User', p)
db.security.addPermissionToRole('User', 'Create', cl)
_______________________________________________
Roundup-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/roundup-users