* improve subMenu.

This commit is contained in:
zhujinyong
2013-06-19 01:38:44 +00:00
parent 79eae99f5c
commit 7d756c2473
3 changed files with 4 additions and 3 deletions
+2 -1
View File
@@ -386,7 +386,8 @@ class commonModel extends model
if(common::hasPriv($module, $method))
{
/* Is the currentModule active? */
if($currentModule == $subModule and $float != 'right') $active = 'active';
$subModules = explode(',', $subModule);
if(in_array($currentModule,$subModules) and $float != 'right') $active = 'active';
if($module == $currentModule and ($method == $currentMethod or strpos(",$alias,", ",$currentMethod,") !== false) and $float != 'right') $active = 'active';
echo "<li class='$float $active'>" . html::a(helper::createLink($module, $method, $vars), $label, $target, "id=submenu$subMenuKey") . "</li>\n";
}