Should be part of r1855.
FOSDEM got the best of me :).
Patch by: Lennard de Rijk
Reviewed by: to-be-reviewed
--- a/app/soc/views/models/club_app.py Sat Feb 07 20:44:05 2009 +0000
+++ b/app/soc/views/models/club_app.py Sat Feb 07 21:43:27 2009 +0000
@@ -85,10 +85,6 @@
new_params['review_template'] = 'soc/club_app/review.html'
- new_params['sidebar_additional'] = [
- ('/%(url_name)s/review_overview/' % new_params,
- 'Review %(name_plural)s' % new_params, 'review_overview')]
-
params = dicts.merge(params, new_params)
super(View, self).__init__(params=params)
--- a/app/soc/views/models/group_app.py Sat Feb 07 20:44:05 2009 +0000
+++ b/app/soc/views/models/group_app.py Sat Feb 07 21:43:27 2009 +0000
@@ -66,7 +66,7 @@
new_params['create_template'] = 'soc/models/twoline_edit.html'
new_params['edit_template'] = 'soc/models/twoline_edit.html'
- patterns = [(r'^%(url_name)s/(?P<access_type>review_overview)/%(scope)s$',
+ patterns = [(r'^%(url_name)s/(?P<access_type>review_overview)$',
'soc.views.models.%(module_name)s.review_overview',
'Review %(name_plural)s'),
(r'^%(url_name)s/(?P<access_type>review)/%(key_fields)s$',
@@ -75,6 +75,10 @@
new_params['extra_django_patterns'] = patterns
+ new_params['sidebar_additional'] = [
+ ('/%(url_name)s/review_overview' % params,
+ 'Review %(name_plural)s' % params, 'review_overview')]
+
new_params['extra_dynaexclude'] = ['applicant', 'backup_admin', 'status',
'created_on', 'last_modified_on']
@@ -301,13 +305,8 @@
params = dicts.merge(params, self._params)
- filter = {}
-
- if kwargs['scope_path']:
- filter = {'scope_path': kwargs['scope_path']}
-
# only select the requests that haven't been reviewed yet
- filter['status'] = 'needs review'
+ filter = {'status' : 'needs review'}
ur_params = params.copy()
ur_params['list_description'] = ugettext('A list of all unhandled '
@@ -337,7 +336,7 @@
pa_params ['list_action'] = (redirects.getReviewRedirect, params)
pa_list = list_helper.getListContent(
- request, pa_params, filter, 2)
+ request, pa_params, filter, 4)
# only select the requests the have been rejected
filter ['status'] = 'rejected'
@@ -348,7 +347,7 @@
den_params ['list_action'] = (redirects.getReviewRedirect, params)
den_list = list_helper.getListContent(
- request, den_params, filter, 3)
+ request, den_params, filter, 2)
# only select the request that have been ignored
filter ['status'] = 'ignored'
@@ -359,7 +358,7 @@
ign_params ['list_action'] = (redirects.getReviewRedirect, params)
ign_list = list_helper.getListContent(
- request, ign_params, filter, 4)
+ request, ign_params, filter, 3)
# fill contents with all the needed lists
contents = [ur_list, uh_list, pa_list, den_list, ign_list]
--- a/app/soc/views/models/org_app.py Sat Feb 07 20:44:05 2009 +0000
+++ b/app/soc/views/models/org_app.py Sat Feb 07 21:43:27 2009 +0000
@@ -63,7 +63,7 @@
# TODO(ljvderijk) fix host access check
rights['review'] = ['checkIsHostForProgram',
('checkCanReviewGroupApp', [org_app_logic.logic])]
- rights['review_overview'] = ['checkIsHostForProgram']
+ rights['review_overview'] = ['checkIsDeveloper']
rights['apply'] = ['checkIsUser',
('checkCanCreateOrgApp', ['org_signup'])]
@@ -79,10 +79,7 @@
patterns = [(r'^%(url_name)s/(?P<access_type>apply)/%(scope)s$',
'soc.views.models.%(module_name)s.create',
- 'Create an %(name_plural)s'),
- (r'^%(url_name)s/(?P<access_type>list)/%(scope)s$',
- 'soc.views.models.%(module_name)s.create',
- 'Create an %(name_plural)s')]
+ 'Create an %(name_plural)s'),]
new_params['extra_django_patterns'] = patterns