commit d25a3c02fe831199a3a6ce8c6e135b372def6421 parent 98f6be85f2106ef42ad55fcac106609bf5a334d0 Author: MTRNord <info@nordgedanken.de> Date: Tue, 1 Dec 2015 00:31:14 +0100 add config-mode Views Diffstat:
5 files changed, 35 insertions(+), 0 deletions(-)
diff --git a/fastd_network_connect/src/config-mode/controller/admin/fastd_network_connect.lua b/fastd_network_connect/src/config-mode/controller/admin/fastd_network_connect.lua @@ -0,0 +1,3 @@ +function index() + entry({"admin", "fastd_network_connect"}, cbi("admin/fastd_network_connect"), _("Fastd Connection of 2 Networks"), 10) +end diff --git a/fastd_network_connect/src/config-mode/i18n/de.po b/fastd_network_connect/src/config-mode/i18n/de.po diff --git a/fastd_network_connect/src/config-mode/i18n/en.po b/fastd_network_connect/src/config-mode/i18n/en.po diff --git a/fastd_network_connect/src/config-mode/i18n/fastd_network_connect.pot b/fastd_network_connect/src/config-mode/i18n/fastd_network_connect.pot diff --git a/fastd_network_connect/src/config-mode/model/cbi/admin/fastd_network_connect.lua b/fastd_network_connect/src/config-mode/model/cbi/admin/fastd_network_connect.lua @@ -0,0 +1,32 @@ +local f, s, o, ssid +local uci = luci.model.uci.cursor() +local config = 'wireless' + +f = SimpleForm("wifi", translate("Private WLAN")) +f.template = "admin/expertmode" + +s = f:section(SimpleSection, nil, translate( + 'Your node can additionally extend your private network by bridging the WAN interface ' + .. 'with a separate WLAN. This feature is completely independent of the mesh functionality. ' + .. 'Please note that the private WLAN and meshing on the WAN interface should not be enabled ' + .. 'at the same time.' +)) + +o = s:option(Flag, "enabled", translate("Enabled")) +o.default = (ssid and not uci:get_bool(config, primary_iface, "disabled")) and o.enabled or o.disabled +o.rmempty = false + +o = s:option(Value, "ssid", translate("Name (SSID)")) +o:depends("enabled", '1') +o.default = ssid + +o = s:option(Value, "key", translate("Key"), translate("8-63 characters")) +o:depends("enabled", '1') +o.datatype = "wpakey" +o.default = uci:get(config, primary_iface, "key") + +function f.handle(self, state, data) + +end + +return f