From 0ff4dc822b62bdc4abc925a2d1a6b8641defa98a Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Thu, 26 Mar 2020 19:14:47 +0100 Subject: luci-app-firewall: use Firewall.removeZone() helper Fixes: FS#2932 Ref: https://bugs.openwrt.org/index.php?do=details&task_id=2932 Signed-off-by: Jo-Philipp Wich --- .../htdocs/luci-static/resources/view/firewall/zones.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'applications/luci-app-firewall/htdocs/luci-static') diff --git a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js index fe9ef75c5a..85c126d7ae 100644 --- a/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js +++ b/applications/luci-app-firewall/htdocs/luci-static/resources/view/firewall/zones.js @@ -82,6 +82,12 @@ return L.view.extend({ s.anonymous = true; s.sortable = true; + s.handleRemove = function(section_id, ev) { + return firewall.deleteZone(section_id).then(L.bind(function() { + return this.super('handleRemove', [section_id, ev]); + }, this)); + }; + s.tab('general', _('General Settings')); s.tab('advanced', _('Advanced Settings')); s.tab('conntrack', _('Conntrack Settings')); -- cgit v1.2.3