From e630b32498767164004e965f34471d70d6e6f51c Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Tue, 24 Sep 2019 08:05:11 +0200 Subject: [PATCH] luci-mod-network: interfaces.js: map remove action to network.deleteNetwork() Signed-off-by: Jo-Philipp Wich --- .../htdocs/luci-static/resources/view/network/interfaces.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js index 624718dd8..b49d36d46 100644 --- a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js +++ b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js @@ -740,6 +740,12 @@ return L.view.extend({ }, this)); }; + s.handleRemove = function(section_id, ev) { + return network.deleteNetwork(section_id).then(L.bind(function(section_id, ev) { + return form.GridSection.prototype.handleRemove.apply(this, [section_id, ev]); + }, this, section_id, ev)); + }; + o = s.option(form.DummyValue, '_ifacebox'); o.modalonly = false; o.textvalue = function(section_id) { -- 2.25.1