+ local call
+ if value == "1" then
+ call = "ifup"
+ elseif value == "0" then
+ call = "ifdown"
+ end
+ os.execute(call .. " " .. section .. " >/dev/null 2>&1")
+end
+
+ifname = s:option(DummyValue, "ifname", translate("Device"))
+function ifname.cfgvalue(self, section)
+ return netstate[section] and netstate[section].ifname
+end
+
+ifname.titleref = luci.dispatcher.build_url("admin", "network", "vlan")
+
+
+if luci.model.uci.cursor():load("firewall") then
+ zone = s:option(DummyValue, "_zone", translate("Zone"))
+ zone.titleref = luci.dispatcher.build_url("admin", "network", "firewall", "zones")
+
+ function zone.cfgvalue(self, section)
+ return table.concat(wa.network_get_zones(section) or { "-" }, ", ")
+ end