• Best practices to enforce 1:1 relationships?

    It turns out that Sugar does not enforce 1:1 relationships, it overwrites them with no warning to the user. (Bug?) Is my only option for enforcement a custom before-relationship-add logic hook? Thanks, Francesca
  • before_relationship_add after returning after relationship informaiton

    Hi everyone. I'm having an issue currently with before_relationship_add, what I am wanting to do is to interrogate the change to a 1:1 relationship. So for instance my idea was: Relationship changes from A to B. I load A and find the old name. …
  • Is it possible to trigger a logichook after the process definition has complete the process ?

    Hi All, I want to do verify the data change after Process Definitions has ended saving?
  • How can I fill a non-db field in a after_retrieve call?

    I have created a custom field that is not a db field. When I run an after_retrieve logic hook it should be filled with a message. For some reason I can't get the field to populate. I know the function is running, because I get the error log. I am…
  • Web Logic Hook not sending events o sending wrong ones

    Hello! Recently we have implemented a Webhook to notify users of new and closed cases. We had this running for last month without a problem. Since the start of this year, the SMS has stopped. We set up a new one to point to webhook.site to compare…
  • How To save date and time value in date and time field in sugarcrm using before save logic hook ?

    How To save date and time value in date and time field in sugarcrm using before save logic hook ?
  • Send note file with email as attachment

    Hi, In case record i have an note record with file attachment under "Notes" subpanel. I need to send that file from note record with email as attachment. Currently the email is sending using ($mail = new SugarPHPMailer();) but how to attach that file…
  • Prevent deletion of some products

    Hello i want to disable delete or prevent them from deleting certain products in some module when user clicks delete button. Is there any experts who knows this ? Thanks in advance any help would be appreciated. found a sample code trying to put it together…
  • How to show message from after save logichook in sugarcrm 7.9

    I have logichook aftersave, and in this I have send data to my api and based on api response I want to show message in SugarCRM 7.9. How can I achive this. I have think to replace logichook with endpoint but in create.js I did not get record_id. I have…
  • auto increment integer field

    Hi, I use sugar 7.6 pro and I want a custom integer field id_autoincrement in the task module which is autoincremented every time that I create a new task. If I create a task and the last created id is 10 the new one will be 11 for example. I find a lot…
  • How to inherit Primary Team from related (Parent) record via Logic Hook?

    Hello, My scenario is the following: 1. We have Teams defined by regions (Africa, Asia, Europe...etc.) 2. For each Teams added some users. 3. An Account created (which is located in Europe) and manually set up the Team for Europe. If I create a child…
  • Set Relationship is not working on sandbox Sugarcrm

    This is m logic hook After Save , this logic hook is perfectly working on my local machine. But it is not working on sandboxcopy. I asked this question to Sugar Support team , They found that Set_relationship is not working . But my question is why this…
  • How to remove email addresses through an after save logic hook?

    Hello, All. I would like to scrub bogus email addresses (that are entered during testing, etc) through an after save logic hook. I am able to mark an email address as invalid using the code below. However, I would like to completely remove the email address…