文件列表只显示文件名;app.js 加版本参数防移动端旧缓存(.bin 问题疑为旧 JS 未更新)
This commit is contained in:
@@ -110,6 +110,7 @@
|
||||
|
||||
<div class="toast hidden" id="toast"></div>
|
||||
|
||||
<script src="/js/app.js"></script>
|
||||
<!-- 发版时更新 v 参数,避免移动端浏览器缓存旧 JS -->
|
||||
<script src="/js/app.js?v=20260831b"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
@@ -394,7 +394,7 @@ async function loadFiles() {
|
||||
return;
|
||||
}
|
||||
el.innerHTML = files.map(f => {
|
||||
return '<div class="file-row"><span class="file-name">' + esc(f.filename) + '</span>' +
|
||||
return '<div class="file-row"><span class="file-name">' + esc(f.filename.split('/').pop() || f.filename) + '</span>' +
|
||||
'<span class="file-size">' + fmtSize(f.size) + '</span>' +
|
||||
'<button class="file-act" onclick="ui.downloadFile(\'' + esc(f.filename) + '\')">下载</button>' +
|
||||
'<button class="file-act del" onclick="ui.deleteFile(\'' + esc(f.filename).replace(/'/g, '%27') + '\')">删</button></div>';
|
||||
|
||||
Reference in New Issue
Block a user