From 2c60e46ad83a1792c94a04073036ab7fed449702 Mon Sep 17 00:00:00 2001 From: Terry Geng Date: Tue, 19 May 2020 21:35:19 +0800 Subject: [PATCH] fix: player display bug --- static/js/custom.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/static/js/custom.js b/static/js/custom.js index c619cb7..2b71583 100644 --- a/static/js/custom.js +++ b/static/js/custom.js @@ -156,7 +156,7 @@ function displayPlaylist(data) { } displayActiveItem(data.current_index); - updatePlayerInfo(items[data.current_index]); + updatePlayerInfo(items[data.current_index - data.start_from]); bindPlaylistEvent(); playlist_table.animate({ opacity: 1 }, 200); }); @@ -925,7 +925,7 @@ function uploadNextFile(){ req.upload.addEventListener("progress", function(e){ if (e.lengthComputable) { let percent = e.loaded / e.total; - setProgressBar(file_progress_item.progress, percent, Math.floor(percent) + "%"); + setProgressBar(file_progress_item.progress, percent, Math.floor(percent*100) + "%"); } });