Have you ever wanted to set up a Global ACL Policy for users in SugarCRM? I wanted to this past week and found with the lack of a global group it was very confusing at first. The reason for this was that we developed a module that controls LeadRouting and we wanted to enabled Sales Managers to control who got assigned for a given state in the US and Canada or by a given country everywhere else. Since we didn’t want people updating this module unless they were in Sales Management we need to lock down the whole module.
Now we could have created a group and assigned it to everyone, but when adding new users trying to remember to add that global group to the newly created user would be an issue. What we did was use the contoller.php in the module to determine if the current user has access to it by doing the following: