From 39dfbc734e0506e8a25f5c66ff570010fb4eaac1 Mon Sep 17 00:00:00 2001 From: BaiJiangJie <32935519+BaiJiangJie@users.noreply.github.com> Date: Mon, 23 Sep 2019 20:36:49 +0800 Subject: [PATCH] =?UTF-8?q?[Bugfix]=20=E4=BF=AE=E5=A4=8D=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E4=B8=AD=E7=82=B9=E5=87=BB=E5=88=A0=E9=99=A4=E6=8C=89=E9=92=AE?= =?UTF-8?q?=E6=97=B6=EF=BC=8C=E6=8F=90=E7=A4=BA=20name=20=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E4=B8=BA=20undefined=20=E7=9A=84=E9=97=AE=E9=A2=98=20?= =?UTF-8?q?(#3259)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * [Bugfix] 修复页面中点击删除按钮时,提示 name 信息为 undefined 的问题 * [Bugfix] 修复页面中点击删除按钮时,提示 name 信息为 undefined 的问题 2 --- apps/assets/templates/assets/cmd_filter_rule_list.html | 2 +- apps/assets/templates/assets/domain_gateway_list.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/assets/templates/assets/cmd_filter_rule_list.html b/apps/assets/templates/assets/cmd_filter_rule_list.html index e2452c391..4bdf5ff2b 100644 --- a/apps/assets/templates/assets/cmd_filter_rule_list.html +++ b/apps/assets/templates/assets/cmd_filter_rule_list.html @@ -103,7 +103,7 @@ $(document).ready(function(){ .on('click', '.btn-delete', function () { var $this = $(this); var $data_table = $('#cmd_filter_rule_list_table').DataTable(); - var name = $(this).closest("tr").find(":nth-child(2)").children('a').html(); + var name = $(this).closest("tr").find(":nth-child(2)").html(); var uid = $this.data('uid'); var the_url = '{% url "api-assets:cmd-filter-rule-detail" filter_pk=object.id pk=DEFAULT_PK %}'.replace('{{ DEFAULT_PK }}', uid); objectDelete($this, name, the_url); diff --git a/apps/assets/templates/assets/domain_gateway_list.html b/apps/assets/templates/assets/domain_gateway_list.html index f7a9c8d60..ade46acc9 100644 --- a/apps/assets/templates/assets/domain_gateway_list.html +++ b/apps/assets/templates/assets/domain_gateway_list.html @@ -118,7 +118,7 @@ $(document).ready(function(){ .on('click', '.btn-delete', function () { var $this = $(this); var $data_table = $('#domain_list_table').DataTable(); - var name = $(this).closest("tr").find(":nth-child(2)").children('a').html(); + var name = $(this).closest("tr").find(":nth-child(2)").html(); var uid = $this.data('uid'); var the_url = '{% url "api-assets:gateway-detail" pk=DEFAULT_PK %}'.replace('{{ DEFAULT_PK }}', uid); objectDelete($this, name, the_url);