When it comes to developing solutions for SugarCRM there are many different ways to go about solving a particular challenge. In our Dev Tips series of blogs we will be highlighting various best practices for add-on development with the end goal of creating higher quality solutions while minimizing the chances of an end user experiencing an issue.
One way to create solutions for SugarCRM is by creating installable packages called modules. Modules contain all the required files along with a manifest.php which defines how the module should be installed. Here are a couple of links which help define and provide examples of a manifest:
SugarCRM Support: Creating an Installable Package for a Logic Hook
Most of the possible options within a manifest are fairly safe as most use the Extension framework to guarantee that there will not be conflicts with other modules that are installed. However, the option that is used in near every module but doesn’t utilize the Extension framework is the copy array option. The copy array defines what files and/or directories from the module zip should be copied over and to where it should be copied to. There is good reason for copy being unique from the Extension framework, but because of how it is used to copy over both files and directories, care must be taken to prevent accidental or unneeded removal of existing customizations.
More importantly, the copy array should accurately list the customizations that are being copied into an install as it is useful for users to be able to open and see if anything being copied over will overwrite a customization of their own. With SugarOutfitters we do that scanning for users and present them a list of the files that may have a chance of conflicting with their own customizations (whether they be from another module, studio, or hand coded). Here are the items that we flag along with some suggestions on how to improve that manifest entry:
Blank Copy to Root
Example: Why we flag it:
Full Directory Copy
Example: Why we flag it:
Core File Copy
Example: Why we flag it:
Custom File Copy
Example: Why we flag it:
With the above suggestions, members will be well-informed about and feel more comfortable with what they’re getting into when purchasing your custom modules. This gives a much better chance for a good user experience when installing and using the module as the user will know what to expect. Furthermore, with SugarOutfitters, we can better present accurate conflict notifications including possible conflicts with other previously purchased add-ons.
So when it comes to the copy directive option, be as descriptive as possible. It will save both users and yourself some headaches.
-
Customer Map Locator for Sugar
Locate your clients and prospects on a contextualized map. Visually identify clients by type icon. Get directions to help plan out your route.
-
CData Drivers and Connectors
FEATUREDCreate a consolidated customer 360 view, streamline accounting processes, consolidate martech data for real-time marketing insights, optimize your sales and supply chain pipelines, or build live and d...
-
Mobileforce CX Portal
FEATUREDDeliver white-glove digital UI experiences to your customers and partners with Mobileforce's Connected Portal and mobile app builder. Mobileforce CX Portal is tightly integrated with SugarCRM.
- Show more addons