How can I display a field from one module in a different module?

I am running SugarCRM Professional, Version 7.2.  I want to add a field to a layout in the calls module, but the field I want to add is a Studio created field from a different module.  I searched the old Sugar vt bulletin forums and found lots of people talking about editing the php files and creating all kinds of relationships, but no one clearly said whether it can be done strictly via Studio.  This site seems less techie, but I have not found an answer here either.  Can I (without editing any source files manually or installing JavaScript files) make a field created for one module available for the layout of a screen in another?  It sure seems like something lots of people would want to do.  Thanks for any help I get (even if the answer is that it cannot be done).
  • Hi John,

    Our public KB article on the intro to Sugar Logic covers this scenario. In short, yes, you can use the Mass Update function to update records. Depending on how many records you have to update, this may become a time intensive process and in some cases, it may exceed the server limits if you try to update too many records at once. If you have thousands of records to update, it may be better to create a checkbox field in the module that you can mass update and filter records via that checkbox field. For example, once the field is created, filter the list view by all records with that field unchecked. Select ~1000 records and mass update them to have the field checked. Once the mass update completes, those records will have their calculated field updated and they will no longer return in the filtered list view.

    Another route you could take is to update all of your records via the REST API if you have the appropriate knowledge. This would allow you to run a process behind the scenes rather than working through the UI.

    Please let me know if you have any questions.

    Kind regards,

    Chris
  • Hi Chris,

    Thanks for your post. As I was reaching out to you I also opened up a Case. SugarCRM Support was able to update all the existing fields by doing the following: "I (SugarCRM Support) went ahead and updated the calculated fields by adding the division field to the filters and sorting all the empty results. I then used the actions menu to run a 'Recalculate Fields' on the needed contact records." I do not fully understand what they did but it did work. Can you shed some light on what they did?
  • John,

    My name is Mike and I was the one you were working with to get this recent update taken care of.  I just wanted to chime in and expand on what I did a bit.  

    First I added your custom field (division) to the existing filters available.  I did this by going into the studio section of Sugar through Admin > Studio and selecting the module that contained the custom field; in this case, Contacts.  Once there I selected layouts, and then Search layout.  Adding the custom field to this layout makes it available as an option to filter by when looking at the listview of your contacts module.  This process can be found here: http://support.sugarcrm.com/02_Documentation/01_Sugar_Editions/01_Sugar_Ultimate/Sugar_Ultimate_7.2/...

    Once I had the field you wanted updated as something I could filter by, I organized the records by all blank divisions first by clicking on the header/column title.  

    I then selected all the records and clicked the action menu > Recalculate Values which of course ran into the limit problem, but addressed the first thousand records which were the records that needed a value as they were blank.  That brought the number of records needing updated down to around 500.  I repeated this same process, thus updating the remaining records appropriately.  

    I hope this helps to clear things up a bit.  Let me know if you have any additional questions.

    Thanks!

    Mike Majoris
  • Hi all , is it possible to do this in Community edition 6.5? 
  • Can this be done in CE?  I don't see the formula field or way to complete this.  Please help!
  • Woow! Thanks guys, this a very very nice blog and community, I´m new in the SUGARCRM development and I think this community is a great idea. I have ressolved a problem with the fields related between modules. Thanks a lot!!. Best Regards
  • OK, so I have followed everything going on in this post so far, but I seem to be having one small problem I'm hoping someone can answer for me. When I new calls is created, I would like to show the Contact info in the call itself (Contact Name, Company, phone number). This is not out of the box, which I find odd since it seems an important piece of info). I made the calculate field and it still is not carrying over. Should I be using the module I calculate from Contact or Contact_parent for a newly created call?
  • The answer seems to have been Contact, Contact parent did not return anything into the field.
  • Hi,

    I am not an expert in the CE, I know that  the CE has a lot of complication, but I know you can create relationships between modules, so, you can try this:

    1.- create a relationship between both modules

    2.- create a related field in the second module

    3.- that field is going to have the value of the first module selected field

    4.- you can get his value with sugar logic functions.

    5.- the second module field, must to be a calculated field (check true the calculated field checkbox when you designe the second module field)

    6.-  then, go to designer section views of the second module and you add the field to the register view of the module.

    7.- finally you reload the "page", record view of the second module and you will see the results.

    Of course, you must do this from Sugar Studio of the admin module.

    Good luck.

    Best regards.

    Obtener Outlook para Android<https://aka.ms/ghei36>