From e4d24f07c9e641a18aede2f556bee4361b7a7af6 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Wed, 28 Jul 2021 09:00:16 +0200 Subject: luci-base: dispatcher: rework dispatching and menu filtering logic - Prefer nodes that do not require authentication over nodes that do - Honour ACL dependencies while resolving firstchild nodes - Consider currently active session while scanning menu tree instead of only loading effective ACLs when a login node is encountered - Do not consider nodes for firstchild dispatching which specify a special "firstchild_ineligible" property - Hide menu nodes that have no accessible children Signed-off-by: Jo-Philipp Wich --- modules/luci-base/htdocs/luci-static/resources/ui.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/luci-base/htdocs/luci-static/resources/ui.js') diff --git a/modules/luci-base/htdocs/luci-static/resources/ui.js b/modules/luci-base/htdocs/luci-static/resources/ui.js index 0e909b6dcc..9cc62c12db 100644 --- a/modules/luci-base/htdocs/luci-static/resources/ui.js +++ b/modules/luci-base/htdocs/luci-static/resources/ui.js @@ -3021,7 +3021,7 @@ function scrubMenu(node) { for (var k in node.children) { var child = scrubMenu(node.children[k]); - if (child.title) + if (child.title && !child.firstchild_ineligible) hasSatisfiedChild = hasSatisfiedChild || child.satisfied; } } -- cgit v1.2.3