diff --git a/LTEMvcApp/Views/Home/Index.cshtml b/LTEMvcApp/Views/Home/Index.cshtml index cb344a1..a3ceb17 100644 --- a/LTEMvcApp/Views/Home/Index.cshtml +++ b/LTEMvcApp/Views/Home/Index.cshtml @@ -143,7 +143,7 @@ } else { - 已停止 + 已停止 } @@ -183,6 +183,9 @@ 配置 + + 删除 + } @@ -219,5 +222,20 @@ alert('停止失败:' + xhr.responseText); }); } + + function deleteTestClient(address) { + if (!confirm('确定要删除该测试客户端吗?')) return; + $.ajax({ + url: '/api/testconfig/address/' + encodeURIComponent(address), + type: 'DELETE', + success: function() { + alert('删除成功!'); + setTimeout(() => location.reload(), 1000); + }, + error: function(xhr) { + alert('删除失败:' + xhr.responseText); + } + }); + } }