We are strong advocates of making your CRM instance your own. Adding integrations, customizing modules and installing custom add-ons are just a few ways to make Sugar feel like it's been designed specifically for your business.
In this blog post, we'll take a look at how Matt Marum, Director of Product Management at SugarCRM, customized Sugar for a fictitious school of coders.
Professor M's School for Gifted Coders is a module-loadable package that can be installed in Sugar. Professor M is based on a popular character in the superhero world, who uses Sugar to manage his school. Professor M (aka Professor Marum) has created an exclusive non-profit school for gifted coders.
The Professor’s School is gathering the best and brightest to train them to battle against the forces of evil (specifically, bad customer experiences and poor project implementations). It is hazardous and demanding work.
The school has deployed Sugar as a platform to help them manage both students and faculty so they can focus on their core organizational goals of developing talented coders and being a force for good.
High-Level Use Cases
Professor’s M School uses Sugar for the following high-level use cases:
- Managing applicants, current students, former students, and professors
- Tracking super groups (groups of coders)
- Soliciting donations from alumni and alumni affiliated super groups
Here is how you would name and use the modules of your Sugar instance if you were Professor M:
Professor M Module
Super groups are organizations of affiliated coders.
Applicants are prospective students that need to be accepted or rejected.
Students are coders who have been admitted to the Professor M School.
Donations are opportunities to raise funds as charitable contributions.
Funding Line Items
Revenue Line Items
Charitable contributions broken down by line item.
Custom person-type module
School staff that helps Professor M teach student coders.
These are the prerequisites necessary to install this package:
- Sugar 22.214.171.124 (or newer) installed with NO sample data.
- Note: If Sugar is installed using config_si.php, it needs to be sure that the disable_unknown_platforms property is set to false or is not in the file.
- Note for Windows users: The path to the Sugar instance has to be as short as possible to avoid errors of file paths being too long.
Install the Modules and Customizations
Here is how you can install this Sugar package:
- Download the appropriate zip file from the latest Github repository release. Get the production version of the package if you’re installing it on Sugar Cloud. Otherwise, download the standard or production release file. Note that the standard release includes automated testing files too.
- Login to Sugar as an Administrator
- Navigate to Administration > Module Loader
- Upload the zip file
- Click Install for the ProfessorM package
- Review and accept the license agreement
- Click Commit
- Note for Windows users: If you receive the warning message "Full extraction path exceed MAXPATHLEN (260)...", try doing the following:
- Download the archive from the latest Github release.
- Install the zip as a module loadable package using the steps above.
- Download sugarcrm-ProfessorM-windows-manual-install.zip from the latest release.
- Unzip the file. It includes a Readme file and a set of folders. If there are no folders in the zip, then all file paths in the package/src folder have been deemed short enough to be included in a typical Windows installation, and the zips need to be generated locally on your machine.
- Open ProfMForWindowsReadme.txt and follow the instructions to manually copy the files from the zip to the Sugar instance. You may need to create the appropriate folders in you instance if they do not already exist.
- Navigate to Administration > Repair > Quick Repair and Rebuild.
- If the above installation still fails due to a MAXPATHLEN error, try manually generating the zips locally.
Choose Which Modules to Display
After installing the package, you should choose which modules you want to display.By default, Sugar displays most of the modules in your instance. To make things simpler, you can hide any modules you are not planning on using extensively, and rearrange the rest based on your needs.
- Login to Sugar as an Administrator
- Go to Administration > Display Modules and Subpanels
- Drag any modules you don’t need to use in the Hidden Modules section
- Rearrange the items in the Displayed Modules based on their importance in your Sugar instance
- Click Save
Using the Sugar REST API to Create the Professor M Sample Data
To create the Professor M sample data, you can use Postman to run a collection of Sugar REST API calls. Each call in the collection has one or more simple tests associated with it to ensure the call was successful.
- Save a copy of ProfessorM_PostmanCollection.json
- In Postman, click Import
- Click Choose Files and import ProfessorM_PostmanCollection.json
- Click the gear icon in the upper right corner and select Manage Environments
- Click Add
- Input a name for your environment (for example, Professor M)
- Add the following keys and values:
- url: the url of the Sugar installation (for example, http://localhost:8888/profm)
- rest_endpoint: /rest/v10
- username: the username for an admin user in the Sugar instance
- password: the password associated with the username above
- Click Add
- Close the Manage Environments dialog
- Click Runner
- Select the ProfessorM Sample Data collection
- Ensure the newly created environment is selected
- Click Run
- Wait for the collection to finish running. All tests should pass.
For Sugar Enterprise and Ultimate editions, you can use the features that leverage Advanced Workflow. A good point is to save a copy of ProfessorM_PostmanCollection_AdvancedWorkflow.json and follow the steps above to import the collection and run it.
Setting Up Your Development Environment
To generate the Professor M module loadable packages or update the code, you will need to set up a development environment. This is not required if you’re just planning to install the Professor M package as is.
- Checkout or download a copy of this repository.
- Install PHP 7.
- Install Composer. Composer is used to install the PHP dependencies for the project.
- Execute the following command from the school/package folder in order to install the dependencies:
You should now be ready to customize Professor M’s School for Gifted Coders package how you see fit and carry the School of Gifted Coders legacy. We hope you enjoyed our walkthrough for customizing your Sugar instance from a coder’s perspective. We certainly enjoyed the subject presented by Matt Marum at SugarCon 2018 in Las Vegas.
If you would like to customize your Sugar instance to fit your business like a glove, don't hesitate to contact us today!