From fd419379e57e448eba2aa743cbe21b9375da2594 Mon Sep 17 00:00:00 2001 From: Rick Falkvinge Date: Wed, 7 Jul 2021 16:11:16 +0200 Subject: [PATCH] Some more debugging code --- Site/Controls/v5/Base/DateTextBox.ascx | 4 ++++ Site/Scripts/Swarmops-v5.js | 8 ++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Site/Controls/v5/Base/DateTextBox.ascx b/Site/Controls/v5/Base/DateTextBox.ascx index fe1211ca..4de13277 100644 --- a/Site/Controls/v5/Base/DateTextBox.ascx +++ b/Site/Controls/v5/Base/DateTextBox.ascx @@ -49,6 +49,10 @@ $('#<%=this.ClientID%>_InterpretedDate').val(''); $('#<%=this.TextInput.ClientID%>').focus(); } + }, + function(data) { + console.log('ERROR'); + console.log(data); }); }); diff --git a/Site/Scripts/Swarmops-v5.js b/Site/Scripts/Swarmops-v5.js index d7001598..4bee3d6a 100644 --- a/Site/Scripts/Swarmops-v5.js +++ b/Site/Scripts/Swarmops-v5.js @@ -431,8 +431,9 @@ var SwarmopsJS = (function () { } - publicSymbols.ajaxCall = ajaxCall; function ajaxCall(url, params, successFunction, errorFunction) { + console.log("making Ajax call"); + console.log(params); $.ajax({ type: "POST", url: url, @@ -440,9 +441,11 @@ var SwarmopsJS = (function () { contentType: "application/json; charset=utf-8", dataType: "json", success: function (msg) { + console.log(msg); successFunction(msg.d); }, - error: function () { + error: function (data) { + console.log(data); if (errorFunction !== undefined) { errorFunction(); } else { @@ -451,6 +454,7 @@ var SwarmopsJS = (function () { } }); } + publicSymbols.ajaxCall = ajaxCall; // Preserves the "this" object into success and error functions