diff options
author | Steven Barth <steven@midlink.org> | 2008-08-13 23:14:19 +0000 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2008-08-13 23:14:19 +0000 |
commit | 662f70a467a3bc62bbe3d38c732d4b5a85165a8d (patch) | |
tree | 6f3c1802f682ece3a0dc94893125a64b6f6b586a /modules | |
parent | 58f183a28269ded9f41eb980b63a607421689f63 (diff) |
modules/admin-full: Added Firewall-Zone column to network interface overview
Diffstat (limited to 'modules')
-rw-r--r-- | modules/admin-full/luasrc/model/cbi/admin_network/network.lua | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/modules/admin-full/luasrc/model/cbi/admin_network/network.lua b/modules/admin-full/luasrc/model/cbi/admin_network/network.lua index 0fffd32b61..228efc42d9 100644 --- a/modules/admin-full/luasrc/model/cbi/admin_network/network.lua +++ b/modules/admin-full/luasrc/model/cbi/admin_network/network.lua @@ -53,6 +53,15 @@ end ifname = s:option(DummyValue, "ifname", translate("device")) ifname.stateful = true +if luci.model.uci.load("firewall") then + zone = s:option(DummyValue, "_zone", translate("zone")) + + function zone.cfgvalue(self, section) + local zones = luci.tools.webadmin.network_get_zones(section) + return zones and table.concat(zones, ", ") or "-" + end +end + hwaddr = s:option(DummyValue, "_hwaddr") function hwaddr.cfgvalue(self, section) local ix = self.map:stateget(section, "ifname") or "" |