From: Florian Eckert Date: Thu, 8 Feb 2018 12:07:24 +0000 (+0100) Subject: luci-app-firewall: only show portforward template if there are more then one zone X-Git-Url: http://git.archive.openwrt.org/?p=project%2Fluci.git;a=commitdiff_plain;h=846fb1f8bc7e779d22d399fa4ac4cb9f73964007 luci-app-firewall: only show portforward template if there are more then one zone Only show portforward template if there are more then one zone. Signed-off-by: Florian Eckert --- diff --git a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm index 58121c420..e1fef02d9 100644 --- a/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm +++ b/applications/luci-app-firewall/luasrc/view/firewall/cbi_addrule.htm @@ -2,6 +2,7 @@ local fw = require "luci.model.firewall".init() local wz = fw:get_zone("wan") local lz = fw:get_zone("lan") + local zones = fw:get_zones() %>
@@ -38,7 +39,7 @@ <% end %> - <% if wz and lz then %> + <% if #zones > 1 then %>

<%:New forward rule%>: