Commit 115f5b2c by Don Mitchell

Merge pull request #3791 from edx/dhm/bug_open_ended_notifications

Dhm/bug open ended notifications
parents 9dc48c00 08aaa97b
......@@ -191,7 +191,8 @@ class PeerGradingModule(PeerGradingFields, XModule):
if not self.use_for_single_location_local:
return self.peer_grading()
else:
return self.peer_grading_problem({'location': self.link_to_location})['html']
# b/c handle_ajax expects serialized data payload and directly calls peer_grading
return self.peer_grading_problem({'location': self.link_to_location.to_deprecated_string()})['html']
def handle_ajax(self, dispatch, data):
"""
......
......@@ -35,14 +35,14 @@ def _reverse_with_slash(url_name, course_key):
@param course_id: The id of the course object (eg course.id).
@returns: The reversed url with a trailing slash.
"""
course_id = course_key.to_deprecated_string()
ajax_url = _reverse_without_slash(url_name, course_id)
ajax_url = _reverse_without_slash(url_name, course_key)
if not ajax_url.endswith('/'):
ajax_url += '/'
return ajax_url
def _reverse_without_slash(url_name, course_id):
def _reverse_without_slash(url_name, course_key):
course_id = course_key.to_deprecated_string()
ajax_url = reverse(url_name, kwargs={'course_id': course_id})
return ajax_url
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment