diff options
author | Florian Eckert <fe@dev.tdt.de> | 2018-11-21 13:15:29 +0100 |
---|---|---|
committer | Florian Eckert <fe@dev.tdt.de> | 2018-11-22 08:18:17 +0100 |
commit | 1986dc2751517f11da943863a8cca6b3fe50be3b (patch) | |
tree | b42e2551c960067f205a62dfdda30a3460343eca | |
parent | 9881ad5a6b558dbff21703724b29d34c96d1d327 (diff) |
luci-app-openvpn: On apply/save redirect to OpenVPN overview page
This change will redirect on apply/save to the OpenVPN overview page.
This is the default behaviour on LuCI.
Signed-off-by: Florian Eckert <fe@dev.tdt.de>
-rw-r--r-- | applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua | 4 | ||||
-rw-r--r-- | applications/luci-app-openvpn/luasrc/model/cbi/openvpn-basic.lua | 5 |
2 files changed, 4 insertions, 5 deletions
diff --git a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua index 3fb734aeb..a693e0cf0 100644 --- a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua +++ b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-advanced.lua @@ -703,10 +703,10 @@ local cts = { } local params = { } local m = Map("openvpn") -local p = m:section( SimpleSection ) - +m.redirect = luci.dispatcher.build_url("admin", "services", "openvpn") m.apply_on_parse = true +local p = m:section( SimpleSection ) p.template = "openvpn/pageswitch" p.mode = "advanced" p.instance = arg[1] diff --git a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-basic.lua b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-basic.lua index 42eb4cfd8..cee5f9d31 100644 --- a/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-basic.lua +++ b/applications/luci-app-openvpn/luasrc/model/cbi/openvpn-basic.lua @@ -95,11 +95,10 @@ local basicParams = { local m = Map("openvpn") -local p = m:section( SimpleSection ) - +m.redirect = luci.dispatcher.build_url("admin", "services", "openvpn") m.apply_on_parse = true - +local p = m:section( SimpleSection ) p.template = "openvpn/pageswitch" p.mode = "basic" p.instance = arg[1] |