From 9b5046259fcb9cfb928ae042fd2d5932ec762263 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Fri, 20 Nov 2015 23:44:43 +0100 Subject: luci-mod-admin-full: make mirror port settings depend on mirror enable Signed-off-by: Jo-Philipp Wich --- modules/luci-mod-admin-full/luasrc/model/cbi/admin_network/vlan.lua | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'modules/luci-mod-admin-full/luasrc/model') diff --git a/modules/luci-mod-admin-full/luasrc/model/cbi/admin_network/vlan.lua b/modules/luci-mod-admin-full/luasrc/model/cbi/admin_network/vlan.lua index 40f8014f1a..ce3c3ef325 100644 --- a/modules/luci-mod-admin-full/luasrc/model/cbi/admin_network/vlan.lua +++ b/modules/luci-mod-admin-full/luasrc/model/cbi/admin_network/vlan.lua @@ -107,6 +107,12 @@ m.uci:foreach("network", "switch", local sp = s:option(ListValue, "mirror_source_port", translate("Mirror source port")) local mp = s:option(ListValue, "mirror_monitor_port", translate("Mirror monitor port")) + sp:depends("enable_mirror_tx", "1") + sp:depends("enable_mirror_rx", "1") + + mp:depends("enable_mirror_tx", "1") + mp:depends("enable_mirror_rx", "1") + local pt for pt = 0, num_ports - 1 do local name -- cgit v1.2.3