How show phone_mobile of contacs in create view of Call Module? Sugar 7.6

How show phone_mobile of contacs in create view of Call Module?

I'm add calculated value in field related($contacts, "phone_mobile"), but this show phone_mobile only record View.

How show in create view?

Parents
  • When using Sugar logic the field is specified as 'read-only' because the logic is enforced.

    You could disable the enforce on the field.

    $dictionary['Call']['fields']['phone_mobile']['enforce']='false'
    

    When creating a new Call from the contact's subpanel the phone_mobile will be autofilled. The field remains editable.

  • I'm create file

    custom/modules/Calls/Ext/Vardefs/vardefs.ext.php

    and

    add line

    $dictionary['Call']['fields']['phone_mobile']['enforce']='false'  
    
    

    But, this not work for me

    Thank you

Reply Children
    1. The contents of a file in the folder custom/modules/Calls/Ext/Vardefs/vardefs.ext.php get lost after a repair & rebuild.
    2. You could add the line of code to the file containing the definition of the field custom/Extension/modules/Calls/Ext/Vardefs/<fieldname>.php. After editing the field in the studio the enforced=false change will undone.

    The best solution is to add a file called enforce.php in de folder custom/Extension/modules/Calls/Ext/Vardefs containing:

    <?php

    $dictionary['Call']['fields']['phone_mobile']['enforce']='false'

    ?>

    replace the name "phone_mobile" with the fieldname you are using in the Call module to store the contacts phone_mobile. (probably ending with a _c)

    Don't forget to Repair & Rebuild