Get in touch:
01524 851 877
07718 896 553

SugarCRM Field Access Control

Posted on Oct 27 2009 by Matthew Jakeman

I have been playing around with SugarCRM CE recently as part of a project and one of the features we required was to be able to make some fields read only to certain users. This feature is available in the Professional version of SugarCRM but unfortunately not in the Community Edition.

Fortunately I came across this SugarCRM module which did some of what I wanted. Unfortunately however, when a field is set to “Read Only” it disappears totally in the Edit View. Apparently this is a feature of the module but it definitely wasn’t what I wanted. I wanted the fields to still appear in the Edit View but be read only.

There were also a few other bits and pieces unfinished in the module such as the type of access that had been selected for a field showing up as the representing integer value in the overview rather than a human readable string.

After quite a steep learning curve editing the templates and adding a logic hook I have managed to get the module doing more or less what I want. I have left the original type of Read Only as it was and added a new type “Read Only In Edit View” which does pretty much what it says on the tin. I have also changed the overview list of fields to display a string showing what type of access has been selected for a field.

I am probably going to keep making tweaks to this module as there are still quite a few tweaks that could be made to make it a bit better I think.

For now my modified version of the module can be downloaded here or here.

Leave a comment