Upload templates/batch.html with huggingface_hub
Browse files- templates/batch.html +3 -3
templates/batch.html
CHANGED
|
@@ -160,10 +160,10 @@ function submitBatch() {
|
|
| 160 |
btn.textContent = '全部上傳';
|
| 161 |
let html = '<table class="table table-sm table-bordered"><thead><tr><th>檔名</th><th>結果</th></tr></thead><tbody>';
|
| 162 |
(d.results || []).forEach(r => {
|
| 163 |
-
let cls = 'status-ok', msg = '成功';
|
| 164 |
-
if (r.status === 'error') { cls = 'status-err'; msg = '失敗
|
| 165 |
else if (r.status === 'duplicate') { cls = 'status-dup'; msg = '重複,已複寫'; }
|
| 166 |
-
else if (r.status === 'skipped') { cls = 'status-dup'; msg = '
|
| 167 |
html += `<tr><td class="small">${r.file}</td><td class="${cls}">${msg}</td></tr>`;
|
| 168 |
});
|
| 169 |
html += '</tbody></table>';
|
|
|
|
| 160 |
btn.textContent = '全部上傳';
|
| 161 |
let html = '<table class="table table-sm table-bordered"><thead><tr><th>檔名</th><th>結果</th></tr></thead><tbody>';
|
| 162 |
(d.results || []).forEach(r => {
|
| 163 |
+
let cls = 'status-ok', msg = '成功新增';
|
| 164 |
+
if (r.status === 'error') { cls = 'status-err'; msg = r.msg || '失敗'; }
|
| 165 |
else if (r.status === 'duplicate') { cls = 'status-dup'; msg = '重複,已複寫'; }
|
| 166 |
+
else if (r.status === 'skipped') { cls = 'status-dup'; msg = '重複,跳過不新增'; }
|
| 167 |
html += `<tr><td class="small">${r.file}</td><td class="${cls}">${msg}</td></tr>`;
|
| 168 |
});
|
| 169 |
html += '</tbody></table>';
|