Beispiel #1
0
 def get(self, request, course_id):
     """
     Implements the GET method as described in the class docstring.
     """
     course_key = CourseKey.from_string(course_id)
     topic_ids = self.request.GET.get('topic_id')
     with modulestore().bulk_operations(course_key):
         response = get_course_topics(
             request,
             course_key,
             set(topic_ids.strip(',').split(',')) if topic_ids else None,
         )
     return Response(response)
Beispiel #2
0
 def get(self, request, course_id):
     """
     Implements the GET method as described in the class docstring.
     """
     course_key = CourseKey.from_string(course_id)
     topic_ids = self.request.GET.get('topic_id')
     with modulestore().bulk_operations(course_key):
         response = get_course_topics(
             request,
             course_key,
             set(topic_ids.strip(',').split(',')) if topic_ids else None,
         )
     return Response(response)