Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/PhieF/CarnetElectron.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhie <phie@phie.ovh>2020-11-05 21:21:26 +0300
committerPhie <phie@phie.ovh>2020-11-05 21:21:26 +0300
commit0ff8c8d4d5b4e1ac5858bc9595af86c80a91a18c (patch)
tree006289cb843044b43cd5fd528c3e787435c79de1 /importer
parent6bc3b69823e2d4a7370fa07c3e8b976208d341e3 (diff)
display import end when importing an archive
Diffstat (limited to 'importer')
-rw-r--r--importer/importer.js11
1 files changed, 10 insertions, 1 deletions
diff --git a/importer/importer.js b/importer/importer.js
index 3979dfa..277cbe2 100644
--- a/importer/importer.js
+++ b/importer/importer.js
@@ -131,6 +131,13 @@ Importer.prototype.displayChooseWholeArchiveOrSelectNotes = function () {
}, files, function (error, data) {
console.log("send " + error)
+ $('#import-finished').show();
+ $('#importing-view').hide();
+ if (error)
+ $('#import-report').html($.i18n("import_error"));
+ else
+ $('#import-report').html($.i18n("import_success"));
+
}, function (percentComplete) {
progressBar.classList.remove("mdl-progress__indeterminate")
@@ -138,7 +145,9 @@ Importer.prototype.displayChooseWholeArchiveOrSelectNotes = function () {
$("#archive-or-notes-selection").hide()
console.log("sending " + percentComplete)
$("#importing-view").show();
- document.getElementById("importing").innerHTML = percentComplete + "%"
+ document.getElementById("importing").innerHTML = Math.trunc(percentComplete) + "%<br /> Please wait"
+ if (percentComplete == 100)
+ progressBar.classList.add("mdl-progress__indeterminate")
})
}