I can’t believe how long it took me to “get” this. DCPaus is of course exactly right, but I wasn’t relating to it very well.
I wanted to hide the “activities, tasks & history” subpanels in the Accounts module.
None the less, for myself & the next person in step by step fashion.
Create a new (empty) file named custom.php in the /custom/Extension/modules/Accounts/Ext/Layoutdefs folder in your suitecrm directory.
The contents of the file are …
<?php
// Remove activities & tasks from Accounts module (Ian Dodds)
unset($layout_defs['Accounts']['subpanel_setup']['activities']);
unset($layout_defs['Accounts']['subpanel_setup']['tasks']);
unset($layout_defs['Accounts']['subpanel_setup']['history']);
?>
Then do a “Quick Repair & Rebuild” from the repair selection in “Admin”
Following that, I also applied it to a custom module. (Copied the above custom.php file into the below directory & then edited the module name in the lines of code to suit.)
In my case the folder is /custom/Extension/modules/CER_ClientEquipment/Ext/Layoutdefs
(I opened one of the other files in this folder to get an accurate module name & copied that to replace the module name “Accounts” in the above example to my custom module name CER_ClientEquipment.)
The new code for my custom.php file is …
<?php
// Remove activities & tasks from Client Equipment module (Ian Dodds)
unset($layout_defs['CER_ClientEquipment']['subpanel_setup']['activities']);
unset($layout_defs['CER_ClientEquipment']['subpanel_setup']['tasks']);
unset($layout_defs['CER_ClientEquipment']['subpanel_setup']['history']);
?>
And then another “Quick Repair & Rebuild” from the repair selection in “Admin”
It worked as hoped in both scenario’s. I no longer see any of those 3 standard subpanels in either the Accounts module or my custom Client Equipment module.
SuitecRM Version 7.7.5
Gotta love computers :S :S :S