diff --git a/Site/App_GlobalResources/Pages.Ledgers.designer.cs b/Site/App_GlobalResources/Pages.Ledgers.designer.cs
index c4d2c78b..7740f247 100644
--- a/Site/App_GlobalResources/Pages.Ledgers.designer.cs
+++ b/Site/App_GlobalResources/Pages.Ledgers.designer.cs
@@ -1132,6 +1132,24 @@ namespace Resources.Pages {
}
}
+ ///
+ /// Looks up a localized string similar to The transaction file could not be processed. Is it the right file? For the right bank? Please try again.<br/><br/>If the error persists, try getting a fresh transaction file..
+ ///
+ internal static string EndOfMonth_Error_Body_BankTransactionFileFormat {
+ get {
+ return ResourceManager.GetString("EndOfMonth_Error_Body_BankTransactionFileFormat", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to FILE COULD NOT BE IMPORTED.
+ ///
+ internal static string EndOfMonth_Error_Header_BankTransactionFile {
+ get {
+ return ResourceManager.GetString("EndOfMonth_Error_Header_BankTransactionFile", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Autofetch Transaction Data for {0}.
///
@@ -1276,6 +1294,15 @@ namespace Resources.Pages {
}
}
+ ///
+ /// Looks up a localized string similar to PROBLEM WITH TRANSACTION FILE.
+ ///
+ internal static string EndOfMonth_Warning_Header_BankTransactionFile {
+ get {
+ return ResourceManager.GetString("EndOfMonth_Warning_Header_BankTransactionFile", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to Account name.
///
diff --git a/Site/App_GlobalResources/Pages.Ledgers.resx b/Site/App_GlobalResources/Pages.Ledgers.resx
index 8f94bca8..ac9ac482 100644
--- a/Site/App_GlobalResources/Pages.Ledgers.resx
+++ b/Site/App_GlobalResources/Pages.Ledgers.resx
@@ -1075,4 +1075,13 @@ This can happen after bitcoin splits ("forks") or similar even
Inspect Bitcoin Cash Hotwallet For
This is followed by a year and month dropdown
+
+ The transaction file could not be processed. Is it the right file? For the right bank? Please try again.<br/><br/>If the error persists, try getting a fresh transaction file.
+
+
+ FILE COULD NOT BE IMPORTED
+
+
+ PROBLEM WITH TRANSACTION FILE
+
\ No newline at end of file
diff --git a/Site/Pages/v5/Ledgers/EndOfMonth.aspx b/Site/Pages/v5/Ledgers/EndOfMonth.aspx
index 47bec28c..7fbd7292 100644
--- a/Site/Pages/v5/Ledgers/EndOfMonth.aspx
+++ b/Site/Pages/v5/Ledgers/EndOfMonth.aspx
@@ -267,6 +267,7 @@
}
activeUpload = triggeredUpload;
triggeredUpload = null;
+ activeUploadId = null; // Supplied from server side on delayed processing
// switch action icon upload to status icon waiting
$('img.action-icon[data-item="' + activeUpload + '"]').hide();
@@ -294,10 +295,11 @@
if (itemType == "BankTransactionData") {
// Show a pretty dialog telling the user that things went to unpretty shit
- alertify.alert("THIS FILE CANNOT BE PROCESSED
There was an error trying to read the file. Is it really a file of the right type, for the right bank?
Please try again. If the error persists, try getting a fresh transaction file."); // TODO: Localize
+ alertify.alert("" + localized_errorHeader_transactionFile + "
" + localized_errorBody_transactionFileFormat);
}
activeUpload = null;
+ activeUploadId = null;
}
function clientFinishedUpload() {
@@ -317,10 +319,24 @@
function(result) {
if (result.Success) {
- markItemCompleted(activeUpload);
+ if (result.StillProcessing) {
- activeUpload = null;
+ activeUploadId = result.Identity;
+ // CONTINUE HERE
+
+ // Fade out original text, create a progress bar and the word "Processing"
+
+ // Add a processing message updater, check against identity (see Swarmops5.JS)
+
+ // Create a regular callback for progress in case websocket messages fail
+
+ } else {
+ // If we're not still processing, we're done
+
+ markItemCompleted(activeUpload);
+ activeUpload = null;
+ }
} else {
if (result.DisplayMessage != "ERROR_FILEDATAFORMAT") {
alert(result.DisplayMessage); // temporary debug function
@@ -339,11 +355,14 @@
var triggeredUpload = null;
var activeUpload = null;
+ var activeUploadId = null;
var localized_skipNoResponse = SwarmopsJS.unescape('<%=this.Localized_SkipNo%>');
var localized_skipYesResponse = SwarmopsJS.unescape('<%=this.Localized_SkipYes%>');
var localized_skipPromptBankStatement = SwarmopsJS.unescape('<%=this.Localized_SkipPrompt_BankStatement%>');
var localized_skipPromptGeneric = SwarmopsJS.unescape('<%=this.Localized_SkipPrompt_Generic%>');
+ var localized_errorHeader_transactionFile = SwarmopsJS.unescape('<%=this.Localized_Error_Header_TransactionFile%>');
+ var localized_errorBody_transactionFileFormat = SwarmopsJS.unescape('<%=this.Localized_Error_Body_TransactionFileFormat%>');
var uploadGuid = '<%=this.UploadControl.GuidString%>';
diff --git a/Site/Pages/v5/Ledgers/EndOfMonth.aspx.cs b/Site/Pages/v5/Ledgers/EndOfMonth.aspx.cs
index 07aca3c0..aab2caf2 100644
--- a/Site/Pages/v5/Ledgers/EndOfMonth.aspx.cs
+++ b/Site/Pages/v5/Ledgers/EndOfMonth.aspx.cs
@@ -525,5 +525,15 @@ namespace Swarmops.Frontend.Pages.Ledgers
{
get { return CommonV5.JavascriptEscape(Resources.Global.Global_SkipNo); }
}
+
+ public string Localized_Error_Header_BankTransactionFile
+ {
+ get { return CommonV5.JavascriptEscape(Resources.Pages.Ledgers.EndOfMonth_Error_Header_BankTransactionFile); }
+ }
+
+ public string Localized_Error_Body_BankTransactionFileFormat
+ {
+ get { return CommonV5.JavascriptEscape(Resources.Pages.Ledgers.EndOfMonth_Error_Body_BankTransactionFileFormat); }
+ }
}
}
\ No newline at end of file