Hi,
Copy header.php file from modules/Contacts/clients/base/menus/header/ to custom/modules/Contacts/clients/base/menus/header and comment the create array in the file.
Please find the below sample code of contacts module.
<?php
$module_name = 'Contacts';
$viewdefs[$module_name]['base']['menu']['header'] = array(
//~ array(
//~ 'route'=>'#'.$module_name.'/create',
//~ 'label' =>'LNK_NEW_CONTACT',
//~ 'acl_action'=>'create',
//~ 'acl_module'=>$module_name,
//~ 'icon' => 'fa-plus',
//~ ),
//~ array(
//~ 'route'=>'#'.$module_name.'/vcard-import',
//~ 'label' =>'LNK_IMPORT_VCARD',
//~ 'acl_action'=>'create',
//~ 'acl_module'=>$module_name,
//~ 'icon' => 'fa-plus',
//~ ),
array(
'route'=>'#'.$module_name,
'label' =>'LNK_CONTACT_LIST',
'acl_action'=>'list',
'acl_module'=>$module_name,
'icon' => 'fa-bars',
),
array(
'route' => '#Reports?filterModule=' . $module_name,
'label' =>'LNK_CONTACT_REPORTS',
'acl_action'=>'list',
'acl_module' => 'Reports',
'icon' => 'fa-bar-chart-o',
),
array(
'route'=>'#bwc/index.php?module=Import&action=Step1&import_module=Contacts&return_module=Contacts&return_action=index',
'label' =>'LNK_IMPORT_CONTACTS',
'acl_action'=>'import',
'acl_module'=>$module_name,
'icon' => 'fa-arrow-circle-o-up',
),
);
Hope this helpful for you.
Hi Gurpreet Singh,
Dhanalaskhmi's post above will achieve what you're after.
However, before implementing, I strongly recommend you read through a very similar request here as there are some caveats to this approach: https://sugarclub.sugarcrm.com/explore/enterprise-professional/f/enterprise-professional-questions/3428/i-am-unable-to-create-a-report-when-i-click-on-the-triangle-under-the-reports-tab-create-is-not-an-option-i-can-view-view-reports-or-schedule-reports-help/19051#19051.
It's not wrong - you just need to be aware so that if any of those considerations are relevant for your system, you know how to handle it.
In addition to those considerations, bear in mind that if in the future Sugar adds something to the core header.php file (e.g. a new menu item for a new function), you'll need to manually copy that into your custom/ version too.
Good luck!
Adam
Dhanalaskhmi Vusirika Thanks for your help .
Hi,
From your given path /clients/base/menus/header are not there.How i remove.