From b3f7cd6f45be87d021cf210e905a48a1a3afdc39 Mon Sep 17 00:00:00 2001 From: Chenx221 Date: Thu, 11 Apr 2024 16:28:58 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D"=E6=96=87=E4=BB=B6=E4=BF=9D?= =?UTF-8?q?=E9=99=A9=E7=AE=B1=E5=88=A0=E9=99=A4=E4=BB=85=E5=8F=B3=E4=BE=A7?= =?UTF-8?q?=E6=8C=89=E9=92=AE=E5=8F=AF=E7=94=A8"=E9=97=AE=E9=A2=98=20*?= =?UTF-8?q?=E5=BA=94=E8=AF=A5=E6=98=AF=E4=BB=8E=E6=96=87=E4=BB=B6=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E6=90=AC=E4=BB=A3=E7=A0=81=E5=88=B0=E4=BF=9D=E9=99=A9?= =?UTF-8?q?=E7=AE=B1=E6=97=B6=E5=A4=9A=E5=88=A0=E4=BA=86=E7=82=B9=E4=BB=A3?= =?UTF-8?q?=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- web/js/vault_script.js | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/web/js/vault_script.js b/web/js/vault_script.js index 6fdedd4..a1988de 100644 --- a/web/js/vault_script.js +++ b/web/js/vault_script.js @@ -156,6 +156,25 @@ $(document).on('click', 'tr', function (event) { } updateButtons(); }); +$(document).on('click', '.batch-delete-btn', function () { + var relativePaths = $('.select-item:checked').map(function () { + return $(this).data('relativePath'); + }).get(); + $.ajax({ + type: "POST", + url: "index.php?r=vault%2Fdelete", + data: {relativePath: relativePaths}, + success: function () { + // 处理响应 + location.reload(); + }, + error: function () { + // 处理错误 + console.error('AJAX request failed.'); + location.reload(); + } + }); +}); function updateButtons() { var checkboxes = $('.select-item:checked');