(filePath, oldName)
| 365 | _("uploadSpiffs").style.display = 'none'; |
| 366 | } |
| 367 | function renameFile(filePath, oldName) { |
| 368 | const actualFolder = _("actualFolder").value; |
| 369 | const fileName = prompt("Enter the new name: ", oldName); |
| 370 | if (isNullOrEmpty(fileName)) { |
| 371 | window.alert("Invalid Name"); |
| 372 | } else { |
| 373 | const formdata5 = new FormData(); |
| 374 | formdata5.append("filePath", filePath); |
| 375 | formdata5.append("fileName", fileName); |
| 376 | const xhr = httpRequest("POST", "/rename", { async: false, body: formdata5 }); |
| 377 | _("status").innerHTML = xhr.responseText; |
| 378 | listFilesButton(actualFolder); |
| 379 | } |
| 380 | } |
| 381 | function downloadDeleteButton(filename, action) { |
| 382 | const urltocall = "/file?name=" + filename + "&action=" + action; |
| 383 | const actualFolder = _("actualFolder").value; |
nothing calls this directly
no test coverage detected