When Student withdrew a proposal a public comment "Student withdrew proposal." is posted.
Patch by: Pawel Solyga
Reviewed by: to-be-reviewed
--- a/app/soc/views/models/student_proposal.py Mon Apr 06 10:11:44 2009 +0000
+++ b/app/soc/views/models/student_proposal.py Mon Apr 06 11:04:57 2009 +0000
@@ -507,7 +507,8 @@
proposal_logic = params['logic']
student_proposal_entity = proposal_logic.getForFields(filter, unique=True)
-
+ reviewer = student_proposal_entity.scope
+
# update the entity mark it as invalid
proposal_logic.updateEntityProperties(student_proposal_entity,
{'status': 'invalid'})
@@ -515,7 +516,9 @@
# redirect to the program's homepage
redirect_url = redirects.getHomeRedirect(student_proposal_entity.program,
{'url_name': 'program'})
-
+
+ comment = "Student withdrew proposal."
+ self._createReviewFor(student_proposal_entity, reviewer, comment)
return http.HttpResponseRedirect(redirect_url)
return super(View, self).edit(request=request, access_type=access_type,