# HG changeset patch # User Lennard de Rijk # Date 1232921713 0 # Node ID f05c02ba40fc715dcec1aba92fb6b3bba0da2a1e # Parent 99c46908b4b648f2a6d262cd41b4941e6411d3f7 listRequests now only shows the requests that concerns the given group. Patch by: Lennard de Rijk Reviewed by: to-be-reviewed diff -r 99c46908b4b6 -r f05c02ba40fc app/soc/views/models/group.py --- a/app/soc/views/models/group.py Sun Jan 25 22:05:25 2009 +0000 +++ b/app/soc/views/models/group.py Sun Jan 25 22:15:13 2009 +0000 @@ -124,10 +124,16 @@ # set the pagename to include the link_id page_name = '%s %s' %(page_name, kwargs['link_id']) + # get the group from the request + group_logic = params['logic'] + + group_entity = group_logic.getFromFields(**kwargs) + role_names = params['roles_logic'].keys() - + # list all incoming requests filter = { + 'scope' : group_entity, 'role': role_names, 'state': 'new' } @@ -145,6 +151,7 @@ # list all outstanding invites filter = { + 'scope' : group_entity, 'role': role_names, 'state': 'group_accepted' } @@ -162,6 +169,7 @@ # list all ignored requests filter = { + 'scope' : group_entity, 'role': role_names, 'state': 'ignored' }