diff options
author | Steven Barth <steven@midlink.org> | 2008-08-14 14:51:06 +0000 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2008-08-14 14:51:06 +0000 |
commit | 2c09564d762b692d970a531cca58eb52ba3807e7 (patch) | |
tree | 4d14c0d86e3cad8a6fcb9e5a39c104a0e80646e4 /modules | |
parent | 8c246e81746fac0fc0ff07266058d4ace5acdd55 (diff) |
modules/admin-core: Added several cross-references to relevant configuration pages
Diffstat (limited to 'modules')
4 files changed, 8 insertions, 7 deletions
diff --git a/modules/admin-core/luasrc/tools/webadmin.lua b/modules/admin-core/luasrc/tools/webadmin.lua index ac11845d4d..d6d952117e 100644 --- a/modules/admin-core/luasrc/tools/webadmin.lua +++ b/modules/admin-core/luasrc/tools/webadmin.lua @@ -76,6 +76,7 @@ function cbi_add_networks(field) end end ) + field.titleref = luci.dispatcher.build_url("admin", "network", "network") end function cbi_add_knownips(field) diff --git a/modules/admin-full/luasrc/model/cbi/admin_network/dhcp.lua b/modules/admin-full/luasrc/model/cbi/admin_network/dhcp.lua index 1c9ae396ae..f2f2e4742a 100644 --- a/modules/admin-full/luasrc/model/cbi/admin_network/dhcp.lua +++ b/modules/admin-full/luasrc/model/cbi/admin_network/dhcp.lua @@ -11,6 +11,7 @@ You may obtain a copy of the License at $Id$ ]]-- +require("luci.tools.webadmin") require("luci.model.uci") require("luci.sys") require("luci.util") @@ -22,11 +23,12 @@ s.addremove = true s.anonymous = true iface = s:option(ListValue, "interface", translate("interface")) +luci.tools.webadmin.cbi_add_networks(iface) + luci.model.uci.foreach("network", "interface", function (section) if section[".name"] ~= "loopback" then iface.default = iface.default or section[".name"] - iface:value(section[".name"]) s:depends("interface", section[".name"]) end end) 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 228efc42d9..d2ccb9b95e 100644 --- a/modules/admin-full/luasrc/model/cbi/admin_network/network.lua +++ b/modules/admin-full/luasrc/model/cbi/admin_network/network.lua @@ -52,9 +52,11 @@ end ifname = s:option(DummyValue, "ifname", translate("device")) ifname.stateful = true +ifname.titleref = luci.dispatcher.build_url("admin", "network", "vlan") if luci.model.uci.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) local zones = luci.tools.webadmin.network_get_zones(section) diff --git a/modules/admin-full/luasrc/model/cbi/admin_wifi/networks.lua b/modules/admin-full/luasrc/model/cbi/admin_wifi/networks.lua index 4b2179a8f4..0c62b58e96 100644 --- a/modules/admin-full/luasrc/model/cbi/admin_wifi/networks.lua +++ b/modules/admin-full/luasrc/model/cbi/admin_wifi/networks.lua @@ -11,6 +11,7 @@ You may obtain a copy of the License at $Id$ ]]-- +require("luci.tools.webadmin") m = Map("wireless", translate("networks"), translate("a_w_networks1")) s = m:section(TypedSection, "wifi-iface", "") @@ -27,12 +28,7 @@ luci.model.uci.foreach("wireless", "wifi-device", network = s:option(ListValue, "network", translate("network"), translate("a_w_network1")) network:value("") -luci.model.uci.foreach("network", "interface", - function (section) - if section[".name"] ~= "loopback" then - network:value(section[".name"]) - end - end) +luci.tools.webadmin.cbi_add_networks(network) mode = s:option(ListValue, "mode", translate("mode")) mode:value("ap", translate("a_w_ap")) |