* Fix bug#20464

This commit is contained in:
zenggang
2022-03-09 09:27:42 +00:00
parent d28a3b2f39
commit 41e2e45e8a
+12
View File
@@ -244,6 +244,18 @@ class customModel extends model
$link = explode('|', $link);
list($label, $module, $method) = $link;
$hasPriv = commonModel::hasPriv($module, $method);
/* Fix bug#20464 */
if(!$hasPriv and is_array($item) and isset($item['subMenu']))
{
foreach($item['subMenu'] as $subMenu)
{
if(!isset($subMenu['link'])) continue;
list($subLabel, $module, $method) = explode('|', $subMenu['link']);
$hasPriv = commonModel::hasPriv($module, $method);
if($hasPriv == true) break;
}
}
if($module == 'execution' and $method == 'more') $hasPriv = true;
if($module == 'project' and $method == 'other') $hasPriv = true;
}