From d7451841d7a70ef14c6ed8e4074007453e173360 Mon Sep 17 00:00:00 2001 From: Rick Falkvinge Date: Wed, 25 Apr 2018 16:08:00 +0200 Subject: [PATCH] Debug testing --- Site/Pages/v5/Ledgers/UploadBankFiles.aspx | 28 ++++++++++++---------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/Site/Pages/v5/Ledgers/UploadBankFiles.aspx b/Site/Pages/v5/Ledgers/UploadBankFiles.aspx index a5d6ea31..8c50f410 100644 --- a/Site/Pages/v5/Ledgers/UploadBankFiles.aspx +++ b/Site/Pages/v5/Ledgers/UploadBankFiles.aspx @@ -23,8 +23,7 @@ }); - function onAccountChange(newAccountId) { - alert(newAccountId); + function onAccountChange(oldAccountId, newAccountId) { if (newAccountId != 0) { $('#<%=this.UploadFile.ClientID %>_ButtonUploadVisible').fadeIn(); @@ -50,16 +49,21 @@ $('#DivProcessingFake').slideUp(); // in case second, third... file halfway = false; - $.ajax({ - type: "POST", - url: "/Pages/v5/Ledgers/UploadBankFiles.aspx/InitializeProcessing", - data: "{'guid': '<%= this.UploadFile.GuidString %>', 'accountIdString':'" + $('#<%= this.DropAccounts.ClientID %>').val() + "'}", - contentType: "application/json; charset=utf-8", - dataType: "json", - success: function (msg) { - setTimeout('updateProgressProcessing();', 1000); - } - }); + var selectedAccountId = <%=this.DropAccounts.ClientID%>_val(); + + alert(selectedAccountId); + return; // debug code + + SwarmopsJS.ajaxCall ( + "/Pages/v5/Ledgers/UploadBankFiles.aspx/InitializeProcessing", + { guid: guid, accountId: selectedAccountId }, + function (result) { + if (result.Success) + { + setTimeout('updateProgressProcessing();', 1000); + } + } + ); } function updateProgressProcessing() {