Commit 4f308f23 by Tim Krones

Make sure not to override global beforeSend handler.

parent 834b9a3a
...@@ -4,6 +4,12 @@ function InstructorToolBlock(runtime, element) { ...@@ -4,6 +4,12 @@ function InstructorToolBlock(runtime, element) {
// Pagination // Pagination
$(document).ajaxSend(function(event, jqxhr, options) {
if (options.url.indexOf('get_result_page') !== -1) {
options.data = JSON.stringify(options.data);
}
});
var Result = Backbone.Model.extend({ var Result = Backbone.Model.extend({
initialize: function(attrs, options) { initialize: function(attrs, options) {
...@@ -41,10 +47,7 @@ function InstructorToolBlock(runtime, element) { ...@@ -41,10 +47,7 @@ function InstructorToolBlock(runtime, element) {
reset: true, reset: true,
type: 'POST', type: 'POST',
contentType: 'application/json', contentType: 'application/json',
processData: false, processData: false
beforeSend: function(jqXHR, options) {
options.data = JSON.stringify(options.data);
}
}, },
getFirstPage: function() { getFirstPage: function() {
......
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