listRequests now only shows the requests that concerns the given group.
Patch by: Lennard de Rijk
Reviewed by: to-be-reviewed
--- 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'
}