@login_required
@ensure_csrf_cookie
@require_http_methods(['GET'])
def course_rerun_handler(request, course_key_string):
 if (not GlobalStaff().has_user(request.user)):
  raise PermissionDenied()
 course_key = CourseKey.from_string(course_key_string)
 with modulestore().bulk_operations(course_key):
  course_module = get_course_and_check_access(course_key, request.user, depth=3)
  if (request.method == 'GET'):
   return render_to_response('course-create-rerun.html', {'source_course_key': course_key, 'display_name': course_module.display_name, 'user': request.user, 'course_creator_status': _get_course_creator_status(request.user), 'allow_unicode_course_id': settings.FEATURES.get('ALLOW_UNICODE_COURSE_ID', False)})

@ login_required @ ensure_csrf_cookie @ require_http_methods ( [ 'GET' ] ) def course_rerun_handler ( request , course_key_string ) : if ( not GlobalStaff ( ) . has_user ( request . user ) ) : raise PermissionDenied ( ) course_key = CourseKey . from_string ( course_key_string ) with modulestore ( ) . bulk_operations ( course_key ) : course_module = get_course_and_check_access ( course_key , request . user , depth = 3 ) if ( request . method == 'GET' ) : return render_to_response ( 'course-create-rerun.html' , { 'source_course_key' : course_key , 'display_name' : course_module . display_name , 'user' : request . user , 'course_creator_status' : _get_course_creator_status ( request . user ) , 'allow_unicode_course_id' : settings . FEATURES . get ( 'ALLOW_UNICODE_COURSE_ID' , False ) } )
the restful handler for course reruns .