diff options
author | Steven Barth <steven@midlink.org> | 2008-11-05 21:12:19 +0000 |
---|---|---|
committer | Steven Barth <steven@midlink.org> | 2008-11-05 21:12:19 +0000 |
commit | ba689499bb82e7bff9a118feaec6a7fd032157e0 (patch) | |
tree | ab04e6cf26f2d15fb81f7ec887b2b4a136c277ec | |
parent | 5c36f2175179f2dae03b8d2f31677186c41efcd2 (diff) |
Merge on_***_to handlers
-rw-r--r-- | libs/web/luasrc/dispatcher.lua | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libs/web/luasrc/dispatcher.lua b/libs/web/luasrc/dispatcher.lua index 79532ddf1..2323cf8d2 100644 --- a/libs/web/luasrc/dispatcher.lua +++ b/libs/web/luasrc/dispatcher.lua @@ -529,6 +529,16 @@ function cbi(model, config) end end + if config.on_valid_to and state and state > 0 and state < 2 then + luci.http.redirect(config.on_valid_to) + return + end + + if config.on_changed_to and state and state > 1 then + luci.http.redirect(config.on_changed_to) + return + end + if config.on_success_to and state and state > 0 then luci.http.redirect(config.on_success_to) return |