From: Jo-Philipp Wich Date: Wed, 7 Oct 2015 11:03:42 +0000 (+0200) Subject: luci-base: expose luci.dispatcher.build_url() as url() in templates X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=49a2cb5ad11ccc0225fd3fa1de4b85a0618bbb99;p=oweals%2Fluci.git luci-base: expose luci.dispatcher.build_url() as url() in templates Signed-off-by: Jo-Philipp Wich --- diff --git a/modules/luci-base/luasrc/dispatcher.lua b/modules/luci-base/luasrc/dispatcher.lua index 28dfd18bb..5d9d1b0b1 100644 --- a/modules/luci-base/luasrc/dispatcher.lua +++ b/modules/luci-base/luasrc/dispatcher.lua @@ -286,6 +286,7 @@ function dispatch(request) ifattr = function(...) return _ifattr(...) end; attr = function(...) return _ifattr(true, ...) end; token = ctx.urltoken.stok; + url = build_url; }, {__index=function(table, key) if key == "controller" then return build_url()