This repository has been archived by the owner on Sep 13, 2024. It is now read-only.
You can show only actual menu items for users. #14142
snenko
started this conversation in
Feature improvement
Replies: 1 comment 1 reply
-
I try to implement this via custom override code in my project. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
if you add isShowTopLevelMenuItem function into Vtiger_Menu_Model class:
`
public static function isShowTopLevelMenuItem($menu)
{
if(isset($menu['childs']) && count($menu['childs'])>0) {
foreach ($menu['childs'] as $id=>$subMenu) {
}
return true;
}
`
And update TPL file:
/layouts/basic/modules/Vtiger/menu/Label.tpl
` {if $MENU_MODULE=='Settings::Vtiger'}
{assign var=SHOWITEMMENU value='true'}
{else}
{assign var=SHOWITEMMENU value=Vtiger_Menu_Model::isShowTopLevelMenuItem($MENU, $MENU_MODULE)}
{/if}
Beta Was this translation helpful? Give feedback.
All reactions