diff --git a/express-server/public/ocrscan/ocrscan.js b/express-server/public/ocrscan/ocrscan.js index e6bed8f8..38c793b7 100644 --- a/express-server/public/ocrscan/ocrscan.js +++ b/express-server/public/ocrscan/ocrscan.js @@ -7,6 +7,7 @@ $(document).ready(function() { $('.modal').modal({ dismissible: false }); + $('.materialboxed').materialbox(); $('.fixed-action-btn').floatingActionButton(); @@ -23,6 +24,7 @@ $(document).ready(function() { $("#modal1").modal("open"); + $(".btn-analyze").click(function() { analyzeUploaded(); }); @@ -55,7 +57,7 @@ function movePurchases(text) { }, success(result){ console.log(result); - alert("Done"); + window.location.href = "/dash/" + idtoken }, error(err){ console.error("Error: " + err); @@ -76,6 +78,9 @@ $(document).on("click", ".btndash", function() { }); function analyzeUploaded() { + + $("#modalEND").modal("open"); + var img = document.getElementById("blah"); Tesseract.recognize(img).progress((progress) => { diff --git a/express-server/public/ocrscan/style.css b/express-server/public/ocrscan/style.css index 1e97f8e9..1fd77b35 100644 --- a/express-server/public/ocrscan/style.css +++ b/express-server/public/ocrscan/style.css @@ -71,4 +71,12 @@ html, body { .btn-choose { width: 100%; +} + +.progress .indeterminate { + background-color: #f4511e; +} + +.progress { + background-color: #f8cfc3; } \ No newline at end of file diff --git a/express-server/views/ocrscan.ejs b/express-server/views/ocrscan.ejs index e16c29dd..da936f68 100644 --- a/express-server/views/ocrscan.ejs +++ b/express-server/views/ocrscan.ejs @@ -55,7 +55,7 @@