Enable un-authenticated handler urls
Updates to depend on the latest version of XBlock, which includes support for service-to-service (thirdparty) handler urls, which aren't authenticated with a user (unlike handler requests coming from the xblock client-side javascript). Co-author: Ned Batchelder <ned@edx.org>
This commit is contained in:
@@ -42,7 +42,7 @@ class TestModuleSystem(ModuleSystem): # pylint: disable=abstract-method
|
||||
"""
|
||||
ModuleSystem for testing
|
||||
"""
|
||||
def handler_url(self, block, handler, suffix='', query=''):
|
||||
def handler_url(self, block, handler, suffix='', query='', thirdparty=False):
|
||||
return str(block.scope_ids.usage_id) + '/' + handler + '/' + suffix + '?' + query
|
||||
|
||||
|
||||
|
||||
@@ -403,6 +403,7 @@ class XModule(XModuleMixin, HTMLSnippet, XBlock): # pylint: disable=abstract-me
|
||||
data is a dictionary-like object with the content of the request"""
|
||||
return u""
|
||||
|
||||
@XBlock.handler
|
||||
def xmodule_handler(self, request, suffix=None):
|
||||
"""
|
||||
XBlock handler that wraps `handle_ajax`
|
||||
|
||||
Reference in New Issue
Block a user