Update filesize even if filelist is empty
Cette révision appartient à :
Parent
b05f3b8171
révision
eb297454c1
1 fichiers modifiés avec 2 ajouts et 1 suppressions
|
@ -368,11 +368,12 @@ Modal.Init({
|
|||
FileListLabel.addEventListener("click", function (e) {
|
||||
FileListContainer.innerHTML = "<tr class='tr-filelist'><td>{{T("loading_file_list")}}</td></tr>"
|
||||
Query.Get('/stats/{{Torrent.ID}}?files', function (data) {
|
||||
|
||||
if(data.totalsize != null && data.totalsize != "0.0 B") document.getElementsByClassName("torrent-info-size")[0].innerHTML = data.totalsize
|
||||
if(data.filelist != null) {
|
||||
FileListContainer.innerHTML = ""
|
||||
FileListLabel.style.opacity = 1
|
||||
document.getElementById("filelist").style.opacity = 1
|
||||
if(data.totalsize != "0.0 B") document.getElementsByClassName("torrent-info-size")[0].innerHTML = data.totalsize
|
||||
|
||||
for(var i = 0; i < data.filelist.length; i++) {
|
||||
var file = data.filelist[i]
|
||||
|
|
Référencer dans un nouveau ticket