diff options
author | Peter Grassberger <petertheone@gmail.com> | 2016-06-27 22:42:51 (GMT) |
---|---|---|
committer | Peter Grassberger <petertheone@gmail.com> | 2016-06-27 22:42:51 (GMT) |
commit | bd6186e7233de72b85c0566d12273ede449453b5 (patch) | |
tree | 9441db6bc0b2ae1edb575f371e2f73bbeceb333b /www/js/utils.js | |
parent | 3cc9bda4fbc189cc931b9cfa2163c3ff212ce1fa (diff) |
drop dropzone, add websocket uploads
Diffstat (limited to 'www/js/utils.js')
-rw-r--r-- | www/js/utils.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/www/js/utils.js b/www/js/utils.js index a2a28b2..8337c12 100644 --- a/www/js/utils.js +++ b/www/js/utils.js @@ -147,7 +147,9 @@ jQuery.fn.sort = function() { function updateProgressBar($el, upload) { if(upload.uploadprogress.progress_step < 2) { - $el.find('.file-bytes').text(Number(upload.uploadprogress.progress).toFixed(2) + '%'); + var bytes_str = Number((upload.uploadprogress.current/1024)/1024).toFixed(1) + " von " + + Number((upload.uploadprogress.total/1024)/1024).toFixed(1) + " MB"; + $el.find('.file-bytes').text(bytes_str); $el.find('.progress .progress-bar').css("width", upload.uploadprogress.progress + "%"); } else { $el.find('.file-bytes').text('importiere...'); |